X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=kernel%2Fdebug%2Fdebug_core.c;h=8865caec45fbc9edb72e6d7d36d6c7fd2e0ac4e4;hb=efb5fea23009a0223996e699b54cc9533e2070e9;hp=334b3980ffc14d396e25ccb11644f7f038cbe6e4;hpb=264a8ae739402ab7e14d1794fd4bbce0e339d415;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git diff --git a/kernel/debug/debug_core.c b/kernel/debug/debug_core.c index 334b398..8865cae 100644 --- a/kernel/debug/debug_core.c +++ b/kernel/debug/debug_core.c @@ -49,6 +49,7 @@ #include #include #include +#include #include #include @@ -224,10 +225,17 @@ static void kgdb_flush_swbreak_addr(unsigned long addr) if (!CACHE_FLUSH_IS_SAFE) return; - if (current->mm && current->mm->mmap_cache) { - flush_cache_range(current->mm->mmap_cache, - addr, addr + BREAK_INSTR_SIZE); + if (current->mm) { + int i; + + for (i = 0; i < VMACACHE_SIZE; i++) { + if (!current->vmacache[i]) + continue; + flush_cache_range(current->vmacache[i], + addr, addr + BREAK_INSTR_SIZE); + } } + /* Force flush instruction cache if it was outside the mm */ flush_icache_range(addr, addr + BREAK_INSTR_SIZE); }