“The subprime-mortgage-market meltdown is a classic example of the way small fry get devoured, but the whales of Wall Street get rescued,” writes Fortune senior editor-at-large Allan Sloan. He adds:

If you believe in markets — which I do — this rescue is especially galling, because Wall Street enabled this mess in the first place. How so? By happily sucking up hundreds of billions of dollars’ worth of suspect mortgages from marginal U.S. borrowers — and begging mortgage makers to create more of them. The Street sliced and diced this financial toxic waste into a variety of esoteric securities, making a nice markup when it sold them and generating a continuing stream of profits when it made markets in them.

Somehow analysts at credit-rating agencies, looking at computerized scenarios rather than at the real world, decided that the bulk of the securities backed by these trashy loans could be rated triple-A.

It’s really amazing: Most of the loans to substandard creditors borrowing 100 percent of the purchase price of homes they couldn’t afford were rated the same as GE and the federal government. That makes no sense. But the money rolled in, and Wall Street — by which I mean the world’s biggest and most important financial institutions — didn’t care about the real world or ask any questions. It was too busy making money, and cashing bonus checks generated by subprime-mortgage profits.

Sloan grants that we don’t want “the world’s financial system to implode,” so it’s a good thing that Federal Reserve chairman Ben Bernanke and the world’s other central bankers think some institutions are “to big to fail.” But Sloan wants those big institutions to pay a price for their bailouts:

I’d feel a lot better if the Street had to pay a serious price to its rescuers — say, having to fork over a big equity stake and pay a loan-shark interest rate. That way taxpayers, who are picking up the tab for the rescue, would get paid bigtime for taking on bigtime risk.

After all, that’s the Wall Street way.