Skip to content

Commit

Permalink
MIPS: Jazz: Fix GCC 4.6.0 build error
Browse files Browse the repository at this point in the history
  CC      arch/mips/jazz/jazzdma.o
arch/mips/jazz/jazzdma.c: In function 'vdma_remap':
arch/mips/jazz/jazzdma.c:214:20: error: variable 'npages' set but not used [-Werror=unused-but-set-variable]
cc1: all warnings being treated as errors

Signed-off-by: Ralf Baechle <[email protected]>
  • Loading branch information
ralfbaechle committed May 10, 2011
1 parent 11b9d0e commit 84d3b0d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions arch/mips/jazz/jazzdma.c
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ EXPORT_SYMBOL(vdma_free);
*/
int vdma_remap(unsigned long laddr, unsigned long paddr, unsigned long size)
{
int first, pages, npages;
int first, pages;

if (laddr > 0xffffff) {
if (vdma_debug)
Expand All @@ -228,8 +228,7 @@ int vdma_remap(unsigned long laddr, unsigned long paddr, unsigned long size)
return -EINVAL; /* invalid physical address */
}

npages = pages =
(((paddr & (VDMA_PAGESIZE - 1)) + size) >> 12) + 1;
pages = (((paddr & (VDMA_PAGESIZE - 1)) + size) >> 12) + 1;
first = laddr >> 12;
if (vdma_debug)
printk("vdma_remap: first=%x, pages=%x\n", first, pages);
Expand Down

0 comments on commit 84d3b0d

Please sign in to comment.