diff mbox

[3/3] PCI: mark pci_scan_bus_parented() as __deprecated

Message ID 1371747665-12768-4-git-send-email-liuj97@gmail.com (mailing list archive)
State New, archived
Delegated to: Bjorn Helgaas
Headers show

Commit Message

Jiang Liu June 20, 2013, 5:01 p.m. UTC
From: Jiang Liu <jiang.liu@huawei.com>

Mark pci_scan_bus_parented() as __deprecated and clean up outdated
comments.

Signed-off-by: Jiang Liu <jiang.liu@huawei.com>
Cc: Chris Metcalf <cmetcalf@tilera.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Thierry Reding <thierry.reding@avionic-design.de>
Cc: linux-kernel@vger.kernel.org
Cc: linux-pci@vger.kernel.org
---
 arch/tile/kernel/pci.c | 3 ---
 include/linux/pci.h    | 4 ++--
 2 files changed, 2 insertions(+), 5 deletions(-)

Comments

Greg KH June 20, 2013, 5:08 p.m. UTC | #1
On Fri, Jun 21, 2013 at 01:01:05AM +0800, Jiang Liu wrote:
> From: Jiang Liu <jiang.liu@huawei.com>
> 
> Mark pci_scan_bus_parented() as __deprecated and clean up outdated
> comments.

Why not just delete the function, if no in-kernel users are calling it,
it's no longer needed at all.

thanks,

greg k-h
--
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
Jiang Liu June 20, 2013, 5:14 p.m. UTC | #2
On 06/21/2013 01:08 AM, Greg Kroah-Hartman wrote:
> On Fri, Jun 21, 2013 at 01:01:05AM +0800, Jiang Liu wrote:
>> From: Jiang Liu <jiang.liu@huawei.com>
>>
>> Mark pci_scan_bus_parented() as __deprecated and clean up outdated
>> comments.
> 
> Why not just delete the function, if no in-kernel users are calling it,
> it's no longer needed at all.
Hi Greg,
I thought that may break out of tree drivers, so give a warning first
for smooth transitions. Any guidelines here? I have some other similar
cases to keep some exported symbols just for out of tree drivers.
Regards!
Gerry

> 
> thanks,
> 
> greg k-h
> 

--
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
Greg KH June 20, 2013, 5:31 p.m. UTC | #3
On Fri, Jun 21, 2013 at 01:14:23AM +0800, Jiang Liu wrote:
> On 06/21/2013 01:08 AM, Greg Kroah-Hartman wrote:
> > On Fri, Jun 21, 2013 at 01:01:05AM +0800, Jiang Liu wrote:
> >> From: Jiang Liu <jiang.liu@huawei.com>
> >>
> >> Mark pci_scan_bus_parented() as __deprecated and clean up outdated
> >> comments.
> > 
> > Why not just delete the function, if no in-kernel users are calling it,
> > it's no longer needed at all.
> Hi Greg,
> I thought that may break out of tree drivers, so give a warning first
> for smooth transitions. Any guidelines here? I have some other similar
> cases to keep some exported symbols just for out of tree drivers.

Don't care about out-of-tree drivers, as they obviously don't care about
you, or the in-kernel code.  You are doing no one any favors by keeping
these functions around for a while, only delaying the time that these
out-of-tree drivers will have to be updated, they will not be updated by
a mere __depreciated warning.

So just delete them, that's what the rest of the kernel does, it's the
price that out-of-tree drivers pay, and the authors of them know this
quite well.

thanks,

greg k-h
--
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

diff --git a/arch/tile/kernel/pci.c b/arch/tile/kernel/pci.c
index 67237d3..936e087 100644
--- a/arch/tile/kernel/pci.c
+++ b/arch/tile/kernel/pci.c
@@ -309,9 +309,6 @@  int __init pcibios_init(void)
 			 *
 			 * It reads the PCI tree for this bus into the Linux
 			 * data structures.
-			 *
-			 * This is inlined in linux/pci.h and calls into
-			 * pci_scan_bus_parented() in probe.c.
 			 */
 			pci_add_resource(&resources, &ioport_resource);
 			pci_add_resource(&resources, &iomem_resource);
diff --git a/include/linux/pci.h b/include/linux/pci.h
index f1229c7..b72d275 100644
--- a/include/linux/pci.h
+++ b/include/linux/pci.h
@@ -720,8 +720,8 @@  void pcibios_bus_to_resource(struct pci_dev *dev, struct resource *res,
 void pcibios_scan_specific_bus(int busn);
 struct pci_bus *pci_find_bus(int domain, int busnr);
 void pci_bus_add_devices(const struct pci_bus *bus);
-struct pci_bus *pci_scan_bus_parented(struct device *parent, int bus,
-				      struct pci_ops *ops, void *sysdata);
+struct pci_bus * __deprecated pci_scan_bus_parented(struct device *parent,
+			int bus, struct pci_ops *ops, void *sysdata);
 struct pci_bus *pci_scan_bus(int bus, struct pci_ops *ops, void *sysdata);
 struct pci_bus *pci_create_root_bus(struct device *parent, int bus,
 				    struct pci_ops *ops, void *sysdata,