aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/gma500/framebuffer.c
diff options
context:
space:
mode:
authorKirill A. Shutemov <kirill.shutemov@linux.intel.com>2012-03-08 11:02:36 -0500
committerDave Airlie <airlied@redhat.com>2012-03-10 08:05:50 -0500
commit6aa1ead1b855819b8b754d0f84f9da6942fe7589 (patch)
treed2ca9e96726e75b37b1a6c451d5b62020430f2d7 /drivers/gpu/drm/gma500/framebuffer.c
parent026abc333205c1fff80138b8c2cac3d0347685f4 (diff)
gma500: psbfb_create(): move depth initialization out of loop
Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/gma500/framebuffer.c')
-rw-r--r--drivers/gpu/drm/gma500/framebuffer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/gma500/framebuffer.c b/drivers/gpu/drm/gma500/framebuffer.c
index 110fcad4c124..b4710dc8d27f 100644
--- a/drivers/gpu/drm/gma500/framebuffer.c
+++ b/drivers/gpu/drm/gma500/framebuffer.c
@@ -391,6 +391,7 @@ static int psbfb_create(struct psb_fbdev *fbdev,
391 mode_cmd.width = sizes->surface_width; 391 mode_cmd.width = sizes->surface_width;
392 mode_cmd.height = sizes->surface_height; 392 mode_cmd.height = sizes->surface_height;
393 bpp = sizes->surface_bpp; 393 bpp = sizes->surface_bpp;
394 depth = sizes->surface_depth;
394 395
395 /* No 24bit packed */ 396 /* No 24bit packed */
396 if (bpp == 24) 397 if (bpp == 24)
@@ -403,7 +404,6 @@ static int psbfb_create(struct psb_fbdev *fbdev,
403 * is ok with some fonts 404 * is ok with some fonts
404 */ 405 */
405 mode_cmd.pitches[0] = ALIGN(mode_cmd.width * ((bpp + 7) / 8), 4096 >> pitch_lines); 406 mode_cmd.pitches[0] = ALIGN(mode_cmd.width * ((bpp + 7) / 8), 4096 >> pitch_lines);
406 depth = sizes->surface_depth;
407 407
408 size = mode_cmd.pitches[0] * mode_cmd.height; 408 size = mode_cmd.pitches[0] * mode_cmd.height;
409 size = ALIGN(size, PAGE_SIZE); 409 size = ALIGN(size, PAGE_SIZE);