Freddie Mac swung to a $2.1 billion loss in the second quarter following a profit in the first quarter.

But Freddie narrowed its loss from the $4.7 billion loss it recorded in the year-ago period.

The Federal Housing Finance Agency requested another $1.5 billion in bailout funds from the Treasury Department for Freddie. However, that was offset by a $1.6 billion dividend payment Freddie made to the Treasury in the second quarter. So far, Freddie has taken $66.2 billion in draws but has paid back $13.2 billion since entering conservatorship in September 2008. Together with the $89.1 billion in bailouts Fannie Mae still owes the Treasury after a second-quarter loss, the two government-sponsored enterprises owe $142.2 billion to taxpayers. Freddie said the return to a loss from 1Q reflected declines in long-term interest rates on the fair value of derivatives, which cost Freddie $3.8 billion in the second quarter, compared to $427 million in the previous three months. Meanwhile, the GSE provided nearly $180 billion to the mortgage market in the first half of 2011, and the delinquency rate on its single-family portfolio dropped by 13 basis points over the second quarter to 3.5%. "Mortgage interest rates remained near record lows during the second quarter, helping to support the most affordable market for homebuyers in decades," said Freddie CEO Ed Haldeman. "Nonetheless, labor market weakness and households' worries about their financial security dampened home sales during the quarter." Income was nearly even at $4.6 billion, while the GSE boosted its provision for credit losses to $2.5 billion, up from $2 billion in the previous quarter. "While we expect some improvement in home sales during the second half of the year, our outlook for the single-family housing market remains cautious," Haldeman said. Write to Jon Prior. Follow him on Twitter @JonAPrior.