diff options
author | Paul Mackerras <paulus@samba.org> | 2009-04-21 23:02:09 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2009-04-21 23:02:09 -0400 |
commit | 5bd3ef84d73c2ea7b4babbad060909753c4828d4 (patch) | |
tree | fdf2bafb48ae1ed03175f6c77a7548a181e69ee9 /arch/powerpc/kernel | |
parent | 0658c16056660886ea2f35c4f038be70a94b1532 (diff) | |
parent | 6d25b688ecc488753af3c9e6f6a9a575b863cf37 (diff) |
Merge branch 'merge' of git://git.secretlab.ca/git/linux-2.6 into merge
Diffstat (limited to 'arch/powerpc/kernel')
-rw-r--r-- | arch/powerpc/kernel/dma.c | 2 | ||||
-rw-r--r-- | arch/powerpc/kernel/of_platform.c | 2 | ||||
-rw-r--r-- | arch/powerpc/kernel/prom_parse.c | 11 |
3 files changed, 7 insertions, 8 deletions
diff --git a/arch/powerpc/kernel/dma.c b/arch/powerpc/kernel/dma.c index 1c5c8a6fc129..53c7788cba78 100644 --- a/arch/powerpc/kernel/dma.c +++ b/arch/powerpc/kernel/dma.c | |||
@@ -94,7 +94,7 @@ static int dma_direct_dma_supported(struct device *dev, u64 mask) | |||
94 | * done via some global so platforms can set the limit in case | 94 | * done via some global so platforms can set the limit in case |
95 | * they have limited DMA windows | 95 | * they have limited DMA windows |
96 | */ | 96 | */ |
97 | return mask >= DMA_32BIT_MASK; | 97 | return mask >= DMA_BIT_MASK(32); |
98 | #else | 98 | #else |
99 | return 1; | 99 | return 1; |
100 | #endif | 100 | #endif |
diff --git a/arch/powerpc/kernel/of_platform.c b/arch/powerpc/kernel/of_platform.c index 3f37a6e62771..87df428e3588 100644 --- a/arch/powerpc/kernel/of_platform.c +++ b/arch/powerpc/kernel/of_platform.c | |||
@@ -76,7 +76,7 @@ struct of_device* of_platform_device_create(struct device_node *np, | |||
76 | return NULL; | 76 | return NULL; |
77 | 77 | ||
78 | dev->dma_mask = 0xffffffffUL; | 78 | dev->dma_mask = 0xffffffffUL; |
79 | dev->dev.coherent_dma_mask = DMA_32BIT_MASK; | 79 | dev->dev.coherent_dma_mask = DMA_BIT_MASK(32); |
80 | 80 | ||
81 | dev->dev.bus = &of_platform_bus_type; | 81 | dev->dev.bus = &of_platform_bus_type; |
82 | 82 | ||
diff --git a/arch/powerpc/kernel/prom_parse.c b/arch/powerpc/kernel/prom_parse.c index 8f0856f312da..8362620c9e6f 100644 --- a/arch/powerpc/kernel/prom_parse.c +++ b/arch/powerpc/kernel/prom_parse.c | |||
@@ -971,7 +971,7 @@ int of_irq_map_one(struct device_node *device, int index, struct of_irq *out_irq | |||
971 | struct device_node *p; | 971 | struct device_node *p; |
972 | const u32 *intspec, *tmp, *addr; | 972 | const u32 *intspec, *tmp, *addr; |
973 | u32 intsize, intlen; | 973 | u32 intsize, intlen; |
974 | int res; | 974 | int res = -EINVAL; |
975 | 975 | ||
976 | DBG("of_irq_map_one: dev=%s, index=%d\n", device->full_name, index); | 976 | DBG("of_irq_map_one: dev=%s, index=%d\n", device->full_name, index); |
977 | 977 | ||
@@ -995,21 +995,20 @@ int of_irq_map_one(struct device_node *device, int index, struct of_irq *out_irq | |||
995 | 995 | ||
996 | /* Get size of interrupt specifier */ | 996 | /* Get size of interrupt specifier */ |
997 | tmp = of_get_property(p, "#interrupt-cells", NULL); | 997 | tmp = of_get_property(p, "#interrupt-cells", NULL); |
998 | if (tmp == NULL) { | 998 | if (tmp == NULL) |
999 | of_node_put(p); | 999 | goto out; |
1000 | return -EINVAL; | ||
1001 | } | ||
1002 | intsize = *tmp; | 1000 | intsize = *tmp; |
1003 | 1001 | ||
1004 | DBG(" intsize=%d intlen=%d\n", intsize, intlen); | 1002 | DBG(" intsize=%d intlen=%d\n", intsize, intlen); |
1005 | 1003 | ||
1006 | /* Check index */ | 1004 | /* Check index */ |
1007 | if ((index + 1) * intsize > intlen) | 1005 | if ((index + 1) * intsize > intlen) |
1008 | return -EINVAL; | 1006 | goto out; |
1009 | 1007 | ||
1010 | /* Get new specifier and map it */ | 1008 | /* Get new specifier and map it */ |
1011 | res = of_irq_map_raw(p, intspec + index * intsize, intsize, | 1009 | res = of_irq_map_raw(p, intspec + index * intsize, intsize, |
1012 | addr, out_irq); | 1010 | addr, out_irq); |
1011 | out: | ||
1013 | of_node_put(p); | 1012 | of_node_put(p); |
1014 | return res; | 1013 | return res; |
1015 | } | 1014 | } |