Some like to blame Wall Street greed for the meltdown. I'm not saying that there isn't blame to be assessed there too, but I can't help but observe that Wall Street's reaction is somewhat like the HAL 9000 computer in 2001: A Space Odyssey. It became irrational because it was instructed to do something fundamentally at odds with its programming. Banks were made to lend to borrowers whom their normal underwritng standards said they should not or be fined for doing so. They were placed in a no-win situation and the ways they tried to reconcile the two competing goals of prudent lending and complying with the Community Redeveloment Act (CRA) caused them to do increasingly irrational things. It's just one more example of how political interference in free markets, well intentioned or not, produces undesireable results.
Update: History of the HAL 9000. HAL was constructed for "the accurate processing of information without distortion or concealment". However, he was asked to conceal information from the Discovery crew and the only way he could reconcile the contradictory instruction was to kill the crew, therefore leaving no one to conceal anything from.