diff options
author | Randy Dunlap <randy.dunlap@oracle.com> | 2011-06-16 15:31:19 -0400 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2011-06-24 04:00:31 -0400 |
commit | 3535ed3fa7a87244410696880000e03bc224315d (patch) | |
tree | 4939250bcc0e494d6cd7c1a5ed91aef9a89d4e26 /drivers/video/geode | |
parent | bccaeafd7c117acee36e90d37c7e05c19be9e7bf (diff) |
gx1fb: Fix section mismatch warnings
Fix a chain of section mismatches in geode driver, beginning with:
WARNING: drivers/video/geode/gx1fb.o(.data+0x70): Section mismatch in reference from the variable gx1fb_driver to the function .init.text:gx1fb_probe()
The variable gx1fb_driver references
the function __init gx1fb_probe()
If the reference is valid then annotate the
variable with __init* or __refdata (see linux/init.h) or name the variable:
*_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console
Making the changes that Paul pointed out resulted in a few more
changes being needed, so they are all included here.
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'drivers/video/geode')
-rw-r--r-- | drivers/video/geode/gx1fb_core.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/video/geode/gx1fb_core.c b/drivers/video/geode/gx1fb_core.c index c6b554f72c6d..5a5d0928df33 100644 --- a/drivers/video/geode/gx1fb_core.c +++ b/drivers/video/geode/gx1fb_core.c | |||
@@ -29,7 +29,7 @@ static int crt_option = 1; | |||
29 | static char panel_option[32] = ""; | 29 | static char panel_option[32] = ""; |
30 | 30 | ||
31 | /* Modes relevant to the GX1 (taken from modedb.c) */ | 31 | /* Modes relevant to the GX1 (taken from modedb.c) */ |
32 | static const struct fb_videomode __initdata gx1_modedb[] = { | 32 | static const struct fb_videomode __devinitdata gx1_modedb[] = { |
33 | /* 640x480-60 VESA */ | 33 | /* 640x480-60 VESA */ |
34 | { NULL, 60, 640, 480, 39682, 48, 16, 33, 10, 96, 2, | 34 | { NULL, 60, 640, 480, 39682, 48, 16, 33, 10, 96, 2, |
35 | 0, FB_VMODE_NONINTERLACED, FB_MODE_IS_VESA }, | 35 | 0, FB_VMODE_NONINTERLACED, FB_MODE_IS_VESA }, |
@@ -195,7 +195,7 @@ static int gx1fb_blank(int blank_mode, struct fb_info *info) | |||
195 | return par->vid_ops->blank_display(info, blank_mode); | 195 | return par->vid_ops->blank_display(info, blank_mode); |
196 | } | 196 | } |
197 | 197 | ||
198 | static int __init gx1fb_map_video_memory(struct fb_info *info, struct pci_dev *dev) | 198 | static int __devinit gx1fb_map_video_memory(struct fb_info *info, struct pci_dev *dev) |
199 | { | 199 | { |
200 | struct geodefb_par *par = info->par; | 200 | struct geodefb_par *par = info->par; |
201 | unsigned gx_base; | 201 | unsigned gx_base; |
@@ -268,7 +268,7 @@ static struct fb_ops gx1fb_ops = { | |||
268 | .fb_imageblit = cfb_imageblit, | 268 | .fb_imageblit = cfb_imageblit, |
269 | }; | 269 | }; |
270 | 270 | ||
271 | static struct fb_info * __init gx1fb_init_fbinfo(struct device *dev) | 271 | static struct fb_info * __devinit gx1fb_init_fbinfo(struct device *dev) |
272 | { | 272 | { |
273 | struct geodefb_par *par; | 273 | struct geodefb_par *par; |
274 | struct fb_info *info; | 274 | struct fb_info *info; |
@@ -318,7 +318,7 @@ static struct fb_info * __init gx1fb_init_fbinfo(struct device *dev) | |||
318 | return info; | 318 | return info; |
319 | } | 319 | } |
320 | 320 | ||
321 | static int __init gx1fb_probe(struct pci_dev *pdev, const struct pci_device_id *id) | 321 | static int __devinit gx1fb_probe(struct pci_dev *pdev, const struct pci_device_id *id) |
322 | { | 322 | { |
323 | struct geodefb_par *par; | 323 | struct geodefb_par *par; |
324 | struct fb_info *info; | 324 | struct fb_info *info; |
@@ -382,7 +382,7 @@ static int __init gx1fb_probe(struct pci_dev *pdev, const struct pci_device_id * | |||
382 | return ret; | 382 | return ret; |
383 | } | 383 | } |
384 | 384 | ||
385 | static void gx1fb_remove(struct pci_dev *pdev) | 385 | static void __devexit gx1fb_remove(struct pci_dev *pdev) |
386 | { | 386 | { |
387 | struct fb_info *info = pci_get_drvdata(pdev); | 387 | struct fb_info *info = pci_get_drvdata(pdev); |
388 | struct geodefb_par *par = info->par; | 388 | struct geodefb_par *par = info->par; |
@@ -441,7 +441,7 @@ static struct pci_driver gx1fb_driver = { | |||
441 | .name = "gx1fb", | 441 | .name = "gx1fb", |
442 | .id_table = gx1fb_id_table, | 442 | .id_table = gx1fb_id_table, |
443 | .probe = gx1fb_probe, | 443 | .probe = gx1fb_probe, |
444 | .remove = gx1fb_remove, | 444 | .remove = __devexit_p(gx1fb_remove), |
445 | }; | 445 | }; |
446 | 446 | ||
447 | static int __init gx1fb_init(void) | 447 | static int __init gx1fb_init(void) |
@@ -456,7 +456,7 @@ static int __init gx1fb_init(void) | |||
456 | return pci_register_driver(&gx1fb_driver); | 456 | return pci_register_driver(&gx1fb_driver); |
457 | } | 457 | } |
458 | 458 | ||
459 | static void __exit gx1fb_cleanup(void) | 459 | static void __devexit gx1fb_cleanup(void) |
460 | { | 460 | { |
461 | pci_unregister_driver(&gx1fb_driver); | 461 | pci_unregister_driver(&gx1fb_driver); |
462 | } | 462 | } |