Browse Source

[PATCH] drivers/char/nvram.c: possible cleanups

This patch contains the following possible cleanups:
- make the needlessly global function __nvram_set_checksum static
- #if 0 the unused global function nvram_set_checksum
- remove the EXPORT_SYMBOL's for both functions

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Adrian Bunk 20 years ago
parent
commit
681ea4b930
2 changed files with 3 additions and 5 deletions
  1. 3 3
      drivers/char/nvram.c
  2. 0 2
      include/linux/nvram.h

+ 3 - 3
drivers/char/nvram.c

@@ -211,12 +211,13 @@ nvram_check_checksum(void)
 	return rv;
 	return rv;
 }
 }
 
 
-void
+static void
 __nvram_set_checksum(void)
 __nvram_set_checksum(void)
 {
 {
 	mach_set_checksum();
 	mach_set_checksum();
 }
 }
 
 
+#if 0
 void
 void
 nvram_set_checksum(void)
 nvram_set_checksum(void)
 {
 {
@@ -226,6 +227,7 @@ nvram_set_checksum(void)
 	__nvram_set_checksum();
 	__nvram_set_checksum();
 	spin_unlock_irqrestore(&rtc_lock, flags);
 	spin_unlock_irqrestore(&rtc_lock, flags);
 }
 }
+#endif  /*  0  */
 
 
 /*
 /*
  * The are the file operation function for user access to /dev/nvram
  * The are the file operation function for user access to /dev/nvram
@@ -921,6 +923,4 @@ EXPORT_SYMBOL(__nvram_write_byte);
 EXPORT_SYMBOL(nvram_write_byte);
 EXPORT_SYMBOL(nvram_write_byte);
 EXPORT_SYMBOL(__nvram_check_checksum);
 EXPORT_SYMBOL(__nvram_check_checksum);
 EXPORT_SYMBOL(nvram_check_checksum);
 EXPORT_SYMBOL(nvram_check_checksum);
-EXPORT_SYMBOL(__nvram_set_checksum);
-EXPORT_SYMBOL(nvram_set_checksum);
 MODULE_ALIAS_MISCDEV(NVRAM_MINOR);
 MODULE_ALIAS_MISCDEV(NVRAM_MINOR);

+ 0 - 2
include/linux/nvram.h

@@ -20,8 +20,6 @@ extern void __nvram_write_byte(unsigned char c, int i);
 extern void nvram_write_byte(unsigned char c, int i);
 extern void nvram_write_byte(unsigned char c, int i);
 extern int __nvram_check_checksum(void);
 extern int __nvram_check_checksum(void);
 extern int nvram_check_checksum(void);
 extern int nvram_check_checksum(void);
-extern void __nvram_set_checksum(void);
-extern void nvram_set_checksum(void);
 #endif
 #endif
 
 
 #endif  /* _LINUX_NVRAM_H */
 #endif  /* _LINUX_NVRAM_H */