[PATCH V4] ARM: handle user space mapped pages in flush_kernel_dcache_page

Ming Lei tom.leiming at gmail.com
Fri May 31 05:07:22 EDT 2013


On Sun, May 12, 2013 at 1:35 PM, Simon Baatz <gmbnomis at gmail.com> wrote:
> +void flush_kernel_dcache_page(struct page *page)
> +{
> +       if (cache_is_vivt() || cache_is_vipt_aliasing()) {
> +               struct address_space *mapping;
> +
> +               mapping = page_mapping(page);
> +
> +               if (!mapping || mapping_mapped(mapping))

It is better to replace mapping_mapped(mapping) with page_mapped(page).

> +                       __flush_kernel_dcache_page(page);

I am wondering if I-cache should be flushed here since the user mapping
on the page may be executable and I/D coherency should be maintained.


Thanks,
-- 
Ming Lei



More information about the linux-arm-kernel mailing list