It's not as big a loss as it seems. Below is a quote from the NYT though you also need to factor in the annual Motorola losses.
"When Google bought Motorola, the hardware maker had about $3 billion in cash on hand and nearly $1 billion in tax credits. So that brings the original deal’s effective price down to about $8.5 billion.
Then, Google sold Motorola’s set-top box business to Arris for nearly $2.4 billion. That lowers the effective price to roughly $6.1 billion.