drivers/pci/pcie-sysfs.c:27:25: sparse: symbol 'pcie_link_disabl
Subsystems (2)
PATCH 104/104 drivers/pci/pcie-sysfs.c:27:25: sparse: symbol 'pcie_link_disabl
Hi Yinghai,
There are new sparse warnings show up in
tree: git://git.kernel.org/pub/scm/linux/kernel/git/yinghai/linux-yinghai.git for-pci-pcie-link head: d6396cb3ed85b8a95bd07d9c8f8f70b96a8f3d11 commit: d6396cb3ed85b8a95bd07d9c8f8f70b96a8f3d11 [104/104] PCI: Add link_disable in /sysfs for pcie device
All sparse warnings:
+ drivers/pci/pcie-sysfs.c:27:25: sparse: symbol 'pcie_link_disable_attr' was not declared. Should it be static? drivers/pci/pcie-sysfs.c:53:24: sparse: symbol 'pci_dev_pcie_attr_group' was not declared. Should it be static?
vim +27 drivers/pci/pcie-sysfs.c
24 return count;
25 }
26 Quoted 1 line
27 struct
device_attributepcie_link_disable_attr=
28 __ATTR(pcie_link_disable, 0644,
29 pcie_link_disable_show, pcie_link_disable_store);
30 Please consider folding the attached diff :-)
---
0-DAY kernel build testing backend Open Source Technology Centre
Fengguang Wu <[email protected]> Intel Corporation
drivers/pci/pcie-sysfs.c +2 -2
@@ -24,7 +24,7 @@ pcie_link_disable_store(struct device *dev, struct device_attribute *attr,return count; } -struct device_attribute pcie_link_disable_attr = +static struct device_attribute pcie_link_disable_attr =__ATTR (pcie_link_disable,0644 , pcie_link_disable_show, pcie_link_disable_store);
@@ -50,7 +50,7 @@ static umode_t pci_dev_pcie_attrs_are_visible(struct kobject *kobj,return a->mode; } -struct attribute_group pci_dev_pcie_attr_group = { +static struct attribute_group pci_dev_pcie_attr_group = { .is_visible = pci_dev_pcie_attrs_are_visible, .attrs = pci_dev_pcie_dev_attrs, };
Re: [yinghai:for-pci-pcie-link 104/104] drivers/pci/pcie-sysfs.c:27:25: sparse: symbol 'pcie_link_di
Quoted 4 lines · On Wed, Jul 11, 2012 at 04:24:58PM +0800, [email protected] wrote:
Hi Yinghai,
There are new sparse warnings show up in
Quoted 8 lines
tree: git://git.kernel.org/pub/scm/linux/kernel/git/yinghai/linux-yinghai.git for-pci-pcie-link head: d6396cb3ed85b8a95bd07d9c8f8f70b96a8f3d11 commit: d6396cb3ed85b8a95bd07d9c8f8f70b96a8f3d11 [104/104] PCI: Add link_disable in /sysfs for pcie deviceAll sparse warnings:
+
drivers/pci/pcie-sysfs.c:27:25: sparse: symbol 'pcie_link_disable_attr' was not declared. Should it be static?drivers/pci/pcie-sysfs.c:53:24: sparse: symbol 'pci_dev_pcie_attr_group' was not declared. Should it be static?
Sorry, that 2nd sparse warning is actually false warning. The full diff won't compile.
Thanks,
Fengguang