Defensive tackle Tershawn Wharton agreed to a three-year, $54 million deal with the Panthers after five years in Kansas City.