mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-22 02:20:40 +00:00
fbdev: fbmem: Fix logo center image dx issue
commit955f04766d
upstream. Image.dx gets wrong value because of missing '()'. If xres == logo->width and n == 1, image.dx = -16. Signed-off-by: Guiling Deng <greens9@163.com> Fixes:3d8b1933eb
("fbdev: fbmem: add config option to center the bootup logo") Cc: stable@vger.kernel.org # v5.0+ Signed-off-by: Helge Deller <deller@gmx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
e5fde29135
commit
989b2c4032
1 changed files with 1 additions and 1 deletions
|
@ -514,7 +514,7 @@ static int fb_show_logo_line(struct fb_info *info, int rotate,
|
|||
|
||||
while (n && (n * (logo->width + 8) - 8 > xres))
|
||||
--n;
|
||||
image.dx = (xres - n * (logo->width + 8) - 8) / 2;
|
||||
image.dx = (xres - (n * (logo->width + 8) - 8)) / 2;
|
||||
image.dy = y ?: (yres - logo->height) / 2;
|
||||
} else {
|
||||
image.dx = 0;
|
||||
|
|
Loading…
Reference in a new issue