Skip to content

Commit

Permalink
hwmon: normal_i2c arrays should be const
Browse files Browse the repository at this point in the history
Signed-off-by: Mark M. Hoffman <[email protected]>
  • Loading branch information
Mark M. Hoffman committed Feb 19, 2008
1 parent 57df46d commit 25e9c86
Show file tree
Hide file tree
Showing 41 changed files with 55 additions and 60 deletions.
2 changes: 1 addition & 1 deletion drivers/hwmon/ad7418.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#define DRV_VERSION "0.3"

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x28, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x28, I2C_CLIENT_END };
/* Insmod parameters */
I2C_CLIENT_INSMOD_3(ad7416, ad7417, ad7418);

Expand Down
6 changes: 2 additions & 4 deletions drivers/hwmon/adm1021.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,8 @@


/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x18, 0x19, 0x1a,
0x29, 0x2a, 0x2b,
0x4c, 0x4d, 0x4e,
I2C_CLIENT_END };
static const unsigned short normal_i2c[] = {
0x18, 0x19, 0x1a, 0x29, 0x2a, 0x2b, 0x4c, 0x4d, 0x4e, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_8(adm1021, adm1023, max1617, max1617a, thmc10, lm84, gl523sm,
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/adm1025.c
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
* NE1619 has two possible addresses: 0x2c and 0x2d.
*/

static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };

/*
* Insmod parameters
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/adm1026.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
#include <linux/mutex.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(adm1026);
Expand Down
6 changes: 2 additions & 4 deletions drivers/hwmon/adm1029.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,8 @@
* Addresses to scan
*/

static unsigned short normal_i2c[] = {
0x28, 0x29, 0x2a,
0x2b, 0x2c, 0x2d,
0x2e, 0x2f, I2C_CLIENT_END
static const unsigned short normal_i2c[] = { 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d,
0x2e, 0x2f, I2C_CLIENT_END
};

/*
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/adm1031.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
#define ADM1031_CONF2_TEMP_ENABLE(chan) (0x10 << (chan))

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_2(adm1030, adm1031);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/adm9240.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
#include <linux/mutex.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, 0x2f,
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, 0x2f,
I2C_CLIENT_END };

/* Insmod parameters */
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/ads7828.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
#define ADS7828_INT_VREF_MV 2500 /* Internal vref is 2.5V, 2500mV */

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b,
static const unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b,
I2C_CLIENT_END };

/* Insmod parameters */
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/adt7470.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
#include <linux/log2.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2C, 0x2E, 0x2F, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2C, 0x2E, 0x2F, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(adt7470);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/adt7473.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
#include <linux/log2.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2C, 0x2D, 0x2E, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2C, 0x2D, 0x2E, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(adt7473);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/asb100.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
#include "lm75.h"

/* I2C addresses to scan */
static unsigned short normal_i2c[] = { 0x2d, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2d, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(asb100);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/atxp1.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ MODULE_AUTHOR("Sebastian Witt <[email protected]>");
#define ATXP1_VIDMASK 0x1f
#define ATXP1_GPIO1MASK 0x0f

static unsigned short normal_i2c[] = { 0x37, 0x4e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x37, 0x4e, I2C_CLIENT_END };

I2C_CLIENT_INSMOD_1(atxp1);

Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/dme1737.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ module_param(force_id, ushort, 0);
MODULE_PARM_DESC(force_id, "Override the detected device ID");

/* Addresses to scan */
static unsigned short normal_i2c[] = {0x2c, 0x2d, 0x2e, I2C_CLIENT_END};
static const unsigned short normal_i2c[] = {0x2c, 0x2d, 0x2e, I2C_CLIENT_END};

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(dme1737);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/ds1621.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
#include "lm75.h"

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b, 0x4c,
static const unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b, 0x4c,
0x4d, 0x4e, 0x4f, I2C_CLIENT_END };

/* Insmod parameters */
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/f75375s.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
#include <linux/f75375s.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2d, 0x2e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2d, 0x2e, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_2(f75373, f75375);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/fscher.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
* Addresses to scan
*/

static unsigned short normal_i2c[] = { 0x73, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x73, I2C_CLIENT_END };

/*
* Insmod parameters
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/fschmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
#include <linux/dmi.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x73, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x73, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_5(fscpos, fscher, fscscy, fschrc, fschmd);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/fscpos.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
/*
* Addresses to scan
*/
static unsigned short normal_i2c[] = { 0x73, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x73, I2C_CLIENT_END };

/*
* Insmod parameters
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/gl518sm.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
#include <linux/sysfs.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_2(gl518sm_r00, gl518sm_r80);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/gl520sm.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ module_param(extra_sensor_type, ushort, 0);
MODULE_PARM_DESC(extra_sensor_type, "Type of extra sensor (0=autodetect, 1=temperature, 2=voltage)");

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(gl520sm);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/lm63.c
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
* Address is fully defined internally and cannot be changed.
*/

static unsigned short normal_i2c[] = { 0x4c, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x4c, I2C_CLIENT_END };

/*
* Insmod parameters
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/lm75.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@


/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b, 0x4c,
static const unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b, 0x4c,
0x4d, 0x4e, 0x4f, I2C_CLIENT_END };

/* Insmod parameters */
Expand Down
3 changes: 2 additions & 1 deletion drivers/hwmon/lm77.c
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@
#include <linux/mutex.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b,
I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(lm77);
Expand Down
4 changes: 2 additions & 2 deletions drivers/hwmon/lm78.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@
static struct platform_device *pdev;

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d,
0x2e, 0x2f, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d,
0x2e, 0x2f, I2C_CLIENT_END };
static unsigned short isa_address = 0x290;

