| To: | NamJae Jeon <linkinjeon@gmail.com> |
|---|---|
| Subject: | Re: data consistency of high page |
| From: | "Dennis.Yxun" <dennis.yxun@gmail.com> |
| Date: | Tue, 28 Feb 2012 11:03:02 +0800 |
| Cc: | Minchan Kim <minchan.kim@gmail.com>, Ralf Baechle <ralf@linux-mips.org>, lkml <linux-kernel@vger.kernel.org>, linux-mips <linux-mips@linux-mips.org>, yan@mips.com |
| Dkim-signature: | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=uRGxvOeQhK9Q9dDkJO58lrpWHx+c0JyUYLCVs6WTMvg=; b=uzuMwhIN9ogs94PD34ZtxKshm2NVksdBgW6FANbbJN6koR+jscLQx93wnRcGluya+C HEFc8A33jsdQadAZhjTxASTOgp9VYvcFZ7PacIr9RrFDMUuzpo74AhVjWbe/WmO33Gy0 a83FxNFcaq+W9kwQsbi5veniWy6lifIhIyn7A= |
| In-reply-to: | <BANLkTimKw3mg8N-gBxh3jbo9msaHOF3qPA@mail.gmail.com> |
| References: | <28c262361003230146o7bca61e6h3af2062b1172fdb2@mail.gmail.com> <afc622a1003230511o108556f4s5d1282bd3122b3d9@mail.gmail.com> <BANLkTimKw3mg8N-gBxh3jbo9msaHOF3qPA@mail.gmail.com> |
| Sender: | linux-mips-bounce@linux-mips.org |
|
Hi NamJae: We hit pretty much the same problem, highmem + cache consistence but our hardware should have cache alias problem Could you try attached following patch? dmesg: [ 0.000000] PID hash table entries: 1024 (order: 0, 4096 bytes) [ 0.000000] Dentry cache hash table entries: 32768 (order: 5, 131072 bytes) [ 0.000000] Inode-cache hash table entries: 16384 (order: 4, 65536 bytes) [ 0.000000] Primary instruction cache 16kB, VIPT, 4-way, linesize 32 bytes. [ 0.000000] Primary data cache 16kB, 4-way, VIPT, no aliases, linesize 32 byt es [ 0.000000] MIPS secondary cache 128kB, 8-way, linesize 32 bytes. [ 0.000000] Writing ErrCtl register=00000000 [ 0.000000] Readback ErrCtl register=00000000 [ 0.000000] Memory: 510548k/262144k available (2728k kernel code, 13740k rese rved, 630k data, 5784k init, 262144k highmem) diff --git a/arch/mips/mm/cache.c b/arch/mips/mm/cache.c index 00d70c8..536b7f9 100644 --- a/arch/mips/mm/cache.c +++ b/arch/mips/mm/cache.c @@ -15,6 +15,7 @@ #include <linux/sched.h> #include <linux/syscalls.h> #include <linux/mm.h> +#include <linux/highmem.h> #include <asm/cacheflush.h> #include <asm/processor.h> @@ -83,8 +84,13 @@ void __flush_dcache_page(struct page *page) struct address_space *mapping = page_mapping(page); unsigned long addr; - if (PageHighMem(page)) + if (PageHighMem(page) && + (addr = (unsigned long) kmap_atomic(page, KM_SYNC_DCACHE))) { + flush_data_cache_page(addr); + kunmap_atomic((void *)addr, KM_SYNC_DCACHE); return; + } On Tue, Apr 5, 2011 at 4:17 PM, NamJae Jeon <linkinjeon@gmail.com> wrote: Hi. |
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | [PATCH v2 10/11] MIPS: BCM47XX: move and extend sprom parsing, Hauke Mehrtens |
|---|---|
| Next by Date: | Re: data consistency of high page, Namjae Jeon |
| Previous by Thread: | [PATCH v2 00/11] ssb/bcma/BCM47XX: sprom fixes and extensions, Hauke Mehrtens |
| Next by Thread: | Re: data consistency of high page, Namjae Jeon |
| Indexes: | [Date] [Thread] [Top] [All Lists] |