projects
/
GitHub
/
MotorolaMobilityLLC
/
kernel-slsi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
64f1815
)
MIPS: Jazz: Fix read buffer overflow
author
Roel Kluin
<roel.kluin@gmail.com>
Fri, 31 Jul 2009 12:52:51 +0000
(14:52 +0200)
committer
Ralf Baechle
<ralf@linux-mips.org>
Mon, 3 Aug 2009 16:52:47 +0000
(17:52 +0100)
Check whether index is within bounds before testing the element.
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/jazz/jazzdma.c
patch
|
blob
|
blame
|
history
diff --git
a/arch/mips/jazz/jazzdma.c
b/arch/mips/jazz/jazzdma.c
index f0fd636723be1d2663e16ada6af9aeab32a225cb..0d64d0f464185c0c9c383fcad2e1d30416afc854 100644
(file)
--- a/
arch/mips/jazz/jazzdma.c
+++ b/
arch/mips/jazz/jazzdma.c
@@
-190,7
+190,7
@@
int vdma_free(unsigned long laddr)
return -1;
}
- while (
pgtbl[i].owner == laddr && i < VDMA_PGTBL_ENTRIES
) {
+ while (
i < VDMA_PGTBL_ENTRIES && pgtbl[i].owner == laddr
) {
pgtbl[i].owner = VDMA_PAGE_EMPTY;
i++;
}