projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6815b20
)
xen/platform-pci: add missing free_irq() in error path
author
ruanjinjie
<ruanjinjie@huawei.com>
Mon, 14 Nov 2022 11:21:24 +0000
(19:21 +0800)
committer
Greg Kroah-Hartman
<gregkh@linuxfoundation.org>
Fri, 2 Dec 2022 16:41:10 +0000
(17:41 +0100)
[ Upstream commit
c53717e1e3f0d0f9129b2e0dbc6dcc5e0a8132e9
]
free_irq() is missing in case of error in platform_pci_probe(), fix that.
Signed-off-by: ruanjinjie <ruanjinjie@huawei.com>
Reviewed-by: Oleksandr Tyshchenko <oleksandr_tyshchenko@epam.com>
Link:
https://lore.kernel.org/r/20221114112124.1965611-1-ruanjinjie@huawei.com
Signed-off-by: Juergen Gross <jgross@suse.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/xen/platform-pci.c
patch
|
blob
|
history
diff --git
a/drivers/xen/platform-pci.c
b/drivers/xen/platform-pci.c
index 18f0ed8b1f93b8fab25824162f86bac9beb2d781..6ebd819338ecbacd7d74199c0424f93162e43b7c 100644
(file)
--- a/
drivers/xen/platform-pci.c
+++ b/
drivers/xen/platform-pci.c
@@
-144,7
+144,7
@@
static int platform_pci_probe(struct pci_dev *pdev,
if (ret) {
dev_warn(&pdev->dev, "Unable to set the evtchn callback "
"err=%d\n", ret);
- goto out;
+ goto
irq_
out;
}
}
@@
-152,13
+152,16
@@
static int platform_pci_probe(struct pci_dev *pdev,
grant_frames = alloc_xen_mmio(PAGE_SIZE * max_nr_gframes);
ret = gnttab_setup_auto_xlat_frames(grant_frames);
if (ret)
- goto out;
+ goto
irq_
out;
ret = gnttab_init();
if (ret)
goto grant_out;
return 0;
grant_out:
gnttab_free_auto_xlat_frames();
+irq_out:
+ if (!xen_have_vector_callback)
+ free_irq(pdev->irq, pdev);
out:
pci_release_region(pdev, 0);
mem_out: