Question: how to make one page readonly on ARM

Nicolas Pitre nico at fluxnic.net
Thu Feb 16 13:31:41 EST 2012


On Thu, 16 Feb 2012, 晁永生 wrote:

> 2012/2/16 Russell King - ARM Linux <linux at arm.linux.org.uk>:
> > On Thu, Feb 16, 2012 at 12:54:27PM +0800, 晁永生 wrote:
> >> Hi,
> >> I get one page by __get_free_page and can make it readonly by
> >> set_memory_ro on X86,
> >> but how to do this on ARM?
> >
> > You can't, because we map all kernel space with 1MB section mappings.
> 
> sorry, I don't quite understand. I am kernel newbie.
> Do you mean that if I want to make one memory region readonly, it has
> to be in MB unit?
> Does ARM kernel have any functions similar to set_memory_ro?

No.

Maybe if you tell us more about what your end goal is, we might be able 
to suggest alternatives for solving your problem.


Nicolas


More information about the linux-arm-kernel mailing list