/* Insmod parameters */
Expand Down
4 changes: 2 additions & 2 deletions drivers/hwmon/lm80.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@
#include <linux/mutex.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x28, 0x29, 0x2a, 0x2b, 0x2c,
0x2d, 0x2e, 0x2f, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d,
0x2e, 0x2f, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(lm80);
Expand Down
6 changes: 2 additions & 4 deletions drivers/hwmon/lm83.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,8 @@
* addresses.
*/

static unsigned short normal_i2c[] = { 0x18, 0x19, 0x1a,
0x29, 0x2a, 0x2b,
0x4c, 0x4d, 0x4e,
I2C_CLIENT_END };
static const unsigned short normal_i2c[] = {
0x18, 0x19, 0x1a, 0x29, 0x2a, 0x2b, 0x4c, 0x4d, 0x4e, I2C_CLIENT_END };

/*
* Insmod parameters
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/lm85.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
#include <linux/mutex.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_6(lm85b, lm85c, adm1027, adt7463, emc6d100, emc6d102);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/lm87.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
* LM87 has three possible addresses: 0x2c, 0x2d and 0x2e.
*/

static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };

/*
* Insmod parameters
Expand Down
6 changes: 2 additions & 4 deletions drivers/hwmon/lm90.c
Original file line number Diff line number Diff line change
Expand Up @@ -101,10 +101,8 @@
* 0x4c, 0x4d or 0x4e.
*/

static unsigned short normal_i2c[] = { 0x18, 0x19, 0x1a,
0x29, 0x2a, 0x2b,
0x4c, 0x4d, 0x4e,
I2C_CLIENT_END };
static const unsigned short normal_i2c[] = {
0x18, 0x19, 0x1a, 0x29, 0x2a, 0x2b, 0x4c, 0x4d, 0x4e, I2C_CLIENT_END };

/*
* Insmod parameters
Expand Down
4 changes: 2 additions & 2 deletions drivers/hwmon/lm92.c
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@

/* The LM92 and MAX6635 have 2 two-state pins for address selection,
resulting in 4 possible addresses. */
static unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b,
I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x48, 0x49, 0x4a, 0x4b,
I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(lm92);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/lm93.c
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@
I2C_FUNC_SMBUS_WORD_DATA)

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(lm93);
Expand Down
6 changes: 2 additions & 4 deletions drivers/hwmon/max1619.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,8 @@
#include <linux/mutex.h>
#include <linux/sysfs.h>

static unsigned short normal_i2c[] = { 0x18, 0x19, 0x1a,
0x29, 0x2a, 0x2b,
0x4c, 0x4d, 0x4e,
I2C_CLIENT_END };
static const unsigned short normal_i2c[] = {
0x18, 0x19, 0x1a, 0x29, 0x2a, 0x2b, 0x4c, 0x4d, 0x4e, I2C_CLIENT_END };

/*
* Insmod parameters
Expand Down
3 changes: 2 additions & 1 deletion drivers/hwmon/max6650.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@
* Addresses to scan. There are four disjoint possibilities, by pin config.
*/

static unsigned short normal_i2c[] = {0x1b, 0x1f, 0x48, 0x4b, I2C_CLIENT_END};
static const unsigned short normal_i2c[] = {0x1b, 0x1f, 0x48, 0x4b,
I2C_CLIENT_END};

/*
* Insmod parameters
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/smsc47m192.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
#include <linux/mutex.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(smsc47m192);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/thmc50.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
MODULE_LICENSE("GPL");

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_2(thmc50, adm1022);
Expand Down
4 changes: 2 additions & 2 deletions drivers/hwmon/w83781d.c
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@
static struct platform_device *pdev;

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d,
0x2e, 0x2f, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x28, 0x29, 0x2a, 0x2b, 0x2c, 0x2d,
0x2e, 0x2f, I2C_CLIENT_END };
static unsigned short isa_address = 0x290;

/* Insmod parameters */
Expand Down
3 changes: 2 additions & 1 deletion drivers/hwmon/w83791d.c
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@
#define NUMBER_OF_TEMPIN 3

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, 0x2f, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, 0x2f,
I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(w83791d);
Expand Down
3 changes: 2 additions & 1 deletion drivers/hwmon/w83792d.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@
#include <linux/sysfs.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, 0x2f, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, 0x2f,
I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(w83792d);
Expand Down
3 changes: 2 additions & 1 deletion drivers/hwmon/w83793.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@
#include <linux/mutex.h>

/* Addresses to scan */
static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, 0x2f, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, 0x2f,
I2C_CLIENT_END };

/* Insmod parameters */
I2C_CLIENT_INSMOD_1(w83793);
Expand Down
2 changes: 1 addition & 1 deletion drivers/hwmon/w83l785ts.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
* Address is fully defined internally and cannot be changed.
*/

static unsigned short normal_i2c[] = { 0x2e, I2C_CLIENT_END };
static const unsigned short normal_i2c[] = { 0x2e, I2C_CLIENT_END };

/*
* Insmod parameters
Expand Down
Loading

0 comments on commit 25e9c86

Please sign in to comment.