mirror of
https://github.com/torvalds/linux.git
synced 2024-11-18 10:01:43 +00:00
usb: isp1760-if: fix memleak when platform_get_resource fail
When platform_get_resource fail, we should release_mem_region Signed-off-by: Libo Chen <libo.chen@huawei.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
9a9ef7360e
commit
72d9c8b68d
@ -373,8 +373,10 @@ static int isp1760_plat_probe(struct platform_device *pdev)
|
||||
irq_res = platform_get_resource(pdev, IORESOURCE_IRQ, 0);
|
||||
if (!irq_res) {
|
||||
pr_warning("isp1760: IRQ resource not available\n");
|
||||
return -ENODEV;
|
||||
ret = -ENODEV;
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
irqflags |= irq_res->flags & IRQF_TRIGGER_MASK;
|
||||
|
||||
if (priv) {
|
||||
|
Loading…
Reference in New Issue
Block a user