In a decision that one justice called “a major upheaval in Sixth Amendment law,” the U.S. Supreme Court on Wednesday ruled that lawyers have a constitutional obligation to advise clients of the collateral deportation consequences of a guilty plea in a criminal case.

“It is our responsibility under the Constitution to ensure that no criminal defendant — whether a citizen or not — is left to the mercies of incompetent counsel,” wrote Justice John Paul Stevens for the 7-2 majority.