aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/platforms
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2008-08-11 13:40:28 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2008-08-11 13:40:28 -0400
commite2205a156f4dd727097f7f492bf03aa8920b0071 (patch)
tree7c4947406e9e11b5fbe183db4e0ae1943b9a7d15 /arch/powerpc/platforms
parenta7ef6a40f700496c60b8f7206fff74fecd67b3a2 (diff)
parent13fa00a8780885edcdf0bc53b81e5d0fec71119a (diff)
Merge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc
* 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: powerpc: Remove include/linux/harrier_defs.h powerpc: Do not ignore arch/powerpc/include powerpc: Delete completed "ppc removal" task from feature removal file powerpc/mm: Fix attribute confusion with htab_bolt_mapping() powerpc/pci: Don't keep ISA memory hole resources in the tree powerpc: Zero fill the return values of rtas argument buffer powerpc/4xx: Update defconfig files for 2.6.27-rc1 powerpc/44x: Incorrect NOR offset in Warp DTS powerpc/44x: Warp DTS changes for board updates powerpc/4xx: Cleanup Warp for i2c driver changes. powerpc/44x: Adjust warp-nand resource end address
Diffstat (limited to 'arch/powerpc/platforms')
-rw-r--r--arch/powerpc/platforms/44x/warp-nand.c2
-rw-r--r--arch/powerpc/platforms/44x/warp.c25
2 files changed, 11 insertions, 16 deletions
diff --git a/arch/powerpc/platforms/44x/warp-nand.c b/arch/powerpc/platforms/44x/warp-nand.c
index e55746b824b4..89ecd76127d8 100644
--- a/arch/powerpc/platforms/44x/warp-nand.c
+++ b/arch/powerpc/platforms/44x/warp-nand.c
@@ -24,7 +24,7 @@
24 24
25static struct resource warp_ndfc = { 25static struct resource warp_ndfc = {
26 .start = WARP_NAND_FLASH_REG_ADDR, 26 .start = WARP_NAND_FLASH_REG_ADDR,
27 .end = WARP_NAND_FLASH_REG_ADDR + WARP_NAND_FLASH_REG_SIZE, 27 .end = WARP_NAND_FLASH_REG_ADDR + WARP_NAND_FLASH_REG_SIZE - 1,
28 .flags = IORESOURCE_MEM, 28 .flags = IORESOURCE_MEM,
29}; 29};
30 30
diff --git a/arch/powerpc/platforms/44x/warp.c b/arch/powerpc/platforms/44x/warp.c
index 9565995cba7f..960edf89be51 100644
--- a/arch/powerpc/platforms/44x/warp.c
+++ b/arch/powerpc/platforms/44x/warp.c
@@ -30,18 +30,6 @@ static __initdata struct of_device_id warp_of_bus[] = {
30 {}, 30 {},
31}; 31};
32 32
33static __initdata struct i2c_board_info warp_i2c_info[] = {
34 { I2C_BOARD_INFO("ad7414", 0x4a) }
35};
36
37static int __init warp_arch_init(void)
38{
39 /* This should go away once support is moved to the dts. */
40 i2c_register_board_info(0, warp_i2c_info, ARRAY_SIZE(warp_i2c_info));
41 return 0;
42}
43machine_arch_initcall(warp, warp_arch_init);
44
45static int __init warp_device_probe(void) 33static int __init warp_device_probe(void)
46{ 34{
47 of_platform_bus_probe(NULL, warp_of_bus, NULL); 35 of_platform_bus_probe(NULL, warp_of_bus, NULL);
@@ -223,7 +211,7 @@ static void pika_setup_critical_temp(struct i2c_client *client)
223 211
224 /* These registers are in 1 degree increments. */ 212 /* These registers are in 1 degree increments. */
225 i2c_smbus_write_byte_data(client, 2, 65); /* Thigh */ 213 i2c_smbus_write_byte_data(client, 2, 65); /* Thigh */
226 i2c_smbus_write_byte_data(client, 3, 55); /* Tlow */ 214 i2c_smbus_write_byte_data(client, 3, 0); /* Tlow */
227 215
228 np = of_find_compatible_node(NULL, NULL, "adi,ad7414"); 216 np = of_find_compatible_node(NULL, NULL, "adi,ad7414");
229 if (np == NULL) { 217 if (np == NULL) {
@@ -289,8 +277,15 @@ found_it:
289 printk(KERN_INFO "PIKA DTM thread running.\n"); 277 printk(KERN_INFO "PIKA DTM thread running.\n");
290 278
291 while (!kthread_should_stop()) { 279 while (!kthread_should_stop()) {
292 u16 temp = swab16(i2c_smbus_read_word_data(client, 0)); 280 int val;
293 out_be32(fpga + 0x20, temp); 281
282 val = i2c_smbus_read_word_data(client, 0);
283 if (val < 0)
284 dev_dbg(&client->dev, "DTM read temp failed.\n");
285 else {
286 s16 temp = swab16(val);
287 out_be32(fpga + 0x20, temp);
288 }
294 289
295 pika_dtm_check_fan(fpga); 290 pika_dtm_check_fan(fpga);
296 291