(Bloomberg) -- Panasonic Corp., which jointly owns a battery factory with Tesla Inc., sold the entirety of its stake in the electric vehicle maker, according to a person familiar with the matter.

The company plans to disclose the details of the sale in a filing later on Friday, the person, said asking not to be identified because the details aren’t yet public. The Nikkei reported the news earlier, saying Panasonic will book several hundred billion yen in profit and will use the proceeds to help pay for its $7 billion acquisition of artificial intelligence software developer Blue Yonder.

A spokeswoman at Panasonic declined to comment.

Panasonic is Tesla’s oldest battery supplier and the two have invested billions of dollars in a battery factory in Nevada. The relationship has been contentious at points, with Panasonic facing frequent — and at times public — prods from Tesla Chief Executive Officer Elon Musk to boost battery production. Panasonic also has a battery partnership with Toyota Motor Corp.

Read more: New Panasonic CEO Says Efficiency to Fuel Tesla Business, Growth

Shares of Panasonic rose as much as 4.8% in early trading in Tokyo on Friday. Tesla closed 3.5% higher in the U.S. on Thursday.

Read more: Tesla’s 3-Day Rally Nearly Erases Stock’s Decline for Year

©2021 Bloomberg L.P.