Before Yahoo CEO Scott Thompson offered his resignation at Yahoo he visited China several times and met with Alibaba CEO Jack Ma. The two CEOs along with Yahoo’s CFO Tim Morse and legal head Mike Callahan were working out a deal to determine what should be done with Yahoo's large stake in the Chinese company. Apparently that deal came to somewhat of a resolution before Thompson left the firm.
The main gist involves Yahoo selling a majority of their shares back to Alibaba, who is currently raising capital for those efforts. It is quite a bit more involved than just the buyback however, Alibaba has plans for an IPO brewing. The deal further requires Yahoo to part with the remainder of their stock in Alibaba after the company goes public. So it's kind of a half now, half later agreement.
According to All Things D, Yahoo is holding about a 40% share of Alibaba which is valued at $7 billion. Currently Alibaba is valued at $35 billion, so it is safe to say Yahoo will make some rerun on their investment with the sale.
Despite the recent shift in power over at Yahoo the deal with Alibaba is still expected to be approved. If you remember, Dan Loeb got his way and with Thompson out of the picture, he is now on the board of directors and Ross Levinsohn is acting as interim CEO.