AKRON, Ohio (AP) - Endo Pharmaceuticals has reached a settlement with the first two Ohio counties set to go to trial in the national opioid lawsuit.

The Dublin-based drugmaker said Tuesday that it's agreed to pay Cuyahoga and Summit counties in Ohio a total of $10 million and to provide up to $1 million of free medication. The counties will determine how the settlement is divided.

As part of the deal, the company admits no wrongdoing, fault or liability related to the U.S. opioid epidemic that's prompted thousands of lawsuits by local governments, states and hospitals seeking damages.

An Endo official said the settlement's favorable for the company, costing roughly what would have been spent to carry the litigation through a trial set for in October.

Copyright 2019 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.