From 527dcf4c5029b8dc791eb96fad01a12bb06e7850 Mon Sep 17 00:00:00 2001 From: Kulikov Vasiliy Date: Tue, 10 Aug 2010 18:02:47 -0700 Subject: drivers/video/igafb.c: introduce lost 'return' If iga_init() fails, code releases resources and continues to use it. It seems that after releasing resources 'return' should be. Signed-off-by: Kulikov Vasiliy Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/video/igafb.c | 1 + 1 file changed, 1 insertion(+) (limited to 'drivers/video/igafb.c') diff --git a/drivers/video/igafb.c b/drivers/video/igafb.c index 15d200109446..c4e6fc0301d4 100644 --- a/drivers/video/igafb.c +++ b/drivers/video/igafb.c @@ -531,6 +531,7 @@ int __init igafb_init(void) iounmap(info->screen_base); kfree(par->mmap_map); kfree(info); + return -ENODEV; } #ifdef CONFIG_SPARC -- cgit v1.2.3 From 628a464e5bffd0e9aedaee2a85296be17aa19d90 Mon Sep 17 00:00:00 2001 From: Andrew Morton Date: Tue, 10 Aug 2010 18:02:47 -0700 Subject: drivers/video/igafb.c: make igafb_setup() and igafb_init() static Cc: Kulikov Vasiliy Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/video/igafb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'drivers/video/igafb.c') diff --git a/drivers/video/igafb.c b/drivers/video/igafb.c index c4e6fc0301d4..d885c770eb84 100644 --- a/drivers/video/igafb.c +++ b/drivers/video/igafb.c @@ -368,7 +368,7 @@ static int __init iga_init(struct fb_info *info, struct iga_par *par) return 1; } -int __init igafb_init(void) +static int __init igafb_init(void) { struct fb_info *info; struct pci_dev *pdev; @@ -557,7 +557,7 @@ int __init igafb_init(void) return 0; } -int __init igafb_setup(char *options) +static int __init igafb_setup(char *options) { char *this_opt; -- cgit v1.2.3