Skip to content

Commit

Permalink
regulator: fix tps6524x section mismatch
Browse files Browse the repository at this point in the history
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>

Fix section mismatch that is caused by init code calling exit code:
pmic_remove() cannot be marked as __devexit.

WARNING: drivers/regulator/tps6524x-regulator.o(.devinit.text+0x205): Section mismatch in reference from the function pmic_probe() to the function .devexit.text:pmic_remove()
The function __devinit pmic_probe() references
a function __devexit pmic_remove().
This is often seen when error handling in the init function
uses functionality in the exit path.
The fix is often to remove the __devexit annotation of
pmic_remove() so it may be used outside an exit section.

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Cc:	Liam Girdwood <lrg@slimlogic.co.uk>
Cc:	Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc:	Cyril Chemparathy <cyril@ti.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
  • Loading branch information
rddunlap authored and Liam Girdwood committed Mar 26, 2011
1 parent 6995236 commit 5362b09
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/regulator/tps6524x-regulator.c
Original file line number Diff line number Diff line change
Expand Up @@ -596,7 +596,7 @@ static struct regulator_ops regulator_ops = {
.get_current_limit = get_current_limit,
};

static int __devexit pmic_remove(struct spi_device *spi)
static int pmic_remove(struct spi_device *spi)
{
struct tps6524x *hw = spi_get_drvdata(spi);
int i;
Expand Down

0 comments on commit 5362b09

Please sign in to comment.