aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/i2c/algos/i2c-algo-bit.c2
-rw-r--r--drivers/i2c/algos/i2c-algo-ite.c2
-rw-r--r--drivers/i2c/algos/i2c-algo-pca.c2
-rw-r--r--drivers/i2c/algos/i2c-algo-pcf.c2
-rw-r--r--drivers/i2c/algos/i2c-algo-sgi.c1
-rw-r--r--drivers/i2c/algos/i2c-algo-sibyte.c2
-rw-r--r--drivers/i2c/busses/i2c-ibm_iic.c2
-rw-r--r--drivers/i2c/busses/i2c-isa.c2
-rw-r--r--drivers/i2c/busses/i2c-mpc.c2
-rw-r--r--drivers/i2c/busses/i2c-mv64xxx.c2
-rw-r--r--drivers/media/video/bt832.c2
-rw-r--r--drivers/media/video/bttv-i2c.c2
-rw-r--r--drivers/media/video/ir-kbd-i2c.c2
-rw-r--r--drivers/media/video/ovcamchip/ov6x20.c6
-rw-r--r--drivers/media/video/ovcamchip/ov6x30.c4
-rw-r--r--drivers/media/video/ovcamchip/ovcamchip_core.c8
-rw-r--r--drivers/media/video/tda7432.c2
-rw-r--r--drivers/media/video/tda9875.c2
-rw-r--r--drivers/media/video/tda9887.c4
-rw-r--r--drivers/media/video/tuner-3036.c2
-rw-r--r--drivers/media/video/tvaudio.c6
-rw-r--r--drivers/media/video/tveeprom.c2
-rw-r--r--drivers/media/video/tvmixer.c6
-rw-r--r--drivers/usb/media/w9968cf.c2
-rw-r--r--drivers/video/matrox/matroxfb_maven.c2
-rw-r--r--include/linux/i2c-id.h128
-rw-r--r--include/linux/i2c-isa.h2
27 files changed, 95 insertions, 106 deletions
diff --git a/drivers/i2c/algos/i2c-algo-bit.c b/drivers/i2c/algos/i2c-algo-bit.c
index 6060b10ab0ce..df05df1a0ef6 100644
--- a/drivers/i2c/algos/i2c-algo-bit.c
+++ b/drivers/i2c/algos/i2c-algo-bit.c
@@ -539,8 +539,6 @@ int i2c_bit_add_bus(struct i2c_adapter *adap)
539 DEB2(dev_dbg(&adap->dev, "hw routines registered.\n")); 539 DEB2(dev_dbg(&adap->dev, "hw routines registered.\n"));
540 540
541 /* register new adapter to i2c module... */ 541 /* register new adapter to i2c module... */
542
543 adap->id |= I2C_ALGO_BIT;
544 adap->algo = &i2c_bit_algo; 542 adap->algo = &i2c_bit_algo;
545 543
546 adap->timeout = 100; /* default values, should */ 544 adap->timeout = 100; /* default values, should */
diff --git a/drivers/i2c/algos/i2c-algo-ite.c b/drivers/i2c/algos/i2c-algo-ite.c
index b460e57216e1..2db7bfc85225 100644
--- a/drivers/i2c/algos/i2c-algo-ite.c
+++ b/drivers/i2c/algos/i2c-algo-ite.c
@@ -736,8 +736,6 @@ int i2c_iic_add_bus(struct i2c_adapter *adap)
736 adap->name)); 736 adap->name));
737 737
738 /* register new adapter to i2c module... */ 738 /* register new adapter to i2c module... */
739
740 adap->id |= I2C_ALGO_IIC;
741 adap->algo = &iic_algo; 739 adap->algo = &iic_algo;
742 740
743 adap->timeout = 100; /* default values, should */ 741 adap->timeout = 100; /* default values, should */
diff --git a/drivers/i2c/algos/i2c-algo-pca.c b/drivers/i2c/algos/i2c-algo-pca.c
index be2c8abc6682..beb10edfe9c1 100644
--- a/drivers/i2c/algos/i2c-algo-pca.c
+++ b/drivers/i2c/algos/i2c-algo-pca.c
@@ -369,8 +369,6 @@ int i2c_pca_add_bus(struct i2c_adapter *adap)
369 int rval; 369 int rval;
370 370
371 /* register new adapter to i2c module... */ 371 /* register new adapter to i2c module... */
372
373 adap->id |= I2C_ALGO_PCA;
374 adap->algo = &pca_algo; 372 adap->algo = &pca_algo;
375 373
376 adap->timeout = 100; /* default values, should */ 374 adap->timeout = 100; /* default values, should */
diff --git a/drivers/i2c/algos/i2c-algo-pcf.c b/drivers/i2c/algos/i2c-algo-pcf.c
index 95f023ad8c62..6e498df1f717 100644
--- a/drivers/i2c/algos/i2c-algo-pcf.c
+++ b/drivers/i2c/algos/i2c-algo-pcf.c
@@ -474,8 +474,6 @@ int i2c_pcf_add_bus(struct i2c_adapter *adap)
474 DEB2(dev_dbg(&adap->dev, "hw routines registered.\n")); 474 DEB2(dev_dbg(&adap->dev, "hw routines registered.\n"));
475 475
476 /* register new adapter to i2c module... */ 476 /* register new adapter to i2c module... */
477
478 adap->id |= I2C_ALGO_PCF;
479 adap->algo = &pcf_algo; 477 adap->algo = &pcf_algo;
480 478
481 adap->timeout = 100; /* default values, should */ 479 adap->timeout = 100; /* default values, should */
diff --git a/drivers/i2c/algos/i2c-algo-sgi.c b/drivers/i2c/algos/i2c-algo-sgi.c
index 142505105d6f..2f8df81317ff 100644
--- a/drivers/i2c/algos/i2c-algo-sgi.c
+++ b/drivers/i2c/algos/i2c-algo-sgi.c
@@ -167,7 +167,6 @@ static struct i2c_algorithm sgi_algo = {
167 */ 167 */
168int i2c_sgi_add_bus(struct i2c_adapter *adap) 168int i2c_sgi_add_bus(struct i2c_adapter *adap)
169{ 169{
170 adap->id |= I2C_ALGO_SGI;
171 adap->algo = &sgi_algo; 170 adap->algo = &sgi_algo;
172 171
173 return i2c_add_adapter(adap); 172 return i2c_add_adapter(adap);
diff --git a/drivers/i2c/algos/i2c-algo-sibyte.c b/drivers/i2c/algos/i2c-algo-sibyte.c
index c01108ae7b69..8ed5ad12552f 100644
--- a/drivers/i2c/algos/i2c-algo-sibyte.c
+++ b/drivers/i2c/algos/i2c-algo-sibyte.c
@@ -149,8 +149,6 @@ int i2c_sibyte_add_bus(struct i2c_adapter *i2c_adap, int speed)
149 struct i2c_algo_sibyte_data *adap = i2c_adap->algo_data; 149 struct i2c_algo_sibyte_data *adap = i2c_adap->algo_data;
150 150
151 /* register new adapter to i2c module... */ 151 /* register new adapter to i2c module... */
152
153 i2c_adap->id |= I2C_ALGO_SIBYTE;
154 i2c_adap->algo = &i2c_sibyte_algo; 152 i2c_adap->algo = &i2c_sibyte_algo;
155 153
156 /* Set the frequency to 100 kHz */ 154 /* Set the frequency to 100 kHz */
diff --git a/drivers/i2c/busses/i2c-ibm_iic.c b/drivers/i2c/busses/i2c-ibm_iic.c
index f42ab909eb78..a3ed9590f028 100644
--- a/drivers/i2c/busses/i2c-ibm_iic.c
+++ b/drivers/i2c/busses/i2c-ibm_iic.c
@@ -725,7 +725,7 @@ static int __devinit iic_probe(struct ocp_device *ocp){
725 adap = &dev->adap; 725 adap = &dev->adap;
726 strcpy(adap->name, "IBM IIC"); 726 strcpy(adap->name, "IBM IIC");
727 i2c_set_adapdata(adap, dev); 727 i2c_set_adapdata(adap, dev);
728 adap->id = I2C_ALGO_OCP | I2C_HW_OCP; 728 adap->id = I2C_HW_OCP;
729 adap->algo = &iic_algo; 729 adap->algo = &iic_algo;
730 adap->client_register = NULL; 730 adap->client_register = NULL;
731 adap->client_unregister = NULL; 731 adap->client_unregister = NULL;
diff --git a/drivers/i2c/busses/i2c-isa.c b/drivers/i2c/busses/i2c-isa.c
index baae5dbc198e..bdc6806dafae 100644
--- a/drivers/i2c/busses/i2c-isa.c
+++ b/drivers/i2c/busses/i2c-isa.c
@@ -49,7 +49,7 @@ static struct i2c_algorithm isa_algorithm = {
49/* There can only be one... */ 49/* There can only be one... */
50static struct i2c_adapter isa_adapter = { 50static struct i2c_adapter isa_adapter = {
51 .owner = THIS_MODULE, 51 .owner = THIS_MODULE,
52 .id = I2C_ALGO_ISA | I2C_HW_ISA, 52 .id = I2C_HW_ISA,
53 .class = I2C_CLASS_HWMON, 53 .class = I2C_CLASS_HWMON,
54 .algo = &isa_algorithm, 54 .algo = &isa_algorithm,
55 .name = "ISA main adapter", 55 .name = "ISA main adapter",
diff --git a/drivers/i2c/busses/i2c-mpc.c b/drivers/i2c/busses/i2c-mpc.c
index 70c5ffaee6a3..f065583ddcf1 100644
--- a/drivers/i2c/busses/i2c-mpc.c
+++ b/drivers/i2c/busses/i2c-mpc.c
@@ -279,7 +279,7 @@ static struct i2c_algorithm mpc_algo = {
279static struct i2c_adapter mpc_ops = { 279static struct i2c_adapter mpc_ops = {
280 .owner = THIS_MODULE, 280 .owner = THIS_MODULE,
281 .name = "MPC adapter", 281 .name = "MPC adapter",
282 .id = I2C_ALGO_MPC107 | I2C_HW_MPC107, 282 .id = I2C_HW_MPC107,
283 .algo = &mpc_algo, 283 .algo = &mpc_algo,
284 .class = I2C_CLASS_HWMON, 284 .class = I2C_CLASS_HWMON,
285 .timeout = 1, 285 .timeout = 1,
diff --git a/drivers/i2c/busses/i2c-mv64xxx.c b/drivers/i2c/busses/i2c-mv64xxx.c
index 6e5dd4949237..eb6cc0869938 100644
--- a/drivers/i2c/busses/i2c-mv64xxx.c
+++ b/drivers/i2c/busses/i2c-mv64xxx.c
@@ -521,7 +521,7 @@ mv64xxx_i2c_probe(struct device *dev)
521 drv_data->freq_m = pdata->freq_m; 521 drv_data->freq_m = pdata->freq_m;
522 drv_data->freq_n = pdata->freq_n; 522 drv_data->freq_n = pdata->freq_n;
523 drv_data->irq = platform_get_irq(pd, 0); 523 drv_data->irq = platform_get_irq(pd, 0);
524 drv_data->adapter.id = I2C_ALGO_MV64XXX | I2C_HW_MV64XXX; 524 drv_data->adapter.id = I2C_HW_MV64XXX;
525 drv_data->adapter.algo = &mv64xxx_i2c_algo; 525 drv_data->adapter.algo = &mv64xxx_i2c_algo;
526 drv_data->adapter.owner = THIS_MODULE; 526 drv_data->adapter.owner = THIS_MODULE;
527 drv_data->adapter.class = I2C_CLASS_HWMON; 527 drv_data->adapter.class = I2C_CLASS_HWMON;
diff --git a/drivers/media/video/bt832.c b/drivers/media/video/bt832.c
index a070417e65e6..67ffed8a7fea 100644
--- a/drivers/media/video/bt832.c
+++ b/drivers/media/video/bt832.c
@@ -188,7 +188,7 @@ static int bt832_probe(struct i2c_adapter *adap)
188 if (adap->class & I2C_CLASS_TV_ANALOG) 188 if (adap->class & I2C_CLASS_TV_ANALOG)
189 return i2c_probe(adap, &addr_data, bt832_attach); 189 return i2c_probe(adap, &addr_data, bt832_attach);
190#else 190#else
191 if (adap->id == (I2C_ALGO_BIT | I2C_HW_B_BT848)) 191 if (adap->id == I2C_HW_B_BT848)
192 return i2c_probe(adap, &addr_data, bt832_attach); 192 return i2c_probe(adap, &addr_data, bt832_attach);
193#endif 193#endif
194 return 0; 194 return 0;
diff --git a/drivers/media/video/bttv-i2c.c b/drivers/media/video/bttv-i2c.c
index 82beb5a8a59c..1db95f75ac68 100644
--- a/drivers/media/video/bttv-i2c.c
+++ b/drivers/media/video/bttv-i2c.c
@@ -281,7 +281,7 @@ static struct i2c_adapter bttv_i2c_adap_hw_template = {
281 .class = I2C_CLASS_TV_ANALOG, 281 .class = I2C_CLASS_TV_ANALOG,
282#endif 282#endif
283 I2C_DEVNAME("bt878"), 283 I2C_DEVNAME("bt878"),
284 .id = I2C_ALGO_BIT | I2C_HW_B_BT848 /* FIXME */, 284 .id = I2C_HW_B_BT848 /* FIXME */,
285 .algo = &bttv_algo, 285 .algo = &bttv_algo,
286 .client_register = attach_inform, 286 .client_register = attach_inform,
287}; 287};
diff --git a/drivers/media/video/ir-kbd-i2c.c b/drivers/media/video/ir-kbd-i2c.c
index 9fc5055e001c..c2f32d522668 100644
--- a/drivers/media/video/ir-kbd-i2c.c
+++ b/drivers/media/video/ir-kbd-i2c.c
@@ -429,7 +429,7 @@ static int ir_probe(struct i2c_adapter *adap)
429 struct i2c_client c; char buf; int i,rc; 429 struct i2c_client c; char buf; int i,rc;
430 430
431 switch (adap->id) { 431 switch (adap->id) {
432 case I2C_ALGO_BIT | I2C_HW_B_BT848: 432 case I2C_HW_B_BT848:
433 probe = probe_bttv; 433 probe = probe_bttv;
434 break; 434 break;
435 case I2C_ALGO_SAA7134: 435 case I2C_ALGO_SAA7134:
diff --git a/drivers/media/video/ovcamchip/ov6x20.c b/drivers/media/video/ovcamchip/ov6x20.c
index 3433619ad93f..b3f4d266cede 100644
--- a/drivers/media/video/ovcamchip/ov6x20.c
+++ b/drivers/media/video/ovcamchip/ov6x20.c
@@ -164,10 +164,10 @@ static int ov6x20_init(struct i2c_client *c)
164 DDEBUG(4, &c->dev, "entered"); 164 DDEBUG(4, &c->dev, "entered");
165 165
166 switch (c->adapter->id) { 166 switch (c->adapter->id) {
167 case I2C_ALGO_SMBUS | I2C_HW_SMBUS_OV511: 167 case I2C_HW_SMBUS_OV511:
168 rc = ov_write_regvals(c, regvals_init_6x20_511); 168 rc = ov_write_regvals(c, regvals_init_6x20_511);
169 break; 169 break;
170 case I2C_ALGO_SMBUS | I2C_HW_SMBUS_OV518: 170 case I2C_HW_SMBUS_OV518:
171 rc = ov_write_regvals(c, regvals_init_6x20_518); 171 rc = ov_write_regvals(c, regvals_init_6x20_518);
172 break; 172 break;
173 default: 173 default:
@@ -338,7 +338,7 @@ static int ov6x20_mode_init(struct i2c_client *c, struct ovcamchip_window *win)
338 /******** Palette-specific regs ********/ 338 /******** Palette-specific regs ********/
339 339
340 /* OV518 needs 8 bit multiplexed in color mode, and 16 bit in B&W */ 340 /* OV518 needs 8 bit multiplexed in color mode, and 16 bit in B&W */
341 if (c->adapter->id == (I2C_ALGO_SMBUS | I2C_HW_SMBUS_OV518)) { 341 if (c->adapter->id == I2C_HW_SMBUS_OV518) {
342 if (win->format == VIDEO_PALETTE_GREY) 342 if (win->format == VIDEO_PALETTE_GREY)
343 ov_write_mask(c, 0x13, 0x00, 0x20); 343 ov_write_mask(c, 0x13, 0x00, 0x20);
344 else 344 else
diff --git a/drivers/media/video/ovcamchip/ov6x30.c b/drivers/media/video/ovcamchip/ov6x30.c
index 44a842379b45..6eab458ab792 100644
--- a/drivers/media/video/ovcamchip/ov6x30.c
+++ b/drivers/media/video/ovcamchip/ov6x30.c
@@ -301,7 +301,7 @@ static int ov6x30_mode_init(struct i2c_client *c, struct ovcamchip_window *win)
301 /******** Palette-specific regs ********/ 301 /******** Palette-specific regs ********/
302 302
303 if (win->format == VIDEO_PALETTE_GREY) { 303 if (win->format == VIDEO_PALETTE_GREY) {
304 if (c->adapter->id == (I2C_ALGO_SMBUS | I2C_HW_SMBUS_OV518)) { 304 if (c->adapter->id == I2C_HW_SMBUS_OV518) {
305 /* Do nothing - we're already in 8-bit mode */ 305 /* Do nothing - we're already in 8-bit mode */
306 } else { 306 } else {
307 ov_write_mask(c, 0x13, 0x20, 0x20); 307 ov_write_mask(c, 0x13, 0x20, 0x20);
@@ -313,7 +313,7 @@ static int ov6x30_mode_init(struct i2c_client *c, struct ovcamchip_window *win)
313 * Therefore, the OV6630 needs to be in 8-bit multiplexed 313 * Therefore, the OV6630 needs to be in 8-bit multiplexed
314 * output mode */ 314 * output mode */
315 315
316 if (c->adapter->id == (I2C_ALGO_SMBUS | I2C_HW_SMBUS_OV518)) { 316 if (c->adapter->id == I2C_HW_SMBUS_OV518) {
317 /* Do nothing - we want to stay in 8-bit mode */ 317 /* Do nothing - we want to stay in 8-bit mode */
318 /* Warning: Messing with reg 0x13 breaks OV518 color */ 318 /* Warning: Messing with reg 0x13 breaks OV518 color */
319 } else { 319 } else {
diff --git a/drivers/media/video/ovcamchip/ovcamchip_core.c b/drivers/media/video/ovcamchip/ovcamchip_core.c
index 54dd5612d3b8..b98c64ab7c58 100644
--- a/drivers/media/video/ovcamchip/ovcamchip_core.c
+++ b/drivers/media/video/ovcamchip/ovcamchip_core.c
@@ -296,10 +296,10 @@ static int ovcamchip_attach(struct i2c_adapter *adap)
296 * attach to adapters that are known to contain OV camera chips. */ 296 * attach to adapters that are known to contain OV camera chips. */
297 297
298 switch (adap->id) { 298 switch (adap->id) {
299 case (I2C_ALGO_SMBUS | I2C_HW_SMBUS_OV511): 299 case I2C_HW_SMBUS_OV511:
300 case (I2C_ALGO_SMBUS | I2C_HW_SMBUS_OV518): 300 case I2C_HW_SMBUS_OV518:
301 case (I2C_ALGO_SMBUS | I2C_HW_SMBUS_OVFX2): 301 case I2C_HW_SMBUS_OVFX2:
302 case (I2C_ALGO_SMBUS | I2C_HW_SMBUS_W9968CF): 302 case I2C_HW_SMBUS_W9968CF:
303 PDEBUG(1, "Adapter ID 0x%06x accepted", adap->id); 303 PDEBUG(1, "Adapter ID 0x%06x accepted", adap->id);
304 break; 304 break;
305 default: 305 default:
diff --git a/drivers/media/video/tda7432.c b/drivers/media/video/tda7432.c
index 7cb1fb3e66f9..bc6b6c0cea6d 100644
--- a/drivers/media/video/tda7432.c
+++ b/drivers/media/video/tda7432.c
@@ -328,7 +328,7 @@ static int tda7432_probe(struct i2c_adapter *adap)
328 if (adap->class & I2C_CLASS_TV_ANALOG) 328 if (adap->class & I2C_CLASS_TV_ANALOG)
329 return i2c_probe(adap, &addr_data, tda7432_attach); 329 return i2c_probe(adap, &addr_data, tda7432_attach);
330#else 330#else
331 if (adap->id == (I2C_ALGO_BIT | I2C_HW_B_BT848)) 331 if (adap->id == I2C_HW_B_BT848)
332 return i2c_probe(adap, &addr_data, tda7432_attach); 332 return i2c_probe(adap, &addr_data, tda7432_attach);
333#endif 333#endif
334 return 0; 334 return 0;
diff --git a/drivers/media/video/tda9875.c b/drivers/media/video/tda9875.c
index 566e1a5ca135..3eaf2e1211e5 100644
--- a/drivers/media/video/tda9875.c
+++ b/drivers/media/video/tda9875.c
@@ -262,7 +262,7 @@ static int tda9875_probe(struct i2c_adapter *adap)
262 if (adap->class & I2C_CLASS_TV_ANALOG) 262 if (adap->class & I2C_CLASS_TV_ANALOG)
263 return i2c_probe(adap, &addr_data, tda9875_attach); 263 return i2c_probe(adap, &addr_data, tda9875_attach);
264#else 264#else
265 if (adap->id == (I2C_ALGO_BIT | I2C_HW_B_BT848)) 265 if (adap->id == I2C_HW_B_BT848)
266 return i2c_probe(adap, &addr_data, tda9875_attach); 266 return i2c_probe(adap, &addr_data, tda9875_attach);
267#endif 267#endif
268 return 0; 268 return 0;
diff --git a/drivers/media/video/tda9887.c b/drivers/media/video/tda9887.c
index a28a395d6dfe..f1b1bb5acf70 100644
--- a/drivers/media/video/tda9887.c
+++ b/drivers/media/video/tda9887.c
@@ -618,8 +618,8 @@ static int tda9887_probe(struct i2c_adapter *adap)
618 return i2c_probe(adap, &addr_data, tda9887_attach); 618 return i2c_probe(adap, &addr_data, tda9887_attach);
619#else 619#else
620 switch (adap->id) { 620 switch (adap->id) {
621 case I2C_ALGO_BIT | I2C_HW_B_BT848: 621 case I2C_HW_B_BT848:
622 case I2C_ALGO_BIT | I2C_HW_B_RIVA: 622 case I2C_HW_B_RIVA:
623 case I2C_ALGO_SAA7134: 623 case I2C_ALGO_SAA7134:
624 return i2c_probe(adap, &addr_data, tda9887_attach); 624 return i2c_probe(adap, &addr_data, tda9887_attach);
625 break; 625 break;
diff --git a/drivers/media/video/tuner-3036.c b/drivers/media/video/tuner-3036.c
index 103def1abe3c..79203595b9c1 100644
--- a/drivers/media/video/tuner-3036.c
+++ b/drivers/media/video/tuner-3036.c
@@ -165,7 +165,7 @@ static int
165tuner_probe(struct i2c_adapter *adap) 165tuner_probe(struct i2c_adapter *adap)
166{ 166{
167 this_adap = 0; 167 this_adap = 0;
168 if (adap->id == (I2C_ALGO_BIT | I2C_HW_B_LP)) 168 if (adap->id == I2C_HW_B_LP)
169 return i2c_probe(adap, &addr_data, tuner_attach); 169 return i2c_probe(adap, &addr_data, tuner_attach);
170 return 0; 170 return 0;
171} 171}
diff --git a/drivers/media/video/tvaudio.c b/drivers/media/video/tvaudio.c
index f42a1efa8fcf..9420b5f52915 100644
--- a/drivers/media/video/tvaudio.c
+++ b/drivers/media/video/tvaudio.c
@@ -1098,7 +1098,7 @@ static int tda8425_initialize(struct CHIPSTATE *chip)
1098 /* extern */ TDA8425_S1_CH1, /* intern */ TDA8425_S1_OFF, 1098 /* extern */ TDA8425_S1_CH1, /* intern */ TDA8425_S1_OFF,
1099 /* off */ TDA8425_S1_OFF, /* on */ TDA8425_S1_CH2}; 1099 /* off */ TDA8425_S1_OFF, /* on */ TDA8425_S1_CH2};
1100 1100
1101 if (chip->c.adapter->id == (I2C_ALGO_BIT | I2C_HW_B_RIVA)) { 1101 if (chip->c.adapter->id == I2C_HW_B_RIVA) {
1102 memcpy (desc->inputmap, inputmap, sizeof (inputmap)); 1102 memcpy (desc->inputmap, inputmap, sizeof (inputmap));
1103 } 1103 }
1104 return 0; 1104 return 0;
@@ -1555,8 +1555,8 @@ static int chip_probe(struct i2c_adapter *adap)
1555 return i2c_probe(adap, &addr_data, chip_attach); 1555 return i2c_probe(adap, &addr_data, chip_attach);
1556#else 1556#else
1557 switch (adap->id) { 1557 switch (adap->id) {
1558 case I2C_ALGO_BIT | I2C_HW_B_BT848: 1558 case I2C_HW_B_BT848:
1559 case I2C_ALGO_BIT | I2C_HW_B_RIVA: 1559 case I2C_HW_B_RIVA:
1560 case I2C_ALGO_SAA7134: 1560 case I2C_ALGO_SAA7134:
1561 return i2c_probe(adap, &addr_data, chip_attach); 1561 return i2c_probe(adap, &addr_data, chip_attach);
1562 } 1562 }
diff --git a/drivers/media/video/tveeprom.c b/drivers/media/video/tveeprom.c
index 127ec38ebd60..3c3356a01cc6 100644
--- a/drivers/media/video/tveeprom.c
+++ b/drivers/media/video/tveeprom.c
@@ -534,7 +534,7 @@ static int
534tveeprom_attach_adapter (struct i2c_adapter *adapter) 534tveeprom_attach_adapter (struct i2c_adapter *adapter)
535{ 535{
536 dprintk(1,"%s: id 0x%x\n",__FUNCTION__,adapter->id); 536 dprintk(1,"%s: id 0x%x\n",__FUNCTION__,adapter->id);
537 if (adapter->id != (I2C_ALGO_BIT | I2C_HW_B_BT848)) 537 if (adapter->id != I2C_HW_B_BT848)
538 return 0; 538 return 0;
539 return i2c_probe(adapter, &addr_data, tveeprom_detect_client); 539 return i2c_probe(adapter, &addr_data, tveeprom_detect_client);
540} 540}
diff --git a/drivers/media/video/tvmixer.c b/drivers/media/video/tvmixer.c
index 51b99cdbf29e..f0635b19de30 100644
--- a/drivers/media/video/tvmixer.c
+++ b/drivers/media/video/tvmixer.c
@@ -276,9 +276,9 @@ static int tvmixer_clients(struct i2c_client *client)
276#else 276#else
277 /* TV card ??? */ 277 /* TV card ??? */
278 switch (client->adapter->id) { 278 switch (client->adapter->id) {
279 case I2C_ALGO_BIT | I2C_HW_SMBUS_VOODOO3: 279 case I2C_HW_SMBUS_VOODOO3:
280 case I2C_ALGO_BIT | I2C_HW_B_BT848: 280 case I2C_HW_B_BT848:
281 case I2C_ALGO_BIT | I2C_HW_B_RIVA: 281 case I2C_HW_B_RIVA:
282 /* ok, have a look ... */ 282 /* ok, have a look ... */
283 break; 283 break;
284 default: 284 default:
diff --git a/drivers/usb/media/w9968cf.c b/drivers/usb/media/w9968cf.c
index 908cfdf17039..83e8dd627154 100644
--- a/drivers/usb/media/w9968cf.c
+++ b/drivers/usb/media/w9968cf.c
@@ -1579,7 +1579,7 @@ static int w9968cf_i2c_init(struct w9968cf_device* cam)
1579 }; 1579 };
1580 1580
1581 static struct i2c_adapter adap = { 1581 static struct i2c_adapter adap = {
1582 .id = I2C_ALGO_SMBUS | I2C_HW_SMBUS_W9968CF, 1582 .id = I2C_HW_SMBUS_W9968CF,
1583 .class = I2C_CLASS_CAM_DIGITAL, 1583 .class = I2C_CLASS_CAM_DIGITAL,
1584 .owner = THIS_MODULE, 1584 .owner = THIS_MODULE,
1585 .client_register = w9968cf_i2c_attach_inform, 1585 .client_register = w9968cf_i2c_attach_inform,
diff --git a/drivers/video/matrox/matroxfb_maven.c b/drivers/video/matrox/matroxfb_maven.c
index 67f85344f0cc..ad60bbb16cdf 100644
--- a/drivers/video/matrox/matroxfb_maven.c
+++ b/drivers/video/matrox/matroxfb_maven.c
@@ -1271,7 +1271,7 @@ ERROR0:;
1271} 1271}
1272 1272
1273static int maven_attach_adapter(struct i2c_adapter* adapter) { 1273static int maven_attach_adapter(struct i2c_adapter* adapter) {
1274 if (adapter->id == (I2C_ALGO_BIT | I2C_HW_B_G400)) 1274 if (adapter->id == I2C_HW_B_G400)
1275 return i2c_probe(adapter, &addr_data, &maven_detect_client); 1275 return i2c_probe(adapter, &addr_data, &maven_detect_client);
1276 return 0; 1276 return 0;
1277} 1277}
diff --git a/include/linux/i2c-id.h b/include/linux/i2c-id.h
index 33f08258f22b..5b72f664cc21 100644
--- a/include/linux/i2c-id.h
+++ b/include/linux/i2c-id.h
@@ -218,103 +218,103 @@
218 */ 218 */
219 219
220/* --- Bit algorithm adapters */ 220/* --- Bit algorithm adapters */
221#define I2C_HW_B_LP 0x00 /* Parallel port Philips style adapter */ 221#define I2C_HW_B_LP 0x010000 /* Parallel port Philips style */
222#define I2C_HW_B_LPC 0x01 /* Parallel port, over control reg. */ 222#define I2C_HW_B_LPC 0x010001 /* Parallel port control reg. */
223#define I2C_HW_B_SER 0x02 /* Serial line interface */ 223#define I2C_HW_B_SER 0x010002 /* Serial line interface */
224#define I2C_HW_B_ELV 0x03 /* ELV Card */ 224#define I2C_HW_B_ELV 0x010003 /* ELV Card */
225#define I2C_HW_B_VELLE 0x04 /* Vellemann K8000 */ 225#define I2C_HW_B_VELLE 0x010004 /* Vellemann K8000 */
226#define I2C_HW_B_BT848 0x05 /* BT848 video boards */ 226#define I2C_HW_B_BT848 0x010005 /* BT848 video boards */
227#define I2C_HW_B_WNV 0x06 /* Winnov Videums */ 227#define I2C_HW_B_WNV 0x010006 /* Winnov Videums */
228#define I2C_HW_B_VIA 0x07 /* Via vt82c586b */ 228#define I2C_HW_B_VIA 0x010007 /* Via vt82c586b */
229#define I2C_HW_B_HYDRA 0x08 /* Apple Hydra Mac I/O */ 229#define I2C_HW_B_HYDRA 0x010008 /* Apple Hydra Mac I/O */
230#define I2C_HW_B_G400 0x09 /* Matrox G400 */ 230#define I2C_HW_B_G400 0x010009 /* Matrox G400 */
231#define I2C_HW_B_I810 0x0a /* Intel I810 */ 231#define I2C_HW_B_I810 0x01000a /* Intel I810 */
232#define I2C_HW_B_VOO 0x0b /* 3dfx Voodoo 3 / Banshee */ 232#define I2C_HW_B_VOO 0x01000b /* 3dfx Voodoo 3 / Banshee */
233#define I2C_HW_B_PPORT 0x0c /* Primitive parallel port adapter */ 233#define I2C_HW_B_PPORT 0x01000c /* Primitive parallel port adapter */
234#define I2C_HW_B_SAVG 0x0d /* Savage 4 */ 234#define I2C_HW_B_SAVG 0x01000d /* Savage 4 */
235#define I2C_HW_B_SCX200 0x0e /* Nat'l Semi SCx200 I2C */ 235#define I2C_HW_B_SCX200 0x01000e /* Nat'l Semi SCx200 I2C */
236#define I2C_HW_B_RIVA 0x10 /* Riva based graphics cards */ 236#define I2C_HW_B_RIVA 0x010010 /* Riva based graphics cards */
237#define I2C_HW_B_IOC 0x11 /* IOC bit-wiggling */ 237#define I2C_HW_B_IOC 0x010011 /* IOC bit-wiggling */
238#define I2C_HW_B_TSUNA 0x12 /* DEC Tsunami chipset */ 238#define I2C_HW_B_TSUNA 0x010012 /* DEC Tsunami chipset */
239#define I2C_HW_B_FRODO 0x13 /* 2d3D, Inc. SA-1110 Development Board */ 239#define I2C_HW_B_FRODO 0x010013 /* 2d3D SA-1110 Development Board */
240#define I2C_HW_B_OMAHA 0x14 /* Omaha I2C interface (ARM) */ 240#define I2C_HW_B_OMAHA 0x010014 /* Omaha I2C interface (ARM) */
241#define I2C_HW_B_GUIDE 0x15 /* Guide bit-basher */ 241#define I2C_HW_B_GUIDE 0x010015 /* Guide bit-basher */
242#define I2C_HW_B_IXP2000 0x16 /* GPIO on IXP2000 systems */ 242#define I2C_HW_B_IXP2000 0x010016 /* GPIO on IXP2000 systems */
243#define I2C_HW_B_IXP4XX 0x17 /* GPIO on IXP4XX systems */ 243#define I2C_HW_B_IXP4XX 0x010017 /* GPIO on IXP4XX systems */
244#define I2C_HW_B_S3VIA 0x18 /* S3Via ProSavage adapter */ 244#define I2C_HW_B_S3VIA 0x010018 /* S3Via ProSavage adapter */
245#define I2C_HW_B_ZR36067 0x19 /* Zoran-36057/36067 based boards */ 245#define I2C_HW_B_ZR36067 0x010019 /* Zoran-36057/36067 based boards */
246#define I2C_HW_B_PCILYNX 0x1a /* TI PCILynx I2C adapter */ 246#define I2C_HW_B_PCILYNX 0x01001a /* TI PCILynx I2C adapter */
247#define I2C_HW_B_CX2388x 0x1b /* connexant 2388x based tv cards */ 247#define I2C_HW_B_CX2388x 0x01001b /* connexant 2388x based tv cards */
248 248
249/* --- PCF 8584 based algorithms */ 249/* --- PCF 8584 based algorithms */
250#define I2C_HW_P_LP 0x00 /* Parallel port interface */ 250#define I2C_HW_P_LP 0x020000 /* Parallel port interface */
251#define I2C_HW_P_ISA 0x01 /* generic ISA Bus inteface card */ 251#define I2C_HW_P_ISA 0x020001 /* generic ISA Bus inteface card */
252#define I2C_HW_P_ELEK 0x02 /* Elektor ISA Bus inteface card */ 252#define I2C_HW_P_ELEK 0x020002 /* Elektor ISA Bus inteface card */
253 253
254/* --- PCA 9564 based algorithms */ 254/* --- PCA 9564 based algorithms */
255#define I2C_HW_A_ISA 0x00 /* generic ISA Bus interface card */ 255#define I2C_HW_A_ISA 0x1a0000 /* generic ISA Bus interface card */
256 256
257/* --- ACPI Embedded controller algorithms */ 257/* --- ACPI Embedded controller algorithms */
258#define I2C_HW_ACPI_EC 0x00 258#define I2C_HW_ACPI_EC 0x1f0000
259 259
260/* --- MPC824x PowerPC adapters */ 260/* --- MPC824x PowerPC adapters */
261#define I2C_HW_MPC824X 0x00 /* Motorola 8240 / 8245 */ 261#define I2C_HW_MPC824X 0x100001 /* Motorola 8240 / 8245 */
262 262
263/* --- MPC8xx PowerPC adapters */ 263/* --- MPC8xx PowerPC adapters */
264#define I2C_HW_MPC8XX_EPON 0x00 /* Eponymous MPC8xx I2C adapter */ 264#define I2C_HW_MPC8XX_EPON 0x110000 /* Eponymous MPC8xx I2C adapter */
265 265
266/* --- ITE based algorithms */ 266/* --- ITE based algorithms */
267#define I2C_HW_I_IIC 0x00 /* controller on the ITE */ 267#define I2C_HW_I_IIC 0x080000 /* controller on the ITE */
268 268
269/* --- PowerPC on-chip adapters */ 269/* --- PowerPC on-chip adapters */
270#define I2C_HW_OCP 0x00 /* IBM on-chip I2C adapter */ 270#define I2C_HW_OCP 0x120000 /* IBM on-chip I2C adapter */
271 271
272/* --- Broadcom SiByte adapters */ 272/* --- Broadcom SiByte adapters */
273#define I2C_HW_SIBYTE 0x00 273#define I2C_HW_SIBYTE 0x150000
274 274
275/* --- SGI adapters */ 275/* --- SGI adapters */
276#define I2C_HW_SGI_VINO 0x00 276#define I2C_HW_SGI_VINO 0x160000
277#define I2C_HW_SGI_MACE 0x01 277#define I2C_HW_SGI_MACE 0x160001
278 278
279/* --- XSCALE on-chip adapters */ 279/* --- XSCALE on-chip adapters */
280#define I2C_HW_IOP3XX 0x00 280#define I2C_HW_IOP3XX 0x140000
281 281
282/* --- Au1550 PSC adapters adapters */ 282/* --- Au1550 PSC adapters adapters */
283#define I2C_HW_AU1550_PSC 0x00 283#define I2C_HW_AU1550_PSC 0x1b0000
284 284
285/* --- SMBus only adapters */ 285/* --- SMBus only adapters */
286#define I2C_HW_SMBUS_PIIX4 0x00 286#define I2C_HW_SMBUS_PIIX4 0x040000
287#define I2C_HW_SMBUS_ALI15X3 0x01 287#define I2C_HW_SMBUS_ALI15X3 0x040001
288#define I2C_HW_SMBUS_VIA2 0x02 288#define I2C_HW_SMBUS_VIA2 0x040002
289#define I2C_HW_SMBUS_VOODOO3 0x03 289#define I2C_HW_SMBUS_VOODOO3 0x040003
290#define I2C_HW_SMBUS_I801 0x04 290#define I2C_HW_SMBUS_I801 0x040004
291#define I2C_HW_SMBUS_AMD756 0x05 291#define I2C_HW_SMBUS_AMD756 0x040005
292#define I2C_HW_SMBUS_SIS5595 0x06 292#define I2C_HW_SMBUS_SIS5595 0x040006
293#define I2C_HW_SMBUS_ALI1535 0x07 293#define I2C_HW_SMBUS_ALI1535 0x040007
294#define I2C_HW_SMBUS_SIS630 0x08 294#define I2C_HW_SMBUS_SIS630 0x040008
295#define I2C_HW_SMBUS_SIS96X 0x09 295#define I2C_HW_SMBUS_SIS96X 0x040009
296#define I2C_HW_SMBUS_AMD8111 0x0a 296#define I2C_HW_SMBUS_AMD8111 0x04000a
297#define I2C_HW_SMBUS_SCX200 0x0b 297#define I2C_HW_SMBUS_SCX200 0x04000b
298#define I2C_HW_SMBUS_NFORCE2 0x0c 298#define I2C_HW_SMBUS_NFORCE2 0x04000c
299#define I2C_HW_SMBUS_W9968CF 0x0d 299#define I2C_HW_SMBUS_W9968CF 0x04000d
300#define I2C_HW_SMBUS_OV511 0x0e /* OV511(+) USB 1.1 webcam ICs */ 300#define I2C_HW_SMBUS_OV511 0x04000e /* OV511(+) USB 1.1 webcam ICs */
301#define I2C_HW_SMBUS_OV518 0x0f /* OV518(+) USB 1.1 webcam ICs */ 301#define I2C_HW_SMBUS_OV518 0x04000f /* OV518(+) USB 1.1 webcam ICs */
302#define I2C_HW_SMBUS_OV519 0x10 /* OV519 USB 1.1 webcam IC */ 302#define I2C_HW_SMBUS_OV519 0x040010 /* OV519 USB 1.1 webcam IC */
303#define I2C_HW_SMBUS_OVFX2 0x11 /* Cypress/OmniVision FX2 webcam */ 303#define I2C_HW_SMBUS_OVFX2 0x040011 /* Cypress/OmniVision FX2 webcam */
304 304
305/* --- ISA pseudo-adapter */ 305/* --- ISA pseudo-adapter */
306#define I2C_HW_ISA 0x00 306#define I2C_HW_ISA 0x050000
307 307
308/* --- IPMI pseudo-adapter */ 308/* --- IPMI pseudo-adapter */
309#define I2C_HW_IPMI 0x00 309#define I2C_HW_IPMI 0x0b0000
310 310
311/* --- IPMB adapter */ 311/* --- IPMB adapter */
312#define I2C_HW_IPMB 0x00 312#define I2C_HW_IPMB 0x0c0000
313 313
314/* --- MCP107 adapter */ 314/* --- MCP107 adapter */
315#define I2C_HW_MPC107 0x00 315#define I2C_HW_MPC107 0x0d0000
316 316
317/* --- Marvell mv64xxx i2c adapter */ 317/* --- Marvell mv64xxx i2c adapter */
318#define I2C_HW_MV64XXX 0x00 318#define I2C_HW_MV64XXX 0x190000
319 319
320#endif /* LINUX_I2C_ID_H */ 320#endif /* LINUX_I2C_ID_H */
diff --git a/include/linux/i2c-isa.h b/include/linux/i2c-isa.h
index 54c27e88d101..67e3598c4cec 100644
--- a/include/linux/i2c-isa.h
+++ b/include/linux/i2c-isa.h
@@ -29,7 +29,7 @@ extern int i2c_isa_del_driver(struct i2c_driver *driver);
29/* Detect whether we are on the isa bus. This is only useful to hybrid 29/* Detect whether we are on the isa bus. This is only useful to hybrid
30 (i2c+isa) drivers. */ 30 (i2c+isa) drivers. */
31#define i2c_is_isa_adapter(adapptr) \ 31#define i2c_is_isa_adapter(adapptr) \
32 ((adapptr)->id == (I2C_ALGO_ISA | I2C_HW_ISA)) 32 ((adapptr)->id == I2C_HW_ISA)
33#define i2c_is_isa_client(clientptr) \ 33#define i2c_is_isa_client(clientptr) \
34 i2c_is_isa_adapter((clientptr)->adapter) 34 i2c_is_isa_adapter((clientptr)->adapter)
35 35