The Royal Bank of Scotland booked about $ 2 billion in the quarter for its efforts to reshape the lender and for potential fines and settlements.