Tesla’s Chief Executive Officer Elon Musk has agreed to step down as the company’s chairman as part of a settlement with the United States markets regulator, which had filed a fraud case against him. The company will also pay $40 million (Rs 290 crore) as penalty, Bloomberg reported. The Securities and Exchange Commission announced the settlement on Saturday.

Musk will keep his role of chief executive and will remain a board member, but must resign as chairman within 45 days as part of the agreement. He cannot be re-elected to the position for three years.

The settlement came two days after the Securities and Exchange Commission sued Musk for a series of “false and misleading” tweets in August, in which he proposed to take the company private and claimed he had secured funding. The regulator said Musk had not secured the funding, and that the tweets caused Tesla’s stock price to jump by over 6% in a day.

Weeks after his tweets, Musk announced the company would continue to be publicly traded, as he had received feedback showing most shareholders believed that Tesla is better off as a public company. Two investors had earlier sued him and Tesla for allegedly manipulating the company’s share prices through false and misleading tweets.

In its complaint, the Securities and Exchange Commission said: “In truth and in fact, Musk had not even discussed, much less confirmed, key deal terms, including price, with any potential funding source.” The regulator accused Musk of committing fraud by making false public statements with the potential to hurt investors, and sought to bar Musk from serving as an executive or director of publicly-traded companies.

After the lawsuit, Musk had called the action “unjustified”. “I have always taken action in the best interests of truth, transparency and investors,” he had said, according to CNN. “Integrity is the most important value in my life and the facts will show I never compromised this in any way.”