From: gmbnomis@gmail.com (Simon Baatz)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH V4] ARM: handle user space mapped pages in flush_kernel_dcache_page
Date: Wed, 5 Jun 2013 21:55:55 +0200 [thread overview]
Message-ID: <20130605195555.GA16341@schnuecks.de> (raw)
In-Reply-To: <20130605135817.GL8758@arm.com>
On Wed, Jun 05, 2013 at 02:58:17PM +0100, Catalin Marinas wrote:
> On Mon, Jun 03, 2013 at 06:38:18PM +0100, Simon Baatz wrote:
...
> > The actual flush covering both the lowmem and highmem cases actually
> > is as simple as this (inspired by __flush_dcache_page() in 2.6.32):
> >
> > addr = page_address(page);
> > #ifdef CONFIG_HIGHMEM
> > /*
> > * kmap_atomic() doesn't set the page virtual address, and
> > * kunmap_atomic() takes care of cache flushing already.
> > */
> > if (addr)
> > #endif
> > __cpuc_flush_dcache_area(addr, PAGE_SIZE);
> >
> > If you agree that this makes sense, I will send a new version.
>
> It makes sense (with the addition of the cache_is_vivt() check). Maybe
> something like
>
> if (IS_ENABLED(CONFIG_HIGHMEM) && addr)
>
> to avoid the #ifdef.
Yes, IS_ENABLED is much nicer. However, IS_ENABLED apparently is not
available for <= 3.0.x. :-(
> > If we change the patch this way, there is no need to split off
> > __flush_kernel_dcache_page() from __flush_dcache_page(), which also
> > makes it simpler to apply to past stable kernels.
> >
> > The only thing we need to be aware of is the change of
> > flush_kernel_dcache_page() in 2.6.37 (commit f8b63c1). In earlier
> > versions, we would only need to fix the highmem case. However, I
> > wonder whether it makes sense to apply a fix to 2.6.32 and 2.6.34
> > without this ever being reported as a problem.
>
> I think you can cc stable with a dependency for 2.6.37 onwards and send
> a different patch for earlier versions directly to the
> stable at vger.kernel.org alias, specifying the versions it needs to be
> applied to.
Ok. Next version of the patch then for >= 3.2.x. 3.0.x is special (#ifdef).
2.6.3[24].x are special anyway. However, for the latter I still
wonder whether this makes sense. "stable_kernel_rules.txt" states:
- It must fix a real bug that bothers people (not a, "This could be a
problem..." type thing).
I don't know anyone who is/was bothered by the higmem bug.
(Btw. I verified that the highmem problem is really there (using
current linux-next) and is fixed by the proposed patch.)
- Simon
next prev parent reply other threads:[~2013-06-05 19:55 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-12 5:35 [PATCH V4] ARM: handle user space mapped pages in flush_kernel_dcache_page Simon Baatz
2013-05-23 10:43 ` Catalin Marinas
2013-05-25 3:53 ` Nicolas Pitre
2013-05-28 9:55 ` Catalin Marinas
2013-05-28 17:52 ` Nicolas Pitre
2013-05-29 10:37 ` Catalin Marinas
2013-05-29 14:39 ` Nicolas Pitre
2013-05-29 16:32 ` Nicolas Pitre
2013-05-29 17:33 ` Catalin Marinas
2013-05-27 21:42 ` Simon Baatz
2013-05-28 10:20 ` Catalin Marinas
2013-05-28 18:50 ` Nicolas Pitre
2013-05-29 11:05 ` Catalin Marinas
2013-05-29 19:16 ` Simon Baatz
2013-05-30 16:43 ` Catalin Marinas
2013-05-31 12:05 ` Jason Cooper
2013-05-31 14:15 ` Catalin Marinas
2013-05-31 14:20 ` Jason Cooper
2013-06-03 17:38 ` Simon Baatz
2013-06-03 18:03 ` Jason Cooper
2013-06-03 19:11 ` Simon Baatz
2013-06-03 19:22 ` Jason Cooper
2013-06-03 20:38 ` Greg KH
2013-06-05 13:58 ` Catalin Marinas
2013-06-05 19:55 ` Simon Baatz [this message]
2013-05-31 9:07 ` Ming Lei
2013-05-31 18:54 ` Simon Baatz
2013-06-01 10:27 ` Ming Lei
2013-06-03 9:33 ` Catalin Marinas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20130605195555.GA16341@schnuecks.de \
--to=gmbnomis@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.