The Rajya Sabha on Friday passed the Unlawful Activities (Prevention) Amendment (UAPA) Bill after days of deadlock between the government and opposition parties over the controversial legislation.