aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/mfd/88pm860x-core.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/drivers/mfd/88pm860x-core.c b/drivers/mfd/88pm860x-core.c
index 78c3a9e1fa1e..6ed8de71c983 100644
--- a/drivers/mfd/88pm860x-core.c
+++ b/drivers/mfd/88pm860x-core.c
@@ -860,6 +860,15 @@ out:
860 return; 860 return;
861} 861}
862 862
863static void __devinit device_8606_init(struct pm860x_chip *chip,
864 struct i2c_client *i2c,
865 struct pm860x_platform_data *pdata)
866{
867 device_osc_init(i2c);
868 device_bk_init(chip, pdata);
869 device_led_init(chip, pdata);
870}
871
863int __devinit pm860x_device_init(struct pm860x_chip *chip, 872int __devinit pm860x_device_init(struct pm860x_chip *chip,
864 struct pm860x_platform_data *pdata) 873 struct pm860x_platform_data *pdata)
865{ 874{
@@ -867,9 +876,7 @@ int __devinit pm860x_device_init(struct pm860x_chip *chip,
867 876
868 switch (chip->id) { 877 switch (chip->id) {
869 case CHIP_PM8606: 878 case CHIP_PM8606:
870 device_osc_init(chip->client); 879 device_8606_init(chip, chip->client, pdata);
871 device_bk_init(chip, pdata);
872 device_led_init(chip, pdata);
873 break; 880 break;
874 case CHIP_PM8607: 881 case CHIP_PM8607:
875 device_8607_init(chip, chip->client, pdata); 882 device_8607_init(chip, chip->client, pdata);
@@ -879,9 +886,7 @@ int __devinit pm860x_device_init(struct pm860x_chip *chip,
879 if (chip->companion) { 886 if (chip->companion) {
880 switch (chip->id) { 887 switch (chip->id) {
881 case CHIP_PM8607: 888 case CHIP_PM8607:
882 device_osc_init(chip->companion); 889 device_8606_init(chip, chip->companion, pdata);
883 device_bk_init(chip, pdata);
884 device_led_init(chip, pdata);
885 break; 890 break;
886 case CHIP_PM8606: 891 case CHIP_PM8606:
887 device_8607_init(chip, chip->companion, pdata); 892 device_8607_init(chip, chip->companion, pdata);