Re: [PATCH 7/8] PCI: Make pcie_link_speed variable public & export pci_set_target_speed()
From: Jeff Johnson
Date: Wed Feb 19 2025 - 12:37:04 EST
On 2/16/2025 10:34 PM, Krishna Chaitanya Chundru wrote:
> diff --git a/include/linux/pci.h b/include/linux/pci.h
> index 58f1de626c37..8a3b3195122d 100644
> --- a/include/linux/pci.h
> +++ b/include/linux/pci.h
> @@ -305,6 +305,7 @@ enum pci_bus_speed {
>
> enum pci_bus_speed pcie_get_speed_cap(struct pci_dev *dev);
> enum pcie_link_width pcie_get_width_cap(struct pci_dev *dev);
> +extern const unsigned char pcie_link_speed[];
This, and the Patch 8/8 change that uses it, make me cringe.
Should we instead have a functional interface so that the client calls a
function to perform the lookup?
/jeff