Re: [PATCH v6 4/4] PCI: Move devres code from pci.c to devres.c

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jan 31, 2024 at 10:00:23AM +0100, Philipp Stanner wrote:
> The file pci.c is very large and contains a number of devres-functions.
> These functions should now reside in devres.c
> ...

> +struct pci_devres *find_pci_dr(struct pci_dev *pdev)
> +{
> +	if (pci_is_managed(pdev))
> +		return devres_find(&pdev->dev, pcim_release, NULL, NULL);
> +	return NULL;
> +}
> +EXPORT_SYMBOL(find_pci_dr);

find_pci_dr() was not previously exported, and I don't think it needs
to be exported now, so I dropped the EXPORT_SYMBOL.  It's still usable
inside drivers/pci since it's declared in drivers/pci/pci.h; it's just
not usable from modules.  Let me know if I missed something.

> -static struct pci_devres *find_pci_dr(struct pci_dev *pdev)
> -{
> -	if (pci_is_managed(pdev))
> -		return devres_find(&pdev->dev, pcim_release, NULL, NULL);
> -	return NULL;
> -}




[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux