diff options
author | Grant Likely <grant.likely@secretlab.ca> | 2010-01-28 16:38:25 -0500 |
---|---|---|
committer | Grant Likely <grant.likely@secretlab.ca> | 2010-01-28 16:38:25 -0500 |
commit | 0ada0a73120c28cc432bcdbac061781465c2f48f (patch) | |
tree | d17cadd4ea47e25d9e48e7d409a39c84268fbd27 /arch/powerpc/platforms/powermac | |
parent | 6016a363f6b56b46b24655bcfc0499b715851cf3 (diff) | |
parent | 92dcffb916d309aa01778bf8963a6932e4014d07 (diff) |
Merge commit 'v2.6.33-rc5' into secretlab/test-devicetree
Diffstat (limited to 'arch/powerpc/platforms/powermac')
-rw-r--r-- | arch/powerpc/platforms/powermac/bootx_init.c | 2 | ||||
-rw-r--r-- | arch/powerpc/platforms/powermac/low_i2c.c | 25 | ||||
-rw-r--r-- | arch/powerpc/platforms/powermac/pci.c | 2 | ||||
-rw-r--r-- | arch/powerpc/platforms/powermac/pic.c | 12 |
4 files changed, 13 insertions, 28 deletions
diff --git a/arch/powerpc/platforms/powermac/bootx_init.c b/arch/powerpc/platforms/powermac/bootx_init.c index cf660916ae0b..9dd789a7370d 100644 --- a/arch/powerpc/platforms/powermac/bootx_init.c +++ b/arch/powerpc/platforms/powermac/bootx_init.c | |||
@@ -12,7 +12,7 @@ | |||
12 | #include <linux/kernel.h> | 12 | #include <linux/kernel.h> |
13 | #include <linux/string.h> | 13 | #include <linux/string.h> |
14 | #include <linux/init.h> | 14 | #include <linux/init.h> |
15 | #include <linux/utsrelease.h> | 15 | #include <generated/utsrelease.h> |
16 | #include <asm/sections.h> | 16 | #include <asm/sections.h> |
17 | #include <asm/prom.h> | 17 | #include <asm/prom.h> |
18 | #include <asm/page.h> | 18 | #include <asm/page.h> |
diff --git a/arch/powerpc/platforms/powermac/low_i2c.c b/arch/powerpc/platforms/powermac/low_i2c.c index 414ca9849f23..345e2da56767 100644 --- a/arch/powerpc/platforms/powermac/low_i2c.c +++ b/arch/powerpc/platforms/powermac/low_i2c.c | |||
@@ -42,6 +42,7 @@ | |||
42 | #include <linux/interrupt.h> | 42 | #include <linux/interrupt.h> |
43 | #include <linux/timer.h> | 43 | #include <linux/timer.h> |
44 | #include <linux/mutex.h> | 44 | #include <linux/mutex.h> |
45 | #include <linux/i2c.h> | ||
45 | #include <asm/keylargo.h> | 46 | #include <asm/keylargo.h> |
46 | #include <asm/uninorth.h> | 47 | #include <asm/uninorth.h> |
47 | #include <asm/io.h> | 48 | #include <asm/io.h> |
@@ -80,7 +81,7 @@ struct pmac_i2c_bus | |||
80 | struct device_node *busnode; | 81 | struct device_node *busnode; |
81 | int type; | 82 | int type; |
82 | int flags; | 83 | int flags; |
83 | struct i2c_adapter *adapter; | 84 | struct i2c_adapter adapter; |
84 | void *hostdata; | 85 | void *hostdata; |
85 | int channel; /* some hosts have multiple */ | 86 | int channel; /* some hosts have multiple */ |
86 | int mode; /* current mode */ | 87 | int mode; /* current mode */ |
@@ -1014,25 +1015,9 @@ int pmac_i2c_get_channel(struct pmac_i2c_bus *bus) | |||
1014 | EXPORT_SYMBOL_GPL(pmac_i2c_get_channel); | 1015 | EXPORT_SYMBOL_GPL(pmac_i2c_get_channel); |
1015 | 1016 | ||
1016 | 1017 | ||
1017 | void pmac_i2c_attach_adapter(struct pmac_i2c_bus *bus, | ||
1018 | struct i2c_adapter *adapter) | ||
1019 | { | ||
1020 | WARN_ON(bus->adapter != NULL); | ||
1021 | bus->adapter = adapter; | ||
1022 | } | ||
1023 | EXPORT_SYMBOL_GPL(pmac_i2c_attach_adapter); | ||
1024 | |||
1025 | void pmac_i2c_detach_adapter(struct pmac_i2c_bus *bus, | ||
1026 | struct i2c_adapter *adapter) | ||
1027 | { | ||
1028 | WARN_ON(bus->adapter != adapter); | ||
1029 | bus->adapter = NULL; | ||
1030 | } | ||
1031 | EXPORT_SYMBOL_GPL(pmac_i2c_detach_adapter); | ||
1032 | |||
1033 | struct i2c_adapter *pmac_i2c_get_adapter(struct pmac_i2c_bus *bus) | 1018 | struct i2c_adapter *pmac_i2c_get_adapter(struct pmac_i2c_bus *bus) |
1034 | { | 1019 | { |
1035 | return bus->adapter; | 1020 | return &bus->adapter; |
1036 | } | 1021 | } |
1037 | EXPORT_SYMBOL_GPL(pmac_i2c_get_adapter); | 1022 | EXPORT_SYMBOL_GPL(pmac_i2c_get_adapter); |
1038 | 1023 | ||
@@ -1041,7 +1026,7 @@ struct pmac_i2c_bus *pmac_i2c_adapter_to_bus(struct i2c_adapter *adapter) | |||
1041 | struct pmac_i2c_bus *bus; | 1026 | struct pmac_i2c_bus *bus; |
1042 | 1027 | ||
1043 | list_for_each_entry(bus, &pmac_i2c_busses, link) | 1028 | list_for_each_entry(bus, &pmac_i2c_busses, link) |
1044 | if (bus->adapter == adapter) | 1029 | if (&bus->adapter == adapter) |
1045 | return bus; | 1030 | return bus; |
1046 | return NULL; | 1031 | return NULL; |
1047 | } | 1032 | } |
@@ -1053,7 +1038,7 @@ int pmac_i2c_match_adapter(struct device_node *dev, struct i2c_adapter *adapter) | |||
1053 | 1038 | ||
1054 | if (bus == NULL) | 1039 | if (bus == NULL) |
1055 | return 0; | 1040 | return 0; |
1056 | return (bus->adapter == adapter); | 1041 | return (&bus->adapter == adapter); |
1057 | } | 1042 | } |
1058 | EXPORT_SYMBOL_GPL(pmac_i2c_match_adapter); | 1043 | EXPORT_SYMBOL_GPL(pmac_i2c_match_adapter); |
1059 | 1044 | ||
diff --git a/arch/powerpc/platforms/powermac/pci.c b/arch/powerpc/platforms/powermac/pci.c index e81403b245b5..ab2027cdf893 100644 --- a/arch/powerpc/platforms/powermac/pci.c +++ b/arch/powerpc/platforms/powermac/pci.c | |||
@@ -302,7 +302,7 @@ static void __init setup_chaos(struct pci_controller *hose, | |||
302 | * 1 -> Skip the device but act as if the access was successfull | 302 | * 1 -> Skip the device but act as if the access was successfull |
303 | * (return 0xff's on reads, eventually, cache config space | 303 | * (return 0xff's on reads, eventually, cache config space |
304 | * accesses in a later version) | 304 | * accesses in a later version) |
305 | * -1 -> Hide the device (unsuccessful acess) | 305 | * -1 -> Hide the device (unsuccessful access) |
306 | */ | 306 | */ |
307 | static int u3_ht_skip_device(struct pci_controller *hose, | 307 | static int u3_ht_skip_device(struct pci_controller *hose, |
308 | struct pci_bus *bus, unsigned int devfn) | 308 | struct pci_bus *bus, unsigned int devfn) |
diff --git a/arch/powerpc/platforms/powermac/pic.c b/arch/powerpc/platforms/powermac/pic.c index d212006a5b3c..09e827296276 100644 --- a/arch/powerpc/platforms/powermac/pic.c +++ b/arch/powerpc/platforms/powermac/pic.c | |||
@@ -152,12 +152,12 @@ static unsigned int pmac_startup_irq(unsigned int virq) | |||
152 | unsigned long bit = 1UL << (src & 0x1f); | 152 | unsigned long bit = 1UL << (src & 0x1f); |
153 | int i = src >> 5; | 153 | int i = src >> 5; |
154 | 154 | ||
155 | spin_lock_irqsave(&pmac_pic_lock, flags); | 155 | spin_lock_irqsave(&pmac_pic_lock, flags); |
156 | if ((irq_desc[virq].status & IRQ_LEVEL) == 0) | 156 | if ((irq_to_desc(virq)->status & IRQ_LEVEL) == 0) |
157 | out_le32(&pmac_irq_hw[i]->ack, bit); | 157 | out_le32(&pmac_irq_hw[i]->ack, bit); |
158 | __set_bit(src, ppc_cached_irq_mask); | 158 | __set_bit(src, ppc_cached_irq_mask); |
159 | __pmac_set_irq_mask(src, 0); | 159 | __pmac_set_irq_mask(src, 0); |
160 | spin_unlock_irqrestore(&pmac_pic_lock, flags); | 160 | spin_unlock_irqrestore(&pmac_pic_lock, flags); |
161 | 161 | ||
162 | return 0; | 162 | return 0; |
163 | } | 163 | } |
@@ -195,7 +195,7 @@ static int pmac_retrigger(unsigned int virq) | |||
195 | } | 195 | } |
196 | 196 | ||
197 | static struct irq_chip pmac_pic = { | 197 | static struct irq_chip pmac_pic = { |
198 | .typename = " PMAC-PIC ", | 198 | .name = " PMAC-PIC ", |
199 | .startup = pmac_startup_irq, | 199 | .startup = pmac_startup_irq, |
200 | .mask = pmac_mask_irq, | 200 | .mask = pmac_mask_irq, |
201 | .ack = pmac_ack_irq, | 201 | .ack = pmac_ack_irq, |
@@ -285,7 +285,7 @@ static int pmac_pic_host_match(struct irq_host *h, struct device_node *node) | |||
285 | static int pmac_pic_host_map(struct irq_host *h, unsigned int virq, | 285 | static int pmac_pic_host_map(struct irq_host *h, unsigned int virq, |
286 | irq_hw_number_t hw) | 286 | irq_hw_number_t hw) |
287 | { | 287 | { |
288 | struct irq_desc *desc = get_irq_desc(virq); | 288 | struct irq_desc *desc = irq_to_desc(virq); |
289 | int level; | 289 | int level; |
290 | 290 | ||
291 | if (hw >= max_irqs) | 291 | if (hw >= max_irqs) |
@@ -303,7 +303,7 @@ static int pmac_pic_host_map(struct irq_host *h, unsigned int virq, | |||
303 | } | 303 | } |
304 | 304 | ||
305 | static int pmac_pic_host_xlate(struct irq_host *h, struct device_node *ct, | 305 | static int pmac_pic_host_xlate(struct irq_host *h, struct device_node *ct, |
306 | u32 *intspec, unsigned int intsize, | 306 | const u32 *intspec, unsigned int intsize, |
307 | irq_hw_number_t *out_hwirq, | 307 | irq_hw_number_t *out_hwirq, |
308 | unsigned int *out_flags) | 308 | unsigned int *out_flags) |
309 | 309 | ||