diff options
| author | Wentao Liang <vulab@iscas.ac.cn> | 2026-09-17 10:20:51 +0000 |
|---|---|---|
| committer | Miquel Raynal <miquel.raynal@bootlin.com> | 2026-09-25 15:40:37 +0200 |
| commit | 1a122f5fecbabd47b81b1be3f0934f57b78aad42 (patch) | |
| tree | eb6eafdce1bab6d9f1d9419050316587d45a0126 /scripts/Makefile.thinlto | |
| parent | cfc5ebc9540e29f8f96db88bbfa261139e5afedb (diff) | |
| download | linux-1a122f5fecbabd47b81b1be3f0934f57b78aad42.tar.gz linux-1a122f5fecbabd47b81b1be3f0934f57b78aad42.zip | |
mtd: amd76xrom: Fix PCI device reference leak in amd76xrom_init_one()
init_amd76xrom() obtains the PCI device with pci_get_device() and
hands the reference over to amd76xrom_init_one(), which stores it in
window->pdev. When reserving the ROM window fails, that function
returns -EBUSY directly instead of going through amd76xrom_cleanup(),
so the reference is neither released nor cleared.
Drop the reference and clear window->pdev on that path.
Fixes: dd8e9ed6ed54 ("[MTD] Switch to pci_get_device and do ref counting")
Cc: stable@vger.kernel.org
Signed-off-by: Wentao Liang <vulab@iscas.ac.cn>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Diffstat (limited to 'scripts/Makefile.thinlto')
0 files changed, 0 insertions, 0 deletions
