Now here's a deal Homer Simpson can get behind: Krispy Kreme is cashing in.

The doughnut chain reached a $1.35 billion deal Monday to be acquired by JAB Holding, a private company that just recently agreed to buy Keurig Green Mountain (GMCR).

JAB is gobbling up Krispy Kreme (KKD) for $21 a share in cash, or roughly 25% more than the doughnut chain's closing price on Friday.

After the deal closes, Krispy Kreme will become a private company and keep its headquarters in Winston-Salem, NC.

"We are thrilled to have such an iconic brand as Krispy Kreme joining the JAB portfolio," Peter Harf, senior partner at JAB, said in a statement.

Related: Lawsuit says Starbucks' iced drinks have too much ice

Krispy Kreme hasn't been doing that well lately. The stock plunged below $14 late last year as sales of its consumer packaged goods -- donuts sold in supermarkets -- stumbled. But only in spring last year, the doughnut chain was trading above $20.

The big takeover is making people wonder if Dunkin' Brands (DNKN) might also be a takeover target. Shares of the parent of rival Dunkin' Donuts and Baskin-Robbins rose about 2%.