diff mbox

pci: remove pcibios_add_platform_entries

Message ID alpine.LFD.2.11.1404171947150.1588@denkbrett (mailing list archive)
State New, archived
Delegated to: Bjorn Helgaas
Headers show

Commit Message

Sebastian Ott April 17, 2014, 5:48 p.m. UTC
Remove pcibios_add_platform_entries. Architecture specific attributes
can be achieved by setting pdev->dev.groups .

Link: https://lkml.kernel.org/r/alpine.LFD.2.11.1404141101500.1529@denkbrett
Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com>
---
 drivers/pci/pci-sysfs.c |   10 ----------
 include/linux/pci.h     |    1 -
 2 files changed, 11 deletions(-)


--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

Greg KH April 18, 2014, 2:47 a.m. UTC | #1
On Thu, Apr 17, 2014 at 07:48:07PM +0200, Sebastian Ott wrote:
> Remove pcibios_add_platform_entries. Architecture specific attributes
> can be achieved by setting pdev->dev.groups .
> 
> Link: https://lkml.kernel.org/r/alpine.LFD.2.11.1404141101500.1529@denkbrett
> Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com>

Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Bjorn Helgaas April 30, 2014, 8:52 p.m. UTC | #2
On Thu, Apr 17, 2014 at 07:48:07PM +0200, Sebastian Ott wrote:
> Remove pcibios_add_platform_entries. Architecture specific attributes
> can be achieved by setting pdev->dev.groups .
> 
> Link: https://lkml.kernel.org/r/alpine.LFD.2.11.1404141101500.1529@denkbrett
> Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com>

I cherry-picked 8e209e424f8b ("s390/pci: use pdev->dev.groups for attribute
creation") from Martin's tree and then applied this with Greg's ack to
pci/misc for v3.16.  Thanks!

> ---
>  drivers/pci/pci-sysfs.c |   10 ----------
>  include/linux/pci.h     |    1 -
>  2 files changed, 11 deletions(-)
> 
> --- a/drivers/pci/pci-sysfs.c
> +++ b/drivers/pci/pci-sysfs.c
> @@ -1272,11 +1272,6 @@ static struct bin_attribute pcie_config_
>  	.write = pci_write_config,
>  };
>  
> -int __weak pcibios_add_platform_entries(struct pci_dev *dev)
> -{
> -	return 0;
> -}
> -
>  static ssize_t reset_store(struct device *dev,
>  			   struct device_attribute *attr, const char *buf,
>  			   size_t count)
> @@ -1392,11 +1387,6 @@ int __must_check pci_create_sysfs_dev_fi
>  		pdev->rom_attr = attr;
>  	}
>  
> -	/* add platform-specific attributes */
> -	retval = pcibios_add_platform_entries(pdev);
> -	if (retval)
> -		goto err_rom_file;
> -
>  	/* add sysfs entries for various capabilities */
>  	retval = pci_create_capabilities_sysfs(pdev);
>  	if (retval)
> --- a/include/linux/pci.h
> +++ b/include/linux/pci.h
> @@ -1572,7 +1572,6 @@ extern unsigned long pci_hotplug_io_size
>  extern unsigned long pci_hotplug_mem_size;
>  
>  /* Architecture-specific versions may override these (weak) */
> -int pcibios_add_platform_entries(struct pci_dev *dev);
>  void pcibios_disable_device(struct pci_dev *dev);
>  void pcibios_set_master(struct pci_dev *dev);
>  int pcibios_set_pcie_reset_state(struct pci_dev *dev,
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

--- a/drivers/pci/pci-sysfs.c
+++ b/drivers/pci/pci-sysfs.c
@@ -1272,11 +1272,6 @@  static struct bin_attribute pcie_config_
 	.write = pci_write_config,
 };
 
-int __weak pcibios_add_platform_entries(struct pci_dev *dev)
-{
-	return 0;
-}
-
 static ssize_t reset_store(struct device *dev,
 			   struct device_attribute *attr, const char *buf,
 			   size_t count)
@@ -1392,11 +1387,6 @@  int __must_check pci_create_sysfs_dev_fi
 		pdev->rom_attr = attr;
 	}
 
-	/* add platform-specific attributes */
-	retval = pcibios_add_platform_entries(pdev);
-	if (retval)
-		goto err_rom_file;
-
 	/* add sysfs entries for various capabilities */
 	retval = pci_create_capabilities_sysfs(pdev);
 	if (retval)
--- a/include/linux/pci.h
+++ b/include/linux/pci.h
@@ -1572,7 +1572,6 @@  extern unsigned long pci_hotplug_io_size
 extern unsigned long pci_hotplug_mem_size;
 
 /* Architecture-specific versions may override these (weak) */
-int pcibios_add_platform_entries(struct pci_dev *dev);
 void pcibios_disable_device(struct pci_dev *dev);
 void pcibios_set_master(struct pci_dev *dev);
 int pcibios_set_pcie_reset_state(struct pci_dev *dev,