From: Geert Uytterhoeven Date: Sun, 18 May 2008 18:47:15 +0000 (+0200) Subject: m68k: dnfb doesnt check for Apollo X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=d6497700879beeaaae208c0e9fd10b74dc44db5e;p=linux-beck.git m68k: dnfb doesnt check for Apollo The Apollo frame buffer device driver (dnfb) doesn't check whether it's actually running on Apollo hardware, causing a crash if it isn't. Signed-off-by: Geert Uytterhoeven Signed-off-by: Linus Torvalds --- diff --git a/drivers/video/dnfb.c b/drivers/video/dnfb.c index b083ea7e9c69..606da043f4b4 100644 --- a/drivers/video/dnfb.c +++ b/drivers/video/dnfb.c @@ -284,6 +284,9 @@ int __init dnfb_init(void) { int ret; + if (!MACH_IS_APOLLO) + return -ENODEV; + if (fb_get_options("dnfb", NULL)) return -ENODEV;