Changeset 1427
- Timestamp:
- 07/07/02 17:45:14 (11 years ago)
- Location:
- lm-sensors/trunk/kernel/busses
- Files:
-
- 4 modified
-
i2c-hydra.c (modified) (2 diffs)
-
i2c-i810.c (modified) (6 diffs)
-
i2c-savage4.c (modified) (4 diffs)
-
i2c-voodoo3.c (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
lm-sensors/trunk/kernel/busses/i2c-hydra.c
r1201 r1427 79 79 } 80 80 pdregw(val); 81 pdregr(); /* flush posted write */ 81 82 } 82 83 … … 91 92 } 92 93 pdregw(val); 94 pdregr(); /* flush posted write */ 93 95 } 94 96 -
lm-sensors/trunk/kernel/busses/i2c-i810.c
r1281 r1427 130 130 outlong((val ? SCL_VAL_OUT : 0) | SCL_DIR | SCL_DIR_MASK | SCL_VAL_MASK, 131 131 I810_GPIOB); 132 readlong(I810_GPIOB); /* flush posted write */ 132 133 } 133 134 … … 136 137 outlong((val ? SDA_VAL_OUT : 0) | SDA_DIR | SDA_DIR_MASK | SDA_VAL_MASK, 137 138 I810_GPIOB); 139 readlong(I810_GPIOB); /* flush posted write */ 138 140 } 139 141 … … 162 164 outlong((val ? SCL_VAL_OUT : 0) | SCL_DIR | SCL_DIR_MASK | SCL_VAL_MASK, 163 165 I810_GPIOA); 166 readlong(I810_GPIOA); /* flush posted write */ 164 167 } 165 168 … … 168 171 outlong((val ? SDA_VAL_OUT : 0) | SDA_DIR | SDA_DIR_MASK | SDA_VAL_MASK, 169 172 I810_GPIOA); 173 readlong(I810_GPIOA); /* flush posted write */ 170 174 } 171 175 … … 237 241 cadr &= PCI_BASE_ADDRESS_MEM_MASK; 238 242 mem = ioremap_nocache(cadr, 0x1000); 239 bit_i810i2c_setscl(NULL, 1); 240 bit_i810i2c_setsda(NULL, 1); 241 bit_i810ddc_setscl(NULL, 1); 242 bit_i810ddc_setsda(NULL, 1); 243 if(mem) { 244 bit_i810i2c_setscl(NULL, 1); 245 bit_i810i2c_setsda(NULL, 1); 246 bit_i810ddc_setscl(NULL, 1); 247 bit_i810ddc_setsda(NULL, 1); 248 } 243 249 } 244 250 … … 254 260 *num++, dev))) { 255 261 config_i810(dev); 262 if(!mem) 263 return -ENOMEM; 256 264 printk("i2c-i810.o: i810/i815 found.\n"); 257 265 return 0; -
lm-sensors/trunk/kernel/busses/i2c-savage4.c
r1354 r1427 123 123 r &= ~I2C_SCL_OUT; 124 124 outlong(r); 125 readlong(); /* flush posted write */ 125 126 } 126 127 … … 134 135 r &= ~I2C_SDA_OUT; 135 136 outlong(r); 137 readlong(); /* flush posted write */ 136 138 } 137 139 … … 236 238 cadr &= PCI_BASE_ADDRESS_MEM_MASK; 237 239 mem = ioremap_nocache(cadr, 0x0080000); 238 239 // *((unsigned int *) (mem + REG2)) = 0x8160; 240 *((unsigned int *) (mem + REG)) = 0x00000020; 241 printk("i2c-savage4: Using Savage4 at 0x%p\n", mem); 240 if(mem) { 241 // *((unsigned int *) (mem + REG2)) = 0x8160; 242 *((unsigned int *) (mem + REG)) = 0x00000020; 243 printk("i2c-savage4: Using Savage4 at 0x%p\n", mem); 244 } 242 245 } 243 246 … … 273 276 274 277 if (s4_num > 0) { 278 if(!mem) 279 return -ENOMEM; 275 280 printk("i2c-savage4: %d Savage4 found.\n", s4_num); 276 281 if (s4_num > 1) -
lm-sensors/trunk/kernel/busses/i2c-voodoo3.c
r1201 r1427 116 116 r &= ~I2C_SCL_OUT; 117 117 outlong(r); 118 readlong(); /* flush posted write */ 118 119 } 119 120 … … 127 128 r &= ~I2C_SDA_OUT; 128 129 outlong(r); 130 readlong(); /* flush posted write */ 129 131 } 130 132 … … 152 154 r &= ~DDC_SCL_OUT; 153 155 outlong(r); 156 readlong(); /* flush posted write */ 154 157 } 155 158 … … 163 166 r &= ~DDC_SDA_OUT; 164 167 outlong(r); 168 readlong(); /* flush posted write */ 165 169 } 166 170 … … 229 233 cadr &= PCI_BASE_ADDRESS_MEM_MASK; 230 234 mem = ioremap_nocache(cadr, 0x1000); 231 232 *((unsigned int *) (mem + REG2)) = 0x8160; 233 *((unsigned int *) (mem + REG)) = 0xcffc0020; 234 printk("i2c-voodoo3: Using Banshee/Voodoo3 at 0x%p\n", mem); 235 if(mem) { 236 *((unsigned int *) (mem + REG2)) = 0x8160; 237 *((unsigned int *) (mem + REG)) = 0xcffc0020; 238 printk("i2c-voodoo3: Using Banshee/Voodoo3 at 0x%p\n", mem); 239 } 235 240 } 236 241 … … 267 272 268 273 if (v3_num > 0) { 274 if(!mem) 275 return -ENOMEM; 269 276 printk("i2c-voodoo3: %d Banshee/Voodoo3 found.\n", v3_num); 270 277 if (v3_num > 1)
