mfd: Handle missing WM8350 platform data

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@openedhand.com>
This commit is contained in:
Mark Brown 2008-12-18 23:12:08 +01:00 committed by Samuel Ortiz
parent 9692063062
commit 53a0d99b1e

View File

@ -1350,7 +1350,7 @@ int wm8350_device_init(struct wm8350 *wm8350, int irq,
return ret;
}
if (pdata->init) {
if (pdata && pdata->init) {
ret = pdata->init(wm8350);
if (ret != 0) {
dev_err(wm8350->dev, "Platform init() failed: %d\n",