FILE - In this Dec. 12, 2013 file photo, a man passes by the Samsung Electronics Co. logos at its headquarters in Seoul, South Korea. A unanimous Supreme Court on Tuesday, Dec. 6, 2016, sided with smartphone maker Samsung in its high-profile patent dispute with Apple over design of the iPhone. The justices said Samsung may not be required to pay all the profits it earned from 11 phone models because the features at issue are only a tiny part of the devices. (AP Photo/Ahn Young-joon, File)

WASHINGTON (AP) — A unanimous Supreme Court on Tuesday sided with smartphone maker Samsung in its high-profile patent dispute with Apple over design of the iPhone.

The justices said Samsung may not be required to pay all the profits it earned from 11 phone models because the features at issue are only a tiny part of the devices.

Apple had won a $399 million judgment against Samsung for copying parts of the iPhone’s patented design, but the case now returns to a lower court to decide what Samsung must pay.

The case is part of a series of disputes between the technology rivals that began in 2011. Apple accused Samsung of duplicating a handful of distinctive iPhone features for which Apple holds patents: the flat screen, the rounded rectangle shape of the phone, and the layout of icons on the screen.

At issue was how much Samsung is required to compensate Apple under an 1887 law that requires patent infringers to pay “total profit.” Apple said that meant all the profits from the phone sales, while Samsung argued it was limited to profits related to the specific components that were copied.

Justice Sonia Sotomayor wrote for the court that the law does not require damages to be based on the entire product, but can be limited to only a component of the product. The decision overturned a ruling from a federal appeals court in Washington, which said that Apple was entitled to all the profits.

But the high court declined to lay out a specific test for how such damage awards should be calculated. Sotomayor said doing so was not necessary and the justices left it up to lower courts to resolve.

Samsung had argued that the hefty award ignored the fact that its phones contain more than 200,000 other patents that Apple does not own. Apple said the verdict was fair because the iPhone’s success was directly tied to its distinctive look.