BUDAPEST, June 15 (Reuters) - Hungary's parliament approved a constitutional amendment on Monday that allows ‌prime ministers to serve for a maximum ‌of eight years, effectively barring former premier Viktor Orban from ​holding the role again.

Prime Minister Peter Magyar ousted Orban in an election in April after 16 years, gaining a two-thirds majority in parliament that allows ‌his party to ⁠roll back or change legislation passed by Orban's Fidesz, including the constitution.

• The ⁠amendment says that those who had previously held the role of prime minister for at least ​eight years "cannot ​be elected prime minister." ​This applies to prime ‌ministerial terms held after the date of May 2, 1990.

• Prime ministers will have to leave office after a total of eight years, or two terms.

• The constitutional amendment also paves the ‌way for the dissolution of ​the Sovereignty Protection Office, ​set up by ​Orban's government, that stigmatised opposition figures ‌and journalists for serving "foreign interests."

• ​In addition, ​the amendment gives back the founders' rights of so-called public-interest asset-management foundations to the state. ​Orban's government transferred ‌state assets worth hundreds of billions of ​forints to these foundations.

(Reporting by Anita Komuves; ​Editing by Hugh Lawson)