Skip to contentSkip to conversation

s6e63m0: fix section mismatch

PATCH In review Axel Lin 2 participants 2 messages Jul 28, 2010

Subsystems (2)
lore
Share & tools
lore

Axel Lin

author
#0 lore raw

PATCH 2/2 s6e63m0: fix section mismatch

Eliminate section mismatch warning by marking s6e63m0_probe() as __devinit.

---
 drivers/video/backlight/s6e63m0.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/video/backlight/s6e63m0.c +1 -1
index b27ccf9..1757379 100644
@@ -732,7 +732,7 @@ static ssize_t s6e63m0_sysfs_show_gamma_table(struct device *dev,
 static DEVICE_ATTR(gamma_table, 0644,
 		s6e63m0_sysfs_show_gamma_table, NULL);
 
-static int __init s6e63m0_probe(struct spi_device *spi)
+static int __devinit s6e63m0_probe(struct spi_device *spi)
 {
 	int ret = 0;
 	struct s6e63m0 *lcd = NULL;
Signature · 1 line
1.5.4.3
#1 lore raw
Quoted 2 lines · On Wed, 28 Jul 2010 11:07:36 +0800 Axel Lin <[email protected]> wrote:

Eliminate section mismatch warning by marking s6e63m0_probe() as __devinit.

Please aways quote the error messages or warnings when fixing build errors or warnings. It helps with the review quite a lot.

Quoted 6 lines
drivers/video/backlight/s6e63m0.c +0 -0
index b27ccf9..1757379 100644

drivers/video/backlight/s6e63m0.c static ssize_t s6e63m0_sysfs_show_gamma_table(struct device *dev, · line 738

Quoted 8 lines
drivers/video/backlight/s6e63m0.c +1 -1
@@ -732,7 +732,7 @@ static ssize_t s6e63m0_sysfs_show_gamma_table(struct device *dev,
 static DEVICE_ATTR(gamma_table, 0644,
 		s6e63m0_sysfs_show_gamma_table, NULL);
 
-static int __init s6e63m0_probe(struct spi_device *spi)
+static int __devinit s6e63m0_probe(struct spi_device *spi)
 {
 	int ret = 0;
 	struct s6e63m0 *lcd = NULL;

Many drivers/video/backlight/*.c drivers use __devinit for the platform_driver.probe handler. Quite a lot use nothing (ie: .text). Some still use __init. About half of them use __devexit_p for .remove and half don't. It looks like it all needs a bit of loving care.