Large mortgage originators saw relatively positive results in the recent second quarter as banks reported higher origination volumes, according to analysts with Keefe, Bruyette & Woods.

In addition, gain-on-sales, while somewhat down, remained elevated according to second-quarter results coming out of the industry.

"We believe that two of the biggest beneficiaries from strong volume and margins are PHH Corp. (PHH) and Nationstar Mortgage (NSM)," wrote KBW. "Fidelity National Financial and First American Financial should also benefit from the continued strong mortgage volume which is reflected in title insurance orders."

In analyzing 2Q earnings from the big banks, KBW said it "generally views the mortgage results for banks that have already reported 2Q earnings positively, and we believe they point toward strong results for the rest of the industry."

Bank of America (BAC) recently beat analyst estimates with a second-quarter profit of $2.5 billion, or 19 cents a share, in the second quarter. Prior to the release of the 2Q report, analysts estimated a much more modest 2Q profit of 14 cents a share for BofA.

Citigroup (C) also beat the average earnings estimate by recording a profit of 95 cents a share, compared to forecasts of earnings in the 89 cent-per-share range.

Costs tied to representations and warranties associated with mortgage-backed securities risks remain significant at all of the banks, with a few positive developments, KBW said.

"While JPM noted a positive inflection point in rep and warranty trends, PNC took an outsized provision driven by an expected increase in GSE repurchase demands," KBW said.