The patch titled fbdev: Fix logo rotation if width != height has been added to the -mm tree. Its filename is fbdev-fix-logo-rotation-if-width-=-height.patch See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find out what to do about this ------------------------------------------------------ Subject: fbdev: Fix logo rotation if width != height From: "Antonino A. Daplas" <adaplas@xxxxxxxxx> Logo drawing crashes or produces a corrupt display if the logo width and height are not equal. The dimensions are transposed prior to the actual rotation and the width is used instead of the height in the actual rotation code. These produce a corrupt image. Signed-off-by: Antonino Daplas <adaplas@xxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxx> --- drivers/video/fbmem.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff -puN drivers/video/fbmem.c~fbdev-fix-logo-rotation-if-width-=-height drivers/video/fbmem.c --- a/drivers/video/fbmem.c~fbdev-fix-logo-rotation-if-width-=-height +++ a/drivers/video/fbmem.c @@ -334,11 +334,11 @@ static void fb_rotate_logo_ud(const u8 * static void fb_rotate_logo_cw(const u8 *in, u8 *out, u32 width, u32 height) { - int i, j, w = width - 1; + int i, j, h = height - 1; for (i = 0; i < height; i++) for (j = 0; j < width; j++) - out[height * j + w - i] = *in++; + out[height * j + h - i] = *in++; } static void fb_rotate_logo_ccw(const u8 *in, u8 *out, u32 width, u32 height) @@ -356,24 +356,24 @@ static void fb_rotate_logo(struct fb_inf u32 tmp; if (rotate == FB_ROTATE_UD) { - image->dx = info->var.xres - image->width; - image->dy = info->var.yres - image->height; fb_rotate_logo_ud(image->data, dst, image->width, image->height); + image->dx = info->var.xres - image->width; + image->dy = info->var.yres - image->height; } else if (rotate == FB_ROTATE_CW) { - tmp = image->width; - image->width = image->height; - image->height = tmp; - image->dx = info->var.xres - image->height; fb_rotate_logo_cw(image->data, dst, image->width, image->height); - } else if (rotate == FB_ROTATE_CCW) { tmp = image->width; image->width = image->height; image->height = tmp; - image->dy = info->var.yres - image->width; + image->dx = info->var.xres - image->width; + } else if (rotate == FB_ROTATE_CCW) { fb_rotate_logo_ccw(image->data, dst, image->width, image->height); + tmp = image->width; + image->width = image->height; + image->height = tmp; + image->dy = info->var.yres - image->height; } image->data = dst; _ Patches currently in -mm which might be from adaplas@xxxxxxxxx are git-intelfb.patch savagefb-allocate-space-for-current-and-saved-register.patch savagefb-add-state-save-and_restore-hooks.patch savagefb-add-state-save-and_restore-hooks-fix.patch fbdev-more-accurate-sync-range-extrapolation.patch nvidiafb-revise-pci_device_id-table.patch atyfb-fix-hardware-cursor-handling.patch atyfb-remove-unneeded-calls-to-wait_for_idle.patch atyfb-set-correct-acceleration-flags.patch epson1355fb-update-platform-code.patch vesafb-update-platform-code.patch vfb-update-platform-code.patch vga16fb-update-platform-code.patch fbdev-static-pseudocolor-with-depth-less-than-4-does.patch savagefb-whitespace-cleanup.patch fbdev-firmware-edid-fixes.patch nvidiafb-add-support-for-geforce-6100-and-related-chipsets.patch vesafb-fix-return-code-of-vesafb_setcolreg.patch vesafb-prefer-vga-registers-over-pmi.patch atyfb-fix-dead-code.patch fbdev-coverity-bug-85.patch fbdev-coverity-bug-90.patch backlight-fix-kconfig-dependency.patch fbdev-fix-logo-rotation-if-width-=-height.patch macmodes-fix-section-warning.patch atyfb-fix-section-warnings.patch detaching-fbcon-fix-vgacon-to-allow-retaking-of-the.patch detaching-fbcon-fix-give_up_console.patch detaching-fbcon-remove-calls-to-pci_disable_device.patch detaching-fbcon-add-sysfs-class-device-entry-for-fbcon.patch detaching-fbcon-clean-up-exit-code.patch detaching-fbcon-add-capability-to-attach-detach-fbcon.patch detaching-fbcon-update-documentation.patch vt-binding-add-binding-unbinding-support-for-the-vt.patch vt-binding-update-fbcon-to-support-binding.patch vt-binding-fbcon-update-documentation.patch vt-binding-add-new-doc-file-describing-the-feature.patch vt-binding-add-sysfs-control-to-the-vt-layer.patch vt-binding-make-vt-binding-a-kconfig-option.patch vt-binding-do-not-create-a-device-file-for-class-device.patch vt-binding-update-documentation.patch vt-binding-make-mdacon-support-binding.patch vt-binding-make-newport_con-support-binding.patch vt-binding-make-promcon-support-binding.patch vt-binding-make-sticon-support-binding.patch - To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html