Skip to contentSkip to conversation

pci: mark pci_module_init() as deprecated 2nd try

PATCH In review Henne 2 participants 2 messages Sep 25, 2006 – Sep 27, 2006 PCI

lore
Share & tools
lore

Henne

author
#0 lore raw

PATCH 1/1 pci: mark pci_module_init() as deprecated 2nd try

Hi!
Since nearly all pci_module_init()'s are removed from the tree (19 left), heres the patch for 2.6.18-git4.

In the mm-patchset it's called:
mark-pci_module_init-deprecated.patch
and can be removed if acked by greg.

Greets,
Henne

From: Henrik Kretzschmar <[email protected]>

Changes the pci_module_init macro into a deprecated inline function.

---

include/linux/pci.h +10 -6
@@ -384,12 +384,6 @@
 	.vendor = PCI_ANY_ID, .device = PCI_ANY_ID, \
 	.subvendor = PCI_ANY_ID, .subdevice = PCI_ANY_ID
 
-/*
- * pci_module_init is obsolete, this stays here till we fix up all usages of it
- * in the tree.
- */
-#define pci_module_init	pci_register_driver
-
 /* these external functions are only available when PCI support is enabled */
 #ifdef CONFIG_PCI
 
@@ -547,6 +541,16 @@
 	return __pci_register_driver(driver, THIS_MODULE);
 }
 
+/*
+ * pci_module_init is obsolete, this stays here till we fix up all usages of it
+ * in the tree.
+ */
+
+static inline int __deprecated pci_module_init(struct pci_driver* drv)
+{
+	return pci_register_driver(drv);
+}
+
 void pci_unregister_driver(struct pci_driver *);
 void pci_remove_behind_bridge(struct pci_dev *);
 struct pci_driver *pci_dev_driver(const struct pci_dev *);
#1 lore raw
Quoted 7 lines · On Mon, 25 Sep 2006 21:16:02 +0200 Henne <[email protected]> wrote:

Since nearly all pci_module_init()'s are removed from the tree (19 left), heres the patch for 2.6.18-git4.

In the mm-patchset it's called:
mark-pci_module_init-deprecated.patch
and can be removed if acked by greg.

Quoted 7 lines

Greets,
Henne

From: Henrik Kretzschmar <[email protected]>

Changes the pci_module_init macro into a deprecated inline function.

You didn't need to send this patch. I already have it queued up, behind some more of the pci_module_init-conversion patches, which is the appropriate place for it. It's also behind 1,800-odd other patches.

Patience - at 200/day, we'll get there eventually.