Show
Ignore:
Timestamp:
07/23/99 13:43:58 (15 years ago)
Author:
frodo
Message:

First step to make it possible to integrate lm_sensors modules into

the kernel.

* <kernel/init.h> is now included for all modules
* Initialization-time only functions and variables are marked with init
* EXPORT_SYMBOL or EXPORT_NO_SYMBOLS declarations added

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • lm-sensors/trunk/kernel/chips/eeprom.c

    r499 r513  
    2828#include "compat.h" 
    2929 
     30#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,1,53) 
     31#include <linux/init.h> 
     32#else 
     33#define __init 
     34#endif 
     35 
     36 
    3037/* Addresses to scan */ 
    3138static unsigned short normal_i2c[] = {SENSORS_I2C_END}; 
     
    7582#endif /* MODULE */ 
    7683 
    77 static int eeprom_init(void); 
    78 static int eeprom_cleanup(void); 
     84static int __init eeprom_init(void); 
     85static int __init eeprom_cleanup(void); 
    7986 
    8087static int eeprom_attach_adapter(struct i2c_adapter *adapter); 
     
    134141 
    135142/* Used by init/cleanup */ 
    136 static int eeprom_initialized = 0; 
     143static int __init eeprom_initialized = 0; 
    137144 
    138145/* I choose here for semi-static LM78 allocation. Complete dynamic 
     
    384391} 
    385392 
    386 int eeprom_init(void) 
     393int __init eeprom_init(void) 
    387394{ 
    388395  int res; 
     
    399406} 
    400407 
    401 int eeprom_cleanup(void) 
     408int __init eeprom_cleanup(void) 
    402409{ 
    403410  int res; 
     
    414421} 
    415422 
     423EXPORT_NO_SYMBOLS; 
    416424 
    417425#ifdef MODULE