Bank of America Corp. (NYSE:BAC), the second-largest bank by assets in the U.S., is expected to swing to a profit on a per-share basis when it reports third-quarter results before markets open Wednesday, helped by lower operating costs and $1.1 billion in deferred tax assets that have helped offset a weakened mortgage sector and falling core trading revenues.

The Charlotte, N.C-based Bank of America is expected to report profit of 18 cents per share, up from zero cents in the same quarter a year earlier. Revenue is expected to be $22.034 billion compared with $20.428 in last year’s third-quarter, according to analysts polled by Thomson Reuters.

Citigroup analysts said earlier this month, “Going into earnings season the last few quarters, investor questions centered mostly around expenses and whether BAC could meet targets set under its new expense savings initiatives. BAC has demonstrated solid progress on this front, and with investor confidence increasing that BAC can execute on these savings, the story is shifting to revenue growth.”

Credit Suisse, however, bucking the consensus in its recent take on Bank of America, projected the company will post a 3 percent drop in third-quarter revenue from a year ago, to $21.27 billion. 

Bank of America is experiencing the same problems that have blighted other banks in this quarter, namely a lack of mortgage refinancing activity as interest rates have risen, according to Adam Sarhan of Sarhan Capital.

Early Tuesday, Citigroup Inc. (NYSE:C), the third-largest U.S. bank, reported a slight decline in third-quarter adjusted earnings on weak fixed-income trading revenue and a sluggish mortgage business. 

Fixed-income revenue of $2.8 billion, excluding one-time events, decreased 26 percent from the prior-year period, "reflecting lower volumes and a more uncertain macro environment," Citi said in a statement.

Look for a similar tone to come out of Bank of America's press release on Wednesday.

“It is becoming painfully obvious that U.S. banks are still working through their legacy issues revolving around their mortgage units,” said Sarhan. “Specifically, Bank of America are still unwinding the mess that came with Countrywide. The good news is that once they get passed all this they will become much healthier.”

Bank of America acquired huge mortgage lender Countrywide Financial in 2008 at the worst of the financial crisis. The company and the lawsuits that came with have been an albatross around BofA's neck ever since.

Credit Suisse analysts predict that Bank of America’s mortgage revenues will fall 20 percent from year-ago levels.

Looking forward, the market will be watching for comments about the bank's mortgage settlement issues with AIG. Bank of America has rejected a request from insurer American International Group Inc. (NYSE:AIG) and other investors to renegotiate the $8.5 billion settlement deal that was struck in July 2011 over soured mortgage-backed securities.

On the upside, a note from Citigroup predicts that Bank of America will increase pre-tax pre-provision income by 9 percent year-over-year. Pre-tax, pre-provision income is calculated before taking into account funds set aside to provide for future bad debts.

Within those numbers, BofA's global investment banking is expected to show a 16 percent gain as a rising stock market boosts the equities trade while increasing customers' assets under management and therefore bank fees. Global wealth management business grew 23 percent at Bank of America in the third quarter, according to analyst estimates, including a 13 percent year-over-year gain in investment and brokerage services revenues.  

Bank of America was trading at around $14.33 a share Tuesday. So far this year, the stock has gained 21.4 percent.