projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c4463b3
)
powerpc/tm: Fix null pointer deference in flush_hash_page
author
Michael Neuling
<
[email protected]
>
Thu, 2 May 2013 15:36:14 +0000
(15:36 +0000)
committer
Benjamin Herrenschmidt
<
[email protected]
>
Sun, 5 May 2013 23:25:36 +0000
(09:25 +1000)
Make sure that current->thread.reg exists before we deference it in
flush_hash_page.
Signed-off-by: Michael Neuling <
[email protected]
>
Reported-by: John J Miller <
[email protected]
>
Cc: <
[email protected]
>
Signed-off-by: Benjamin Herrenschmidt <
[email protected]
>
arch/powerpc/mm/hash_utils_64.c
patch
|
blob
|
history
diff --git
a/arch/powerpc/mm/hash_utils_64.c
b/arch/powerpc/mm/hash_utils_64.c
index 3e4c4ed19335d6bd9fc6393c0663cad5bf05c1f7..88ac0eeaadde69bfeceb82d44527754638ed351b 100644
(file)
--- a/
arch/powerpc/mm/hash_utils_64.c
+++ b/
arch/powerpc/mm/hash_utils_64.c
@@
-1230,6
+1230,7
@@
void flush_hash_page(unsigned long vpn, real_pte_t pte, int psize, int ssize,
* unmapping it first, it may see the speculated version.
*/
if (local && cpu_has_feature(CPU_FTR_TM) &&
+ current->thread.regs &&
MSR_TM_ACTIVE(current->thread.regs->msr)) {
tm_enable();
tm_abort(TM_CAUSE_TLBI);