(Reuters) - Diamond Foods Inc removed top management after a probe by its audit committee found that the company improperly accounted for payments to walnut growers, sending its shares down 40 percent in after-hours trading.

The company, maker of Emerald nuts, Kettle chips and Pop Secret popcorn, also said that earnings for its 2010 and 2011 fiscal years will need to be restated to account for the payments.

The result of the investigation and share drop has thrown into doubt the company's deal to buy the Pringles potato chip business from Procter & Gamble Co., which was to be paid for with Diamond shares.

There's a very, very low chance of the Pringles (deal) happening now, said a Diamond investor who declined to be identified due to the sensitivity of the issue.

Chief Executive Michael Mendes and Chief Financial Officer Steve Neil have been placed on administrative leave, the company said in a statement, adding that it was seeking permanent replacements for the two men.

Diamond named director Rick Wolford as acting chief executive and Michael Murphy of consulting firm Alix Partners as acting finance chief.

The company is being investigated by the U.S. Securities and Exchange Commission over the accounting. In addition, the Wall Street Journal on Jan. 12 reported that U.S. prosecutors have launched a criminal inquiry.

The announcement Wednesday is the latest shock to Diamond investors since the probe over payments was announced in November. Adding to the cloud over the company was the suicide that month of Diamond board member Joseph Silveira, who was on the audit committee but rescued himself from the probe since he was president of a firm that manages walnut-growing properties.

Diamond's audit committee found that a payment of about $20 million to walnut growers in August 2010 and another amount of about $60 million in September 2011 were not booked in the correct periods, the company said.

It is unclear precisely when they payments should have been booked but any delays from one fiscal year to the next could artificially reduce the company's costs and boost earnings in that period.

The costs would then increase in subsequent years. In the years ended July 31, 2010 and 2011, the company reported earnings before taxes of $40.2 million and $69.1 million respectively.

Additional information could be discovered as part of the audit committee's ongoing investigation or as the financial restatements are prepared, the company said in a filing with the SEC.

The company has been besieged with questions about whether the way the payments were booked was intended to make the company's earnings look better while it negotiated to buy Pringles from P&G.

A spokesman for P&G said the Diamond announcement was breaking news to the company and that it was considering what steps to take next.

The information released by Diamond Foods is very disappointing, P&G spokesman Paul Fox said. Pringles remains a valuable asset and it has attracted considerable interest from other outside parties.

We need to be focused on building Pringles and on its employees. Those employees would move to Diamond under terms of the deal.

Tom Pirko, CEO of Bevmark Consulting said he expects it to take some time for Diamond -- whose shares have fallen nearly 80 percent since hitting a high of $96.13 in September -- to recover from the probe.

Essentially what has happened is a kind of surgery to excise a tumor, Pirko said. The company has lost faith with investors. They're going to have to make wholesale changes to their culture, their business practices, their accounts, their communications.

FALL FROM GRACE

Mendes, whose removal is a fall from grace, joined Diamond in 1991 and quickly rose through the ranks to become CEO in 1997. He transformed the company from a co-operative of walnut growers into one of the biggest snack food companies in the United States.

After the company went public in 2005, Mendes spent millions on popular brands like Pop Secret popcorn and Kettle chips, and moved the company's headquarters from its rural base in Stockton, Calif., to San Francisco.

Neil, a veteran finance professional, had been CFO since early 2008. He previously held the top finance jobs at lens makers Cooper Cos Inc and Ocular Sciences, and at the generic drugs company Perrigo Co.

It's a good thing that they're cleaning house and getting some new guys in there, the Diamond investor said. It shows that the board is committed to doing things properly.

Diamond shares fell to $21.13 in after-hours trading from Wednesday's Nasdaq close of $36.66, wiping more than $326 million off the company's market value.

(Reporting by Mihir Dalal in Bangalore; additional reporting and writing by Brad Dorfman in Chicago; Editing by Saumyadeb Chakrabarty, Steve Orlofsky and Bernard Orr)