ARM: OMAP: mcbsp: Make wakeup control generic
Hello Jarkko Nikula,
This is a semi-automatic email about new static checker warnings.
The patch 1a6458847dd2: "ARM: OMAP: mcbsp: Make wakeup control generic" from Sep 26, 2011, leads to the following Smatch complaint:
sound/soc/omap/mcbsp.c:590 omap_mcbsp_free()
error: we previously assumed 'mcbsp->pdata' could be null (see line 586)
sound/soc/omap/mcbsp.c
585
586 if (mcbsp->pdata && mcbsp->pdata->ops && mcbsp->pdata->ops->free)
^^^^^^^^^^^^
Existing check.
587 mcbsp->pdata->ops->free(mcbsp->id - 1);
588
589 /* Disable wakeup behavior */
590 if (mcbsp->pdata->has_wakeup)
^^^^^^^^^^^^^^^^^^^^^^^^
Patch introduces an unchecked dereference.
591 MCBSP_WRITE(mcbsp, WAKEUPEN, 0); 592
regards,
dan carpenter