Sumner Redstone isn’t the basketball type - corporate hardball is his game - but he’s getting what amounts to a financial makeup call from Uncle Sam. Redstone, chairman of entertainment giant Viacom Inc., was fouled by Congress last year when it passed surprise legislation to foil his planned tax-free sale of Viacom’s cable-TV systems. But he’s just gotten a surprising ruling from the Internal Revenue Service that lets him sell the systems taxfree, although in a more complicated and expensive way than originally planned.

Unless the IRS reverses its call, which seems unlikely, Viacom will be able to sell its cable systems for $2.36 billion without paying a single penny in capitalgains taxes. I think Viacom deserves its tax break, which will save it at least $600 million, because of the unfair way Congress took away its break last year. But if Viacom’s loophole remains open and lots of companies start using it, it could cost taxpayers billions.

You may recall that last year Redstone unveiled a tax-free $2.3 billion sale under the Federal Communications Commission program that lets companies duck capital-gains taxes by selling cable or broadcast properties to minority buyers. I detested the program because most of its benefits went to white-controlled corporations that did sham transactions by selling to white-controlled buyers who rented minority front men. Other deals subsidized wealthy buyers like Bill Cosby and Quincy Jones, which was absurd. But I think Congress treated Redstone unfairly, even though the people involved insist they weren’t discriminating against him.

Here’s what happened. Before Redstone could file Viacom’s deal with the FCC, the tax-writing House Ways and Means Committee issued a news release proposing to scrap the minority program-effective the day of the release. Normally, loophole-closing legislation is retroactive to the day the bill is introduced. I consider the foul especially flagrant because the Republican-controlled Congress included special clauses approving minority deals by Tribune Co. and Rupert Murdoch’s News Corp. Tribune is a conservative company, Murdoch is very conservative, Redstone is a liberal Democrat. Funny how that works.

Redstone, who didn’t get to be a billionaire by being a pussycat, vowed to find another tax-free way to sell the cable properties. After a year of paper shuffling and angst, Viacom got the financing and approvals it needed, and mailed details to shareholders last week. Viacom is giving them a chance to swap Viacom common stock for stock in the Viacom subsidiary that owns the cable systems. The deal is scheduled to close later this month

As you can see from the explanation adjacent to this article, this deal has more moving parts than a rail car full of hall bear. ings. Even though the deal amounts to what a normal human would consider a sale, it’s being treated like. a simple transaction in which a company splits into pieces. Thus, the deal is tax-free to Viacom and to the stockholders who end up with shares in the cable company, which will promptly be acquired by Tele-Communications Inc. for $2.36 billion. Viacom won’t say how much taxable income this nonsale sale would generate if it were a sale. But filings indicate the gain would be at least $1.5 billion, maybe even $2 billion. At a 40 percent combined tax rate (federal, state and local), Viacom saves $600 million to $800 million.

Viacom, wisely, isn’t talking. (It declined to comment on this story.) Its premature boasting about the tax-free minority sale got Congress’s back up. The IRS, which doesn’t discuss individual tax rulings,wouldn’t talk, but I’m sure it didn’t make nice to Viacom to make up for last year’s congressional foul. The IRS doesn’t do that kind of stuff. But I love the irony of Viacom’s getting a ruling that many people didn’t expect, offsetting a congressional trashing almost no one expected.

The bottom line: Viacom deserves its makeup tax break. But after that, someone should slam-dunk this loophole before it becomes a bigger pain than Dennis Rodman.

1.) Viacom Inc.’s Viacom International subsidiary (international), whose holdings include the cable systems, MTV, and Paramount Pictures, creates a new subsidiary called Viacom International Services (Services).

2.) International borrows $1.7 billion in cash.

3.) International transfers the noncable assets and the cash to Services. This leaves International with the cable systems and $1.7 billion in debt. Services is transferred to Viacom Inc., giving Viacom Inc. the cash and the noncable assets.

4.) Viacom Inc. stockholders trade some of their shares for International Class A common stock valued at $625.8 million.

5.) TCI buys $350 million of Class B common stock in International. TCI takes control of International, and renames it TCI Pacific Communications. The $625.8 million of International Class A common becomes $625.8 million of TCI Pacific preferred.

6.) Bingo: Viacom Inc. and its stockholders get $2.36 billion for the cable system. Tax bill: zero.