Family based immigrant petitions filed by U.S. citizens and green card holders for their same-sex partners are accepted by the U.S. Citizenship and Immigration Services (USCIS). This means U.S. citizens and legal residents can both sponsor their partners of the same sex for U.S. green cards, just like other heterosexual couples.
Form I-130, Petition for Alien Relative can be filed by them to bring their foreign national husband or wife to the U.S. Applications filed by them will not be rejected just because of the same-sex nature of their marriages. However, the sponsors must be eligible to sponsor their foreign national husband or wife for lawful status and the beneficiaries must be admissible into the U.S.
The unconstitutional Defense of Marriage Act (DOMA) was overturned by the Supreme Court in June 2013 after which the USCIS started to accept immigrant petitions from U.S. citizens and green card holders for their husbands or wives of the same sex. There is no difference in the way the USCIS considers and adjudicates applications filed by gay couples from the way it considers applications filed by other heterosexual couples. Apart from accepting new applications from such couples, USCIS also reviewed the petitions filed by such couples in the past that were denied due to the same sex nature of their marriages.
U.S. citizens and green card holders in same-sex marriages can bring their partners living in foreign countries to the U.S. by filing Form I-130 for them. In this case, the beneficiaries need to apply for consular processing and get immigrant visas. Those in the U.S. on non-immigrant status, can apply for adjustment of status through which they can adjust their status to legal permanent resident. They need not go through consular processing.
Only those who were married in U.S. states or foreign countries that are in favor of same-sex marriages can file applications to sponsor their partners. The place where the couple were married will determine whether or not their marriages are valid for immigration purposes. However, applications filed by those living in states that do not recognize same sex marriages but were married in states that recognizes such marriages, will be considered by the USCIS.