12:10PM EDT October 23. 2012 -

TORONTO (AP) — Royal Bank of Canada has agreed to buy the Canadian auto finance and deposit business of Ally Financial.

Canada's largest bank by market capitalization said Tuesday that the purchase will strengthen its position as leader in the Canadian auto finance sector. The cost is about $1.4 billion.

Ally's Canadian unit provides financing to nearly 600 auto dealerships across Canada.

Ally is the name for what used to be called GMAC, formerly the lending division of General Motors. The lender required multiple bailouts after the financial crisis because of the auto industry's near-implosion and its heavy investments in mortgage bonds.

Ally has strengthened its direct banking franchise, advertising directly to consumers and offering low-cost, online-only accounts. But it remains primarily an auto finance company. The U.S. Treasury Department owns 74% of Ally Financial.

Copyright 2012 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.