ChangeSet 1.1587.12.46, 2004/04/30 14:18:21-07:00, eike-hotplug@sf-tec.de

[PATCH] PCI Express Hotplug: use new style of module parameters

This converts PCI Express Hotplug to the new style of module parameter
handling.


 drivers/pci/hotplug/pciehp.h      |    6 +-----
 drivers/pci/hotplug/pciehp_core.c |    7 ++++---
 2 files changed, 5 insertions(+), 8 deletions(-)


diff -Nru a/drivers/pci/hotplug/pciehp.h b/drivers/pci/hotplug/pciehp.h
--- a/drivers/pci/hotplug/pciehp.h	Mon May 17 17:01:13 2004
+++ b/drivers/pci/hotplug/pciehp.h	Mon May 17 17:01:13 2004
@@ -35,11 +35,7 @@
 #include <asm/io.h>		
 #include "pci_hotplug.h"
 
-#if !defined(CONFIG_HOTPLUG_PCI_PCIE_MODULE)
-	#define MY_NAME	"pciehp"
-#else
-	#define MY_NAME	THIS_MODULE->name
-#endif
+#define MY_NAME	"pciehp"
 
 extern int pciehp_poll_mode;
 extern int pciehp_poll_time;
diff -Nru a/drivers/pci/hotplug/pciehp_core.c b/drivers/pci/hotplug/pciehp_core.c
--- a/drivers/pci/hotplug/pciehp_core.c	Mon May 17 17:01:13 2004
+++ b/drivers/pci/hotplug/pciehp_core.c	Mon May 17 17:01:13 2004
@@ -29,6 +29,7 @@
 
 #include <linux/config.h>
 #include <linux/module.h>
+#include <linux/moduleparam.h>
 #include <linux/kernel.h>
 #include <linux/types.h>
 #include <linux/proc_fs.h>
@@ -56,9 +57,9 @@
 MODULE_DESCRIPTION(DRIVER_DESC);
 MODULE_LICENSE("GPL");
 
-MODULE_PARM(pciehp_debug, "i");
-MODULE_PARM(pciehp_poll_mode, "i");
-MODULE_PARM(pciehp_poll_time, "i");
+module_param(pciehp_debug, bool, 644);
+module_param(pciehp_poll_mode, bool, 644);
+module_param(pciehp_poll_time, int, 644);
 MODULE_PARM_DESC(pciehp_debug, "Debugging mode enabled or not");
 MODULE_PARM_DESC(pciehp_poll_mode, "Using polling mechanism for hot-plug events or not");
 MODULE_PARM_DESC(pciehp_poll_time, "Polling mechanism frequency, in seconds");
