Commit cb3eaa5d authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman

i2c: move i2c-proc to i2c-sensor and clean up all usages of it.

parent 0a69163a
...@@ -196,17 +196,6 @@ config I2C_CHARDEV ...@@ -196,17 +196,6 @@ config I2C_CHARDEV
<file:Documentation/modules.txt>. <file:Documentation/modules.txt>.
The module will be called i2c-dev. The module will be called i2c-dev.
config I2C_PROC
tristate "I2C /proc interface (required for hardware sensors)"
depends on I2C && SYSCTL
help
This provides support for i2c device entries in the /proc filesystem.
The entries will be found in /proc/sys/dev/sensors.
This code is also available as a module. If you want to compile
it as a module, say M here and read <file:Documentation/modules.txt>.
The module will be called i2c-proc.
source drivers/i2c/busses/Kconfig source drivers/i2c/busses/Kconfig
source drivers/i2c/chips/Kconfig source drivers/i2c/chips/Kconfig
......
...@@ -14,5 +14,5 @@ obj-$(CONFIG_ITE_I2C_ALGO) += i2c-algo-ite.o ...@@ -14,5 +14,5 @@ obj-$(CONFIG_ITE_I2C_ALGO) += i2c-algo-ite.o
obj-$(CONFIG_ITE_I2C_ADAP) += i2c-adap-ite.o obj-$(CONFIG_ITE_I2C_ADAP) += i2c-adap-ite.o
obj-$(CONFIG_SCx200_I2C) += scx200_i2c.o obj-$(CONFIG_SCx200_I2C) += scx200_i2c.o
obj-$(CONFIG_SCx200_ACB) += scx200_acb.o obj-$(CONFIG_SCx200_ACB) += scx200_acb.o
obj-$(CONFIG_I2C_PROC) += i2c-proc.o obj-$(CONFIG_I2C_SENSOR) += i2c-sensor.o
obj-y += busses/ chips/ obj-y += busses/ chips/
# #
# Sensor device configuration # Sensor device configuration
# All depend on EXPERIMENTAL, I2C and I2C_PROC. # All depend on EXPERIMENTAL and I2C
# #
menu "I2C Hardware Sensors Chip support" menu "I2C Hardware Sensors Chip support"
config SENSORS_ADM1021 config SENSORS_ADM1021
tristate " Analog Devices ADM1021 and compatibles" tristate " Analog Devices ADM1021 and compatibles"
depends on I2C && I2C_PROC depends on I2C && EXPERIMENTAL
help help
If you say yes here you get support for Analog Devices ADM1021 If you say yes here you get support for Analog Devices ADM1021
and ADM1023 sensor chips and clones: Maxim MAX1617 and MAX1617A, and ADM1023 sensor chips and clones: Maxim MAX1617 and MAX1617A,
...@@ -24,7 +24,7 @@ config SENSORS_ADM1021 ...@@ -24,7 +24,7 @@ config SENSORS_ADM1021
config SENSORS_LM75 config SENSORS_LM75
tristate " National Semiconductors LM75 and compatibles" tristate " National Semiconductors LM75 and compatibles"
depends on I2C && I2C_PROC depends on I2C && EXPERIMENTAL
help help
If you say yes here you get support for National Semiconductor LM75 If you say yes here you get support for National Semiconductor LM75
sensor chips and clones: Dallas Semi DS75 and DS1775, TelCon sensor chips and clones: Dallas Semi DS75 and DS1775, TelCon
...@@ -39,7 +39,7 @@ config SENSORS_LM75 ...@@ -39,7 +39,7 @@ config SENSORS_LM75
config SENSORS_VIA686A config SENSORS_VIA686A
tristate " VIA686A" tristate " VIA686A"
depends on I2C && I2C_PROC depends on I2C && EXPERIMENTAL
help help
support for via686a support for via686a
If you say yes here you get support for the integrated sensors in If you say yes here you get support for the integrated sensors in
...@@ -50,4 +50,9 @@ config SENSORS_VIA686A ...@@ -50,4 +50,9 @@ config SENSORS_VIA686A
in the lm_sensors package, which you can download at in the lm_sensors package, which you can download at
http://www.lm-sensors.nu http://www.lm-sensors.nu
config I2C_SENSOR
tristate
depends on SENSORS_ADM1021 || SENSORS_LM75 || SENSORS_VIA686A
default m
endmenu endmenu
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
#include <linux/init.h> #include <linux/init.h>
#include <linux/slab.h> #include <linux/slab.h>
#include <linux/i2c.h> #include <linux/i2c.h>
#include <linux/i2c-proc.h> #include <linux/i2c-sensor.h>
/* Registers */ /* Registers */
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
#include <linux/init.h> #include <linux/init.h>
#include <linux/slab.h> #include <linux/slab.h>
#include <linux/i2c.h> #include <linux/i2c.h>
#include <linux/i2c-proc.h> #include <linux/i2c-sensor.h>
/* Addresses to scan */ /* Addresses to scan */
......
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
#include <linux/pci.h> #include <linux/pci.h>
#include <linux/delay.h> #include <linux/delay.h>
#include <linux/i2c.h> #include <linux/i2c.h>
#include <linux/i2c-proc.h> #include <linux/i2c-sensor.h>
#include <linux/init.h> #include <linux/init.h>
#include <asm/io.h> #include <asm/io.h>
......
/* /*
i2c-proc.c - Part of lm_sensors, Linux kernel modules for hardware i2c-sensor.c - Part of lm_sensors, Linux kernel modules for hardware
monitoring monitoring
Copyright (c) 1998 - 2001 Frodo Looijaard <frodol@dds.nl> and Copyright (c) 1998 - 2001 Frodo Looijaard <frodol@dds.nl> and
Mark D. Studebaker <mdsxyz123@yahoo.com> Mark D. Studebaker <mdsxyz123@yahoo.com>
...@@ -19,10 +19,6 @@ ...@@ -19,10 +19,6 @@
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/ */
/*
This driver puts entries in /proc/sys/dev/sensors for each I2C device
*/
/* #define DEBUG 1 */ /* #define DEBUG 1 */
#include <linux/module.h> #include <linux/module.h>
...@@ -30,11 +26,10 @@ ...@@ -30,11 +26,10 @@
#include <linux/slab.h> #include <linux/slab.h>
#include <linux/ctype.h> #include <linux/ctype.h>
#include <linux/sysctl.h> #include <linux/sysctl.h>
#include <linux/proc_fs.h>
#include <linux/init.h> #include <linux/init.h>
#include <linux/ioport.h> #include <linux/ioport.h>
#include <linux/i2c.h> #include <linux/i2c.h>
#include <linux/i2c-proc.h> #include <linux/i2c-sensor.h>
#include <asm/uaccess.h> #include <asm/uaccess.h>
...@@ -168,20 +163,20 @@ int i2c_detect(struct i2c_adapter *adapter, ...@@ -168,20 +163,20 @@ int i2c_detect(struct i2c_adapter *adapter,
return 0; return 0;
} }
static int __init i2c_proc_init(void) static int __init i2c_sensor_init(void)
{ {
return 0; return 0;
} }
static void __exit i2c_proc_exit(void) static void __exit i2c_sensor_exit(void)
{ {
} }
EXPORT_SYMBOL(i2c_detect); EXPORT_SYMBOL(i2c_detect);
MODULE_AUTHOR("Frodo Looijaard <frodol@dds.nl>"); MODULE_AUTHOR("Frodo Looijaard <frodol@dds.nl>");
MODULE_DESCRIPTION("i2c-proc driver"); MODULE_DESCRIPTION("i2c-sensor driver");
MODULE_LICENSE("GPL"); MODULE_LICENSE("GPL");
module_init(i2c_proc_init); module_init(i2c_sensor_init);
module_exit(i2c_proc_exit); module_exit(i2c_sensor_exit);
/* /*
i2c-proc.h - Part of the i2c package i2c-sensor.h - Part of the i2c package
was originally sensors.h - Part of lm_sensors, Linux kernel modules was originally sensors.h - Part of lm_sensors, Linux kernel modules
for hardware monitoring for hardware monitoring
Copyright (c) 1998, 1999 Frodo Looijaard <frodol@dds.nl> Copyright (c) 1998, 1999 Frodo Looijaard <frodol@dds.nl>
...@@ -19,8 +19,8 @@ ...@@ -19,8 +19,8 @@
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/ */
#ifndef _LINUX_I2C_PROC_H #ifndef _LINUX_I2C_SENSOR_H
#define _LINUX_I2C_PROC_H #define _LINUX_I2C_SENSOR_H
#include <linux/sysctl.h> #include <linux/sysctl.h>
...@@ -369,5 +369,5 @@ struct i2c_chips_data { ...@@ -369,5 +369,5 @@ struct i2c_chips_data {
char name[SENSORS_PREFIX_MAX + 13]; char name[SENSORS_PREFIX_MAX + 13];
}; };
#endif /* def _LINUX_I2C_PROC_H */ #endif /* def _LINUX_I2C_SENSOR_H */
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment