(Corrects to say banks could invest up to 3 percent of their Tier 1 capital, not their tangible common equity, in hedge funds and private equity funds)
* Lawmakers agree to tougher trading ban, with exceptions
* Banks can retain most swaps-dealing operations
* Obama will tout reform at G20 meeting
* Last minute deals lift bank stocks (Adds remarks from Obama, Sen. Lincoln, analyst; updates market reaction)
By Charles Abbott and Andy Sullivan
WASHINGTON, June 25 (Reuters) - U.S. lawmakers hammered out a historic overhaul of financial regulations as dawn broke over the nation's capital on Friday, handing President Barack Obama a major domestic policy victory on the eve of a global summit devoted to financial reform.
In a marathon session of more than 21 hours, legislators agreed to a rewrite of Wall Street rules that may crimp the industry's profits and subject it to tougher oversight and tighter restrictions.
To secure agreement, lawmakers reached deals in the final hours on the most controversial sections which restrict derivatives dealing by banks and curb their proprietary trading to shield taxpayer-backed deposits from more risky activities.
Banks will be allowed to keep most swaps dealing activity in-house, although the riskiest trading would be pushed out. They will also be permitted small investments in hedge funds and private equity funds.
The concessions could lessen the impact on bank profitability. U.S. bank stocks opened about 1.0 percent higher .BKX, with Goldman Sachs Group Inc (GS.N) stock up about 2.0 percent in early trade.
The most sweeping rewrite of financial rules since the 1930s aims to avoid a repeat of the 2007-2009 financial crisis, which touched off a global recession and led to taxpayer bailouts of floundering financial giants. Financial institutions would have to pay $19 billion to cover the costs.
The reforms must still win final approval from both chambers of Congress before Obama can sign them into law, giving Wall Street one final chance to deploy its army of lobbyists on Capitol Hill. Quick approval is expected and the reform could go to Obama for his signature by July 4.
Democrats had raced to complete their work before Obama left for a weekend meeting of the Group of 20 economic powers, where he can tout the changes as a blueprint for other countries.
"This crisis proved and events continue to affirm that our national economies are inextricably linked and just as economic turmoil in one place can quickly spread to another, safeguards in each of our nations can help protect all nations," Obama said at the White House shortly before departing.
Despite last-minute deals, the bill has actually gotten tougher in its yearlong journey through the halls of Congress. Democrats rode a wave of public disgust at an industry that awarded itself rich paydays while much of the country struggled through a deep recession caused by its actions.
"There is no way to view this bill as a positive for the financial sector," wrote Concept Capital analyst Jaret Seiberg.
The KBW bank stock index fell 10.4 percent in May this as the reform process gained steam, its worst month since October of last year, and the capital markets index .KSX fell 10.3 percent, its steepest drop since January 2009 when the crisis reached fever pitch.
Passage of the bill will give Democrats an important legislative victory, alongside healthcare reform, ahead of congressional elections in November. The House could vote as soon as Tuesday, Representative Barney Frank, who chaired the negotiating committee, said.
CURBS ON RISKY TRADING
Lawmakers munched chocolates to stay awake as regulators and administration officials hovered in the wood-paneled room, and as the night wore on, they yielded the microphones to staff to debate the bill's finer points.
The panel completed its work just after 5:30 a.m. (0930 GMT), more than 21 hours after it sat down to its final negotiating session.
Along the way, the negotiators resolved several sticking points that had threatened to scuttle the bill.
They agreed to water down a proposal by Democratic Senator Blanche Lincoln that would have required banks to spin off their lucrative swaps-dealing desks to a separately capitalized affiliate.
Dozens of House of Representatives Democrats said Lincoln's proposal would force trading to move overseas, and threatened to vote against the bill if it included the provision.
The compromise allows banks to stay involved in foreign-exchange and interest-rate swaps dealing, which account for the bulk of the $615 trillion over-the-counter derivatives market.
They also could participate in gold and silver swaps and derivatives designed to hedge banks' own risk.
They would need to spin off dealing operations that handle agricultural, energy and metal swaps, equity swaps, and uncleared credit default swaps.
"Quite frankly, common sense prevailed," said Lincoln, chairman of the Senate Agriculture Committee, shortly after agreement was reached on the bill. "Our objectives were to get the risky stuff out of banks. We figured out how to do that." [ID:nN25273408]
Lawmakers resolved another controversial element of the bill around midnight when they agreed that banks should face restrictions on their risky trading activities.
As with Lincoln's swaps provision, the financial industry won significant last-minute concessions in that rule, named for White House economic adviser Paul Volcker.
The final version of the Volcker rule would give regulators little wiggle room to waive the trading ban but would also allow banks to invest up to 3 percent of their Tier 1 capital in hedge funds and private equity funds.
The bill would dramatically reshape the financial landscape in the United States.
"Onerous legislation is baked into the price if you look at any large-cap bank names," said Weston Boone, managing director and position trader for large-cap banks at Stifel Nicolaus in Baltimore. He said smaller banks fared better.
The legislation sets up a new consumer-protection authority and gives regulators new power to seize troubled financial firms before they harm the broader economy.
Though it leaves largely intact the patchwork of federal regulators that failed to stop the last crisis, it sets up an interagency council to monitor system-wide risks to stability.
It forces much of the over-the-counter derivatives market, which worsened the financial crisis and led to a $182 billion bailout of insurer AIG, onto more accountable channels like clearinghouses and exchanges.
Larger banks face will have to raise more capital to help them ride out future crises.
Credit-rating agencies such as Moody's Corp could see their business models upended by regulators seeking to resolve conflicts of interest, while debit-card issuers like Bank of America will probably have to reduce the transaction fees they charge merchants who use their cards. (Additional reporting by Roberta Rampton, Rachelle Younglai and Kevin Drawbaugh, Deborah Charles and Tabassum Zakaria in Washington, and Rodrigo Campos in New York; writing by Andy Sullivan and Tim Ahmann; Editing by Alistair Bell and Jackie Frank)