aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mfd/wm8994-core.c
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2011-06-02 14:18:55 -0400
committerSamuel Ortiz <sameo@linux.intel.com>2011-07-31 17:28:20 -0400
commita2495bc727e2dd8421fb85c80e38f9a4a4c1e58e (patch)
tree2e3617a8e7e6d8fafe966edf0bb08f5e6df20f03 /drivers/mfd/wm8994-core.c
parentd1738aef387ab9591a6d13b00945e248b942c53f (diff)
mfd: Restructure wm8994-core device revision handling
Switch on the device type before revision since anything we do here will be device as well as revision specific. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'drivers/mfd/wm8994-core.c')
-rw-r--r--drivers/mfd/wm8994-core.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/drivers/mfd/wm8994-core.c b/drivers/mfd/wm8994-core.c
index e198d40292e7..18f19b7198a0 100644
--- a/drivers/mfd/wm8994-core.c
+++ b/drivers/mfd/wm8994-core.c
@@ -476,13 +476,18 @@ static int wm8994_device_init(struct wm8994 *wm8994, int irq)
476 goto err_enable; 476 goto err_enable;
477 } 477 }
478 478
479 switch (ret) { 479 switch (wm8994->type) {
480 case 0: 480 case WM8994:
481 case 1: 481 switch (ret) {
482 if (wm8994->type == WM8994) 482 case 0:
483 case 1:
483 dev_warn(wm8994->dev, 484 dev_warn(wm8994->dev,
484 "revision %c not fully supported\n", 485 "revision %c not fully supported\n",
485 'A' + ret); 486 'A' + ret);
487 break;
488 default:
489 break;
490 }
486 break; 491 break;
487 default: 492 default:
488 break; 493 break;