Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 72d9c8b6 authored by Libo Chen's avatar Libo Chen Committed by Greg Kroah-Hartman
Browse files

usb: isp1760-if: fix memleak when platform_get_resource fail



When platform_get_resource fail, we should release_mem_region

Signed-off-by: default avatarLibo Chen <libo.chen@huawei.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 9a9ef736
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -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) {