Re: [PATCH] ata: pata_sl82c105: fix bridge revision use-after-free

Damien Le Moal <[email protected]>
Newsgroups gmane.linux.ide
Organization Western Digital Research
Message-ID <[email protected]>
On 2026/08/05 23:06, Hongyan Xu wrote:
> pci_get_slot() returns a referenced PCI device. Commit 44c10138fd4b
> ("PCI: Change all drivers to use pci_device->revision") replaced a
> configuration-space read with direct access to the cached revision field,
> but left that access after pci_dev_put(). The bridge may therefore be freed
> before its revision is read.
> 
> Read the revision before dropping the reference.
> 
> Fixes: 44c10138fd4b ("PCI: Change all drivers to use pci_device->revision")
> Signed-off-by: Hongyan Xu <[email protected]>

Applied to for-7.2-fixes. Thanks!

-- 
Damien Le Moal
Western Digital Research
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.