diff options
author | Stephen Rothwell <sfr@canb.auug.org.au> | 2007-05-11 01:42:44 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2007-05-11 21:32:47 -0400 |
commit | 435e0b2b165bcac86eeddf675383070f60587cbb (patch) | |
tree | 1bea3d9ae218d74697d2374b915ac491e4e1cdaf | |
parent | bff8dde8fb0ee9429837051b6054d770755d6e7f (diff) |
[POWERPC] Trivial ps3 warning fixes
Fixes warnings:
arch/powerpc/platforms/ps3/system-bus.c: In function 'ps3_map_sg':
arch/powerpc/platforms/ps3/system-bus.c:278: warning: unused variable 'i'
arch/powerpc/platforms/ps3/system-bus.c:277: warning: unused variable 'dev'
arch/powerpc/platforms/ps3/setup.c:103: warning: 'prealloc' defined but not used
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Acked-by: Geoff Levand <geoffrey.levand@am.sony.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
-rw-r--r-- | arch/powerpc/platforms/ps3/setup.c | 2 | ||||
-rw-r--r-- | arch/powerpc/platforms/ps3/system-bus.c | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/arch/powerpc/platforms/ps3/setup.c b/arch/powerpc/platforms/ps3/setup.c index c9894933084f..935396766621 100644 --- a/arch/powerpc/platforms/ps3/setup.c +++ b/arch/powerpc/platforms/ps3/setup.c | |||
@@ -99,6 +99,7 @@ static void ps3_panic(char *str) | |||
99 | while(1); | 99 | while(1); |
100 | } | 100 | } |
101 | 101 | ||
102 | #ifdef CONFIG_FB_PS3 | ||
102 | static void prealloc(struct ps3_prealloc *p) | 103 | static void prealloc(struct ps3_prealloc *p) |
103 | { | 104 | { |
104 | if (!p->size) | 105 | if (!p->size) |
@@ -115,7 +116,6 @@ static void prealloc(struct ps3_prealloc *p) | |||
115 | p->address); | 116 | p->address); |
116 | } | 117 | } |
117 | 118 | ||
118 | #ifdef CONFIG_FB_PS3 | ||
119 | struct ps3_prealloc ps3fb_videomemory = { | 119 | struct ps3_prealloc ps3fb_videomemory = { |
120 | .name = "ps3fb videomemory", | 120 | .name = "ps3fb videomemory", |
121 | .size = CONFIG_FB_PS3_DEFAULT_SIZE_M*1024*1024, | 121 | .size = CONFIG_FB_PS3_DEFAULT_SIZE_M*1024*1024, |
diff --git a/arch/powerpc/platforms/ps3/system-bus.c b/arch/powerpc/platforms/ps3/system-bus.c index 3c48cce98a5c..6bda51027cc6 100644 --- a/arch/powerpc/platforms/ps3/system-bus.c +++ b/arch/powerpc/platforms/ps3/system-bus.c | |||
@@ -274,13 +274,13 @@ static void ps3_unmap_single(struct device *_dev, dma_addr_t dma_addr, | |||
274 | static int ps3_map_sg(struct device *_dev, struct scatterlist *sg, int nents, | 274 | static int ps3_map_sg(struct device *_dev, struct scatterlist *sg, int nents, |
275 | enum dma_data_direction direction) | 275 | enum dma_data_direction direction) |
276 | { | 276 | { |
277 | struct ps3_system_bus_device *dev = to_ps3_system_bus_device(_dev); | ||
278 | int i; | ||
279 | |||
280 | #if defined(CONFIG_PS3_DYNAMIC_DMA) | 277 | #if defined(CONFIG_PS3_DYNAMIC_DMA) |
281 | BUG_ON("do"); | 278 | BUG_ON("do"); |
282 | return -EPERM; | 279 | return -EPERM; |
283 | #else | 280 | #else |
281 | struct ps3_system_bus_device *dev = to_ps3_system_bus_device(_dev); | ||
282 | int i; | ||
283 | |||
284 | for (i = 0; i < nents; i++, sg++) { | 284 | for (i = 0; i < nents; i++, sg++) { |
285 | int result = ps3_dma_map(dev->d_region, | 285 | int result = ps3_dma_map(dev->d_region, |
286 | page_to_phys(sg->page) + sg->offset, sg->length, | 286 | page_to_phys(sg->page) + sg->offset, sg->length, |