JPMorgan profit gets boost from trading, underwriting