The Bet Yosef records a practice, which originates from the Geonim, to recite a Beracha over a cup of wine as part of the Berit Mila ceremony. This is indeed the accepted practice today. Several different reasons have been offered to explain the purpose of the cup of wine. Some suggested a comparison between a Berit Mila and a wedding, on the basis of which a cup of wine is required at a Berit Mila just as it is under the Hupa (canopy) at a wedding. Others explain the cup of wine as serving simply as "Hibub Misva" – an expression of our love and affection for this special Misva of circumcision.
An interesting question arises concerning the Beracha over the wine at a Berit Mila that takes place in the synagogue on Shabbat morning. Can one fulfill his obligation of Kiddush by listening to this Beracha? Can the Beracha recited over the wine at a Berit Mila function both as the Beracha for the Berit and the Beracha for Kiddush, or does it relate only to the Berit Mila ceremony?
The Halacha in such a case is that one may, indeed, fulfill his Kiddush obligation through the Beracha recited at the Berit Mila in such a case. Therefore, the person who recites the Beracha of "Boreh Peri Ha’gefen" over the wine at the Berit should first announce to everyone in attendance that he has in mind for them to fulfill their Kiddush obligation through his recitation of Kiddush. Of course, they, too, must have this intention as they hear his Kiddush, listen attentively to his Beracha, and recite "Amen." Furthermore, if this Beracha fulfills the requirement of Kiddush, the person who recites the Beracha must ensure to drink the minimum required amount for fulfilling the obligation.
Moreover, the Halachic principle of "En Kiddush Ela Be’makom Se’uda" teaches that one must eat at least a small meal in the location where he recites or hears Kiddush. Hence, if one wishes to fulfill his obligation of Kiddush through the Beracha recited over the wine at a Berit, he must ensure to eat at least a Ke’zayit of "Mezonot" food in that room, for otherwise he does not fulfill his obligation.
Summary: If a Berit Mila is held in the synagogue on Shabbat morning, one can fulfill his obligation of Kiddush by listening to the Beracha over the cup of wine at the Berit. Both the one reciting the Kiddush and the others must have this in mind as the Beracha is recited, and the one reciting the Kiddush must drink the minimum required amount of wine. Furthermore, everyone must eat at least a Ke’zayit of "Mezonot" food in the room where the Beracha was recited.
See Shut Hazon Obadya, helek 1, page 127. Also, see Soba Semahot, page 76.