aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/pci-acpi.c
diff options
context:
space:
mode:
authorColin Ian King <colin.king@canonical.com>2020-02-10 08:52:56 +0000
committerBjorn Helgaas <bhelgaas@google.com>2020-02-10 16:37:55 -0600
commite3cdcfcea363edadebf94576c29d33a441fd5a6f (patch)
tree8435008b62c1594636e45de6c794660a411cbc7e /drivers/pci/pci-acpi.c
parentLinux 5.6-rc1 (diff)
downloadlinux-dev-e3cdcfcea363edadebf94576c29d33a441fd5a6f.tar.xz
linux-dev-e3cdcfcea363edadebf94576c29d33a441fd5a6f.zip
PCI/ACPI: Move pcie_to_hpx3_type[] from stack to static data
Move pcie_to_hpx3_type[] from the stack to static data. This reduces stack usage and also makes the object code slightly smaller. Link: https://lore.kernel.org/r/20200210085256.319424-1-colin.king@canonical.com Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'drivers/pci/pci-acpi.c')
-rw-r--r--drivers/pci/pci-acpi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pci/pci-acpi.c b/drivers/pci/pci-acpi.c
index 0c02d500158f..d914f8bc31ea 100644
--- a/drivers/pci/pci-acpi.c
+++ b/drivers/pci/pci-acpi.c
@@ -439,7 +439,7 @@ enum hpx_type3_dev_type {
static u16 hpx3_device_type(struct pci_dev *dev)
{
u16 pcie_type = pci_pcie_type(dev);
- const int pcie_to_hpx3_type[] = {
+ static const int pcie_to_hpx3_type[] = {
[PCI_EXP_TYPE_ENDPOINT] = HPX_TYPE_ENDPOINT,
[PCI_EXP_TYPE_LEG_END] = HPX_TYPE_LEG_END,
[PCI_EXP_TYPE_RC_END] = HPX_TYPE_RC_END,