Alignment Requirement for MT_MEMORY type

Henry Li hli at broadcom.com
Thu Feb 18 13:08:36 EST 2010


On Wed, Feb 17, 2010 at 04:33:00PM -0800, Henry Li wrote:
> Can someone tell me why there is a requirement for the virtual and 
> physical addresses and size using MT_MEMORY memtype (where prot_l1=0) 
> to be aligned to section boundary (1MB) in 
> linux-2.6.32/arch/arm/mm/mmu.c/create_mapping
> during IO table init?

Because today SDRAM is always a whole number of MB, so its pointless defining it in terms of 4K pages.  MT_MEMORY is not for general purpose use, but only for setting up the initial kernel SDRAM mapping.

>> I see. The platform I am working with has 160kB of SRAM that I need to map as cacheable and shareable but its physical address is not 1MB aligned.  Is there suitable memtype that I could use to map this?



More information about the linux-arm-kernel mailing list