PCI/sysfs: Define SMBIOS label attributes with DEVICE_ATTR*()
authorKrzysztof Wilczyński <kw@linux.com>
Tue, 27 Apr 2021 19:18:26 +0000 (14:18 -0500)
committerBjorn Helgaas <bhelgaas@google.com>
Thu, 29 Apr 2021 15:07:31 +0000 (10:07 -0500)
commit4dd7dfa166d220a245ee21f499bb1084bc249393
tree26ebc7a0a0b3926a7600cf14701303d71aee4640
parent2ed6494155444dd4d2005869edce1ae73b4f23ca
PCI/sysfs: Define SMBIOS label attributes with DEVICE_ATTR*()

Use DEVICE_ATTR*() to simplify definition of the SMBIOS label attributes.
No functional change intended.

Note that dev_attr_smbios_label requires __ATTR() because the "label"
attribute can be exposed via either ACPI or SMBIOS, and we already have the
ACPI label_show() function in this file.

[bhelgaas: split to separate patch]
Link: https://lore.kernel.org/r/20210416205856.3234481-6-kw@linux.com
Signed-off-by: Krzysztof Wilczyński <kw@linux.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
drivers/pci/pci-label.c