[Question] flush_dcache_page() need to flush icache?

Ming Lei tom.leiming at gmail.com
Wed May 1 04:11:47 EDT 2013


On Tue, Apr 30, 2013 at 11:26 PM, Catalin Marinas
<catalin.marinas at arm.com> wrote:
>
> It's not self-modifying code, this would be code running in user space
> which modifies some other code and it would invoke the ARM-specific
> syscall for flushing.
>
> Here it is about kernel modifying a page which is already mapped in user
> space, hence the check for mapping && mapping_mapped.

I understand that flushing icache is only needed when the page is mapped
as executable in virtual address, right?  If yes, the flush_dcache_page might
be inside read/write on one mapped page(executable in virtual space), then
still looks like self-modifying code case?

Thanks,
-- 
Ming Lei



More information about the linux-arm-kernel mailing list