Real-estate recovery has helped Fannie and Freddie return to full-year profitability for first time since 2006.