diff options
Diffstat (limited to 'drivers/video')
-rw-r--r-- | drivers/video/macfb.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/drivers/video/macfb.c b/drivers/video/macfb.c index cfc748e94272..e6cbd9de944a 100644 --- a/drivers/video/macfb.c +++ b/drivers/video/macfb.c | |||
@@ -609,18 +609,19 @@ void __init macfb_setup(char *options) | |||
609 | } | 609 | } |
610 | } | 610 | } |
611 | 611 | ||
612 | void __init macfb_init(void) | 612 | static int __init macfb_init(void) |
613 | { | 613 | { |
614 | int video_cmap_len, video_is_nubus = 0; | 614 | int video_cmap_len, video_is_nubus = 0; |
615 | struct nubus_dev* ndev = NULL; | 615 | struct nubus_dev* ndev = NULL; |
616 | char *option = NULL; | 616 | char *option = NULL; |
617 | int err; | ||
617 | 618 | ||
618 | if (fb_get_options("macfb", &option)) | 619 | if (fb_get_options("macfb", &option)) |
619 | return -ENODEV; | 620 | return -ENODEV; |
620 | macfb_setup(option); | 621 | macfb_setup(option); |
621 | 622 | ||
622 | if (!MACH_IS_MAC) | 623 | if (!MACH_IS_MAC) |
623 | return; | 624 | return -ENODEV; |
624 | 625 | ||
625 | /* There can only be one internal video controller anyway so | 626 | /* There can only be one internal video controller anyway so |
626 | we're not too worried about this */ | 627 | we're not too worried about this */ |
@@ -958,11 +959,11 @@ void __init macfb_init(void) | |||
958 | 959 | ||
959 | fb_alloc_cmap(&fb_info.cmap, video_cmap_len, 0); | 960 | fb_alloc_cmap(&fb_info.cmap, video_cmap_len, 0); |
960 | 961 | ||
961 | if (register_framebuffer(&fb_info) < 0) | 962 | err = register_framebuffer(&fb_info); |
962 | return; | 963 | if (!err) |
963 | 964 | printk("fb%d: %s frame buffer device\n", | |
964 | printk("fb%d: %s frame buffer device\n", | 965 | fb_info.node, fb_info.fix.id); |
965 | fb_info.node, fb_info.fix.id); | 966 | return err; |
966 | } | 967 | } |
967 | 968 | ||
968 | module_init(macfb_init); | 969 | module_init(macfb_init); |