The former Boston Bruins enforcer agreed to terms on a contract with the Florida Panthers on Tuesday, the first day of NHL free agency.

Thornton’s contract will be a two-year deal worth a total of $2.4 million, according to Hockey Night in Canada’s Elliotte Friedman.

Thornton, a fan favorite during his seven years in Boston, played 64 games for the Bruins this past season, tallying three goals, five assists and 74 penalty minutes. He was informed by the team last month that he would not be re-signed.

In an interesting twist, Thornton now becomes teammates with Panthers tough guy Krys Barch, who long has been one of his favorite sparing partners. The two have dropped the gloves eight times since Barch entered the league in 2007, according to HockeyFights.com, including once in a 4-1 Bruins win this past March.

Thornton will not have to wait long for his first game back in Boston, as the Panthers visit TD Garden on Tuesday, Nov. 4.