From b63773a801ff7f7f047894a9be23616f4491aca8 Mon Sep 17 00:00:00 2001 From: Rob Herring Date: Tue, 18 Jul 2017 16:43:21 -0500 Subject: PCI: Convert to using %pOF instead of full_name() Now that we have a custom printf format specifier, convert users of full_name() to use %pOF instead. This is preparation for removing storing of the full path string for each node. Signed-off-by: Rob Herring Signed-off-by: Bjorn Helgaas Reviewed-by: Tyrel Datwyler Cc: Thomas Petazzoni Cc: Jason Cooper Cc: Thierry Reding Cc: Jonathan Hunter Cc: Benjamin Herrenschmidt Cc: Paul Mackerras Cc: Michael Ellerman --- drivers/pci/pci-sysfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'drivers/pci/pci-sysfs.c') diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c index 93e7b97765d7..c9cdc8a1d48a 100644 --- a/drivers/pci/pci-sysfs.c +++ b/drivers/pci/pci-sysfs.c @@ -556,9 +556,9 @@ static ssize_t devspec_show(struct device *dev, struct pci_dev *pdev = to_pci_dev(dev); struct device_node *np = pci_device_to_OF_node(pdev); - if (np == NULL || np->full_name == NULL) + if (np == NULL) return 0; - return sprintf(buf, "%s", np->full_name); + return sprintf(buf, "%pOF", np); } static DEVICE_ATTR_RO(devspec); #endif -- cgit v1.2.3