Commit 79acf83e authored by Ralf Baechle's avatar Ralf Baechle

Moves a test which determines if we actually need to perform a

cacheflush to the right place.  That's a bug which is harmless on UP
but a severe bug on SMP.
Signed-off-by: default avatarRalf Baechle <ralf@linux-mips.org>
parent c6e8b587
...@@ -376,6 +376,13 @@ static inline void local_r4k_flush_cache_page(void *args) ...@@ -376,6 +376,13 @@ static inline void local_r4k_flush_cache_page(void *args)
pmd_t *pmdp; pmd_t *pmdp;
pte_t *ptep; pte_t *ptep;
/*
* If ownes no valid ASID yet, cannot possibly have gotten
* this page into the cache.
*/
if (cpu_context(smp_processor_id(), vma->vm_mm) == 0)
return;
page &= PAGE_MASK; page &= PAGE_MASK;
pgdp = pgd_offset(mm, page); pgdp = pgd_offset(mm, page);
pudp = pud_offset(pgdp, page); pudp = pud_offset(pgdp, page);
...@@ -432,13 +439,6 @@ static void r4k_flush_cache_page(struct vm_area_struct *vma, unsigned long page, ...@@ -432,13 +439,6 @@ static void r4k_flush_cache_page(struct vm_area_struct *vma, unsigned long page,
{ {
struct flush_cache_page_args args; struct flush_cache_page_args args;
/*
* If ownes no valid ASID yet, cannot possibly have gotten
* this page into the cache.
*/
if (cpu_context(smp_processor_id(), vma->vm_mm) == 0)
return;
args.vma = vma; args.vma = vma;
args.page = page; args.page = page;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment