
From: Adrian Bunk <bunk@stusta.de>

This patch makes the following changes to the PNP code:
- make some needlessly global code static
- remove the EXPORT_SYMBOL(pnp_assign_resources) since this function
  is only used in the file it is defined in

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
---

 25-akpm/drivers/pnp/core.c         |    2 +-
 25-akpm/drivers/pnp/interface.c    |    2 +-
 25-akpm/drivers/pnp/manager.c      |    3 +--
 25-akpm/drivers/pnp/pnpbios/core.c |    4 ++--
 25-akpm/drivers/pnp/resource.c     |   10 +++++-----
 25-akpm/include/linux/pnp.h        |    2 --
 6 files changed, 10 insertions(+), 13 deletions(-)

diff -puN drivers/pnp/core.c~some-pnp-cleanups drivers/pnp/core.c
--- 25/drivers/pnp/core.c~some-pnp-cleanups	2005-02-22 18:19:43.000000000 -0800
+++ 25-akpm/drivers/pnp/core.c	2005-02-22 18:19:43.000000000 -0800
@@ -18,7 +18,7 @@
 #include "base.h"
 
 
-LIST_HEAD(pnp_protocols);
+static LIST_HEAD(pnp_protocols);
 LIST_HEAD(pnp_global);
 DEFINE_SPINLOCK(pnp_lock);
 
diff -puN drivers/pnp/interface.c~some-pnp-cleanups drivers/pnp/interface.c
--- 25/drivers/pnp/interface.c~some-pnp-cleanups	2005-02-22 18:19:43.000000000 -0800
+++ 25-akpm/drivers/pnp/interface.c	2005-02-22 18:19:43.000000000 -0800
@@ -29,7 +29,7 @@ struct pnp_info_buffer {
 
 typedef struct pnp_info_buffer pnp_info_buffer_t;
 
-int pnp_printf(pnp_info_buffer_t * buffer, char *fmt,...)
+static int pnp_printf(pnp_info_buffer_t * buffer, char *fmt,...)
 {
 	va_list args;
 	int res;
diff -puN drivers/pnp/manager.c~some-pnp-cleanups drivers/pnp/manager.c
--- 25/drivers/pnp/manager.c~some-pnp-cleanups	2005-02-22 18:19:43.000000000 -0800
+++ 25-akpm/drivers/pnp/manager.c	2005-02-22 18:19:43.000000000 -0800
@@ -300,7 +300,7 @@ static void pnp_clean_resource_table(str
  *
  * Only set depnum to 0 if the device does not have dependent options.
  */
-int pnp_assign_resources(struct pnp_dev *dev, int depnum)
+static int pnp_assign_resources(struct pnp_dev *dev, int depnum)
 {
 	struct pnp_port *port;
 	struct pnp_mem *mem;
@@ -562,7 +562,6 @@ void pnp_resource_change(struct resource
 }
 
 
-EXPORT_SYMBOL(pnp_assign_resources);
 EXPORT_SYMBOL(pnp_manual_config_dev);
 EXPORT_SYMBOL(pnp_auto_config_dev);
 EXPORT_SYMBOL(pnp_activate_dev);
diff -puN drivers/pnp/pnpbios/core.c~some-pnp-cleanups drivers/pnp/pnpbios/core.c
--- 25/drivers/pnp/pnpbios/core.c~some-pnp-cleanups	2005-02-22 18:19:43.000000000 -0800
+++ 25-akpm/drivers/pnp/pnpbios/core.c	2005-02-22 18:19:43.000000000 -0800
@@ -454,7 +454,7 @@ __setup("pnpbios=", pnpbios_setup);
 /* PnP BIOS signature: "$PnP" */
 #define PNP_SIGNATURE   (('$' << 0) + ('P' << 8) + ('n' << 16) + ('P' << 24))
 
-int __init pnpbios_probe_system(void)
+static int __init pnpbios_probe_system(void)
 {
 	union pnp_bios_install_struct *check;
 	u8 sum;
@@ -530,7 +530,7 @@ static struct dmi_system_id pnpbios_dmi_
 	{ }
 };
 
-int __init pnpbios_init(void)
+static int __init pnpbios_init(void)
 {
 	int ret;
 
diff -puN drivers/pnp/resource.c~some-pnp-cleanups drivers/pnp/resource.c
--- 25/drivers/pnp/resource.c~some-pnp-cleanups	2005-02-22 18:19:43.000000000 -0800
+++ 25-akpm/drivers/pnp/resource.c	2005-02-22 18:19:43.000000000 -0800
@@ -21,11 +21,11 @@
 #include <linux/pnp.h>
 #include "base.h"
 
-int pnp_skip_pci_scan;				/* skip PCI resource scanning */
-int pnp_reserve_irq[16] = { [0 ... 15] = -1 };	/* reserve (don't use) some IRQ */
-int pnp_reserve_dma[8] = { [0 ... 7] = -1 };	/* reserve (don't use) some DMA */
-int pnp_reserve_io[16] = { [0 ... 15] = -1 };	/* reserve (don't use) some I/O region */
-int pnp_reserve_mem[16] = { [0 ... 15] = -1 };	/* reserve (don't use) some memory region */
+static int pnp_skip_pci_scan;				/* skip PCI resource scanning */
+static int pnp_reserve_irq[16] = { [0 ... 15] = -1 };	/* reserve (don't use) some IRQ */
+static int pnp_reserve_dma[8] = { [0 ... 7] = -1 };	/* reserve (don't use) some DMA */
+static int pnp_reserve_io[16] = { [0 ... 15] = -1 };	/* reserve (don't use) some I/O region */
+static int pnp_reserve_mem[16] = { [0 ... 15] = -1 };	/* reserve (don't use) some memory region */
 
 
 /*
diff -puN include/linux/pnp.h~some-pnp-cleanups include/linux/pnp.h
--- 25/include/linux/pnp.h~some-pnp-cleanups	2005-02-22 18:19:43.000000000 -0800
+++ 25-akpm/include/linux/pnp.h	2005-02-22 18:19:43.000000000 -0800
@@ -378,7 +378,6 @@ int pnp_register_dma_resource(struct pnp
 int pnp_register_port_resource(struct pnp_option *option, struct pnp_port *data);
 int pnp_register_mem_resource(struct pnp_option *option, struct pnp_mem *data);
 void pnp_init_resource_table(struct pnp_resource_table *table);
-int pnp_assign_resources(struct pnp_dev *dev, int depnum);
 int pnp_manual_config_dev(struct pnp_dev *dev, struct pnp_resource_table *res, int mode);
 int pnp_auto_config_dev(struct pnp_dev *dev);
 int pnp_validate_config(struct pnp_dev *dev);
@@ -423,7 +422,6 @@ static inline int pnp_register_dma_resou
 static inline int pnp_register_port_resource(struct pnp_option *option, struct pnp_port *data) { return -ENODEV; }
 static inline int pnp_register_mem_resource(struct pnp_option *option, struct pnp_mem *data) { return -ENODEV; }
 static inline void pnp_init_resource_table(struct pnp_resource_table *table) { }
-static inline int pnp_assign_resources(struct pnp_dev *dev, int depnum) { return -ENODEV; }
 static inline int pnp_manual_config_dev(struct pnp_dev *dev, struct pnp_resource_table *res, int mode) { return -ENODEV; }
 static inline int pnp_auto_config_dev(struct pnp_dev *dev) { return -ENODEV; }
 static inline int pnp_validate_config(struct pnp_dev *dev) { return -ENODEV; }
_
