The advent of the smartphone has not been kind to BlackBerry, the Canada-based device maker whose products once dominated the C-suite and the trading floor. In survival mode, the company has been slashing costs and laying off thousands of employees. On Monday, Fairfax Financial, a Canadian insurance company, threw its compatriot a lifeline. Fairfax agreed to acquire BlackBerry for $9 a share, or about $4.7 billion, and BlackBerry has agreed to the deal in principle. The price, while still significant, marks a huge markdown from BlackBerry’s peak value; the share traded at about $148 in the summer of 2008.