mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-19 11:43:40 +00:00
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>
This commit is contained in:
parent
36d5be4bc9
commit
074726402b
@ -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;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user