]> www.infradead.org Git - users/dwmw2/linux.git/commitdiff
Documentation: devres: fix error about PCI devres
authorPhilipp Stanner <pstanner@redhat.com>
Fri, 9 Aug 2024 09:52:48 +0000 (11:52 +0200)
committerJonathan Corbet <corbet@lwn.net>
Fri, 16 Aug 2024 22:29:53 +0000 (16:29 -0600)
The documentation states that pcim_enable_device() will make "all PCI
ops" managed. This is totally false, only a small subset of PCI
functions become managed that way. Implicating otherwise has caused at
least one bug so far, namely in commit 8558de401b5f ("drm/vboxvideo: use
managed pci functions").

Change the function summary so the functions dangerous behavior becomes
obvious.

Signed-off-by: Philipp Stanner <pstanner@redhat.com>
Acked-by: Bjorn Helgaas <bhelgaas@google.com>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Link: https://lore.kernel.org/r/20240809095248.14220-2-pstanner@redhat.com
Documentation/driver-api/driver-model/devres.rst

index ac9ee7441887dd5ba2ffbadd299b317198d8c8fe..5f2ee8d717b1deafb43a60b03dbc5d5bc6b4875a 100644 (file)
@@ -391,7 +391,7 @@ PCI
   devm_pci_remap_cfgspace()    : ioremap PCI configuration space
   devm_pci_remap_cfg_resource()        : ioremap PCI configuration space resource
 
-  pcim_enable_device()         : after success, all PCI ops become managed
+  pcim_enable_device()         : after success, some PCI ops become managed
   pcim_iomap()                 : do iomap() on a single BAR
   pcim_iomap_regions()         : do request_region() and iomap() on multiple BARs
   pcim_iomap_regions_request_all() : do request_region() on all and iomap() on multiple BARs