diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2015-12-21 14:13:04 +0100 |
---|---|---|
committer | Thierry Reding <thierry.reding@gmail.com> | 2016-01-04 08:58:33 +0100 |
commit | 074726402b82f14ca377da0b4a4767674c3d1ff8 (patch) | |
tree | b2103335d0df257b371fe9465f56eb8aed3f205f /drivers/pwm/pwm-omap-dmtimer.c | |
parent | pwm: add HAS_IOMEM dependency to PWM_FSL_FTM (diff) | |
download | linux-074726402b82f14ca377da0b4a4767674c3d1ff8.tar.xz linux-074726402b82f14ca377da0b4a4767674c3d1ff8.zip |
pwm: omap-dmtimer: Potential NULL dereference on error
"omap" is NULL so we can't dereference it.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
Diffstat (limited to 'drivers/pwm/pwm-omap-dmtimer.c')
-rw-r--r-- | drivers/pwm/pwm-omap-dmtimer.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pwm/pwm-omap-dmtimer.c b/drivers/pwm/pwm-omap-dmtimer.c index c453b3360605..826634ec0d5c 100644 --- a/drivers/pwm/pwm-omap-dmtimer.c +++ b/drivers/pwm/pwm-omap-dmtimer.c @@ -243,7 +243,7 @@ static int pwm_omap_dmtimer_probe(struct platform_device *pdev) omap = devm_kzalloc(&pdev->dev, sizeof(*omap), GFP_KERNEL); if (!omap) { - omap->pdata->free(dm_timer); + pdata->free(dm_timer); return -ENOMEM; } |