Recently I watched a discourse of Sri Chaganti Koteswara Rao during Maha Sivaratri. He explained greatness of Shiva Lingam by citing the example of the previous birth of the Asura Mahabali. He said
Asura Mahabali was very wicked person in his previous birth. When he stole something, he hid on a bilva tree and when he was climbing the tree accidentally two leaves of bilva tree fell of Shiva Lingam under the tree. At the time of his death, Yama Ganas arrived and asked him to come to Yama loka. But at the same time Shiva ganas also arrived and there occurred a conflict between Shiva and Yama Ganas. Lord Yama went there and asked Bali whether he wanted to enjoy fruits of Good Karma or bad karma. Mahabali said he wanted to enjoy fruits of good Karma (Good Karma he did was only to anoint Lingam with Bilva leaves accidentally). So, as a result of good fruits, he got a chance to become Indra for one day. After becoming Indra, Mahabali donated Swarga loka to two sages (don't remember their names). As a result of this good deed, he was destined to born as Grandson of Prahlada.
I vaguely remember this story and forgive me if there are any mistakes. I could not find any source for this discourse.
So, my question is, what scriptures describe the story of the previous birth of the Asura Mahabali?