PCI: sysfs: Remove unused attribute groups
authorBen Dooks <ben.dooks@codethink.co.uk>
Wed, 16 Oct 2019 08:03:24 +0000 (09:03 +0100)
committerBjorn Helgaas <bhelgaas@google.com>
Thu, 21 Nov 2019 13:52:31 +0000 (07:52 -0600)
56c1af4606f0 ("PCI: Add sysfs max_link_speed/width,
current_link_speed/width, etc") added the following objects, but they are
unused, so remove them:

  pci_bridge_group
  pci_bridge_groups
  pcie_dev_group
  pcie_dev_groups

This fixes the following warnings from sparse:

  drivers/pci/pci-sysfs.c:1546:30: warning: symbol 'pci_bridge_groups' was not declared. Should it be static?
  drivers/pci/pci-sysfs.c:1555:30: warning: symbol 'pcie_dev_groups' was not declared. Should it be static?

Link: https://lore.kernel.org/r/20191016080324.12864-1-ben.dooks@codethink.co.uk
Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
drivers/pci/pci-sysfs.c

index 7934129545290480b573f03976e8d5e5e220ef01..eaffb477c5bf8a4275259a42d1ca190f99ec70a0 100644 (file)
@@ -1539,24 +1539,6 @@ const struct attribute_group *pci_dev_groups[] = {
        NULL,
 };
 
-static const struct attribute_group pci_bridge_group = {
-       .attrs = pci_bridge_attrs,
-};
-
-const struct attribute_group *pci_bridge_groups[] = {
-       &pci_bridge_group,
-       NULL,
-};
-
-static const struct attribute_group pcie_dev_group = {
-       .attrs = pcie_dev_attrs,
-};
-
-const struct attribute_group *pcie_dev_groups[] = {
-       &pcie_dev_group,
-       NULL,
-};
-
 static const struct attribute_group pci_dev_hp_attr_group = {
        .attrs = pci_dev_hp_attrs,
        .is_visible = pci_dev_hp_attrs_are_visible,