From: Ville Syrjälä Date: Wed, 27 Aug 2014 13:51:22 +0000 (+0300) Subject: drm/i915: s, fb->bits_per_pixel/8, pixel_size, in primary plane code X-Git-Tag: fixes-against-v3.18-rc2~73^2~32^2~65 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b98971271bf4c4566db2133ad0a36e4f24819fbe;p=pandora-kernel.git drm/i915: s, fb->bits_per_pixel/8, pixel_size, in primary plane code Use the pixel_size we got from drm_format_plane_cpp() instead of fb->bits_per_pixel/8 when computing the primary plane page/linear offsets. Avoids a few divs and makes the code more future proof against funky pixel formats where bits_per_pixel isn't well defined. This is what we already did in the sprite code. Note that the relevant sprite patch was commit ca320ac456099c29290568353d924157e626ede9 Author: Chris Wilson Date: Wed Dec 19 12:14:22 2012 +0000 drm/i915: Use pixel size for computing linear offsets into a sprite This change was required on sprites because they support yuv formats which have fb->bits_per_pixel undefined. Signed-off-by: Ville Syrjälä Reviewed-by: Chris Wilson [danvet: Add Chris' software archeology as a note to the commit message.] Signed-off-by: Daniel Vetter --- Reading git-diff-tree failed