]> www.infradead.org Git - users/jedix/linux-maple.git/commit
net: mdio: thunder: Use pure PCI devres API
authorPhilipp Stanner <phasta@kernel.org>
Fri, 25 Apr 2025 08:57:39 +0000 (10:57 +0200)
committerJakub Kicinski <kuba@kernel.org>
Mon, 28 Apr 2025 23:19:16 +0000 (16:19 -0700)
commitfad4d94d9ae5a67b76b934e544be91220b682ef1
tree0a687f37025fdbb3f95fb929dad516a7dc10b788
parent6e5f7a5b5e0c6623742298fe0d5a0d3df6be1afc
net: mdio: thunder: Use pure PCI devres API

The currently used function pci_request_regions() is one of the
problematic "hybrid devres" PCI functions, which are sometimes managed
through devres, and sometimes not (depending on whether
pci_enable_device() or pcim_enable_device() has been called before).

The PCI subsystem wants to remove this behavior and, therefore, needs to
port all users to functions that don't have this problem.

Furthermore, the PCI function being managed implies that it's not
necessary to call pci_release_regions() manually.

Remove the calls to pci_release_regions().

Replace pci_request_regions() with pcim_request_all_regions().

Signed-off-by: Philipp Stanner <phasta@kernel.org>
Reviewed-by: Jacob Keller <jacob.e.keller@intel.com>
Link: https://patch.msgid.link/20250425085740.65304-8-phasta@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/mdio/mdio-thunder.c