drm/nouveau: fix for disabled fbdev emulation

Hello,

after this commit:

commit f045f459d9
Author: Ben Skeggs <[email protected]>
Date:   Thu Jun 2 12:23:31 2016 +1000
    drm/nouveau/fbcon: fix out-of-bounds memory accesses

kernel started to oops when loading nouveau module when using GTX 780 Ti
video adapter. This patch fixes the problem.

Bug report: https://bugzilla.kernel.org/show_bug.cgi?id=120591

Signed-off-by: Dmitrii Tcvetkov <[email protected]>
Suggested-by: Ilia Mirkin <[email protected]>
Fixes: f045f459d9 ("nouveau_fbcon_init()")
Signed-off-by: Ben Skeggs <[email protected]>
Cc: [email protected]
This commit is contained in:
Dmitrii Tcvetkov authored and Ben Skeggs committed 2016-06-24 07:51:32 +10:00
1 parent 6aa85f1129
commit 52dfcc5ccf
1 file changed
+2 -1
+2 -1
View File
@@ -552,7 +552,8 @@ nouveau_fbcon_init(struct drm_device *dev)
if (ret)
goto fini;
fbcon->helper.fbdev->pixmap.buf_align = 4;
if (fbcon->helper.fbdev)
fbcon->helper.fbdev->pixmap.buf_align = 4;
return 0;
fini: