diff options
| author | Myeonghun Pak <mhun512@gmail.com> | 2026-07-01 20:21:47 +0900 |
|---|---|---|
| committer | Helge Deller <deller@gmx.de> | 2026-08-10 08:13:25 +0200 |
| commit | 95a627143a696f70e17be5ed3b1e733bb6724b46 (patch) | |
| tree | bb197616ebf95d1a6880b331fc42c5783e951f16 /tools/perf/scripts/python/net_dropmonitor.py | |
| parent | de8db23aa7c337e606fca9faf48b3ba72968597a (diff) | |
fbdev: tdfxfb: fix PCI enable cleanup with pcim_enable_device()
tdfxfb_probe() enables the PCI device with pci_enable_device(), but
several failure paths after that point return without disabling it. The
framebuffer_alloc() failure path returns -ENOMEM directly, and the later
shared out_err path releases the framebuffer and returns -ENXIO without
balancing the PCI enable state.
The successful probe path has the same imbalance because tdfxfb_remove()
releases the framebuffer, mappings and regions, but never calls
pci_disable_device().
Use pcim_enable_device() so the PCI device is disabled automatically on
probe failure and driver detach.
This issue was identified during our ongoing static-analysis research while
reviewing kernel code.
Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Co-developed-by: Ijae Kim <ae878000@gmail.com>
Signed-off-by: Ijae Kim <ae878000@gmail.com>
Signed-off-by: Myeonghun Pak <mhun512@gmail.com>
Signed-off-by: Helge Deller <deller@gmx.de>
Diffstat (limited to 'tools/perf/scripts/python/net_dropmonitor.py')
0 files changed, 0 insertions, 0 deletions
