about PMD_SHIFT value (22 or 18?)
Chan Kim
ckim at etri.re.kr
Thu May 1 07:44:21 EDT 2014
Hi,
Hope someone could answer to this question..
As some of you know, SRMMU(Sparc Reference MMU in Sparc V8) uses top 8, 6, 6 bits of the linear address as PGT, PMD, PTE table index.
so PGDIR_SHIFT is 24 and PMD_SHIFT is 18, and PTE_SHIFT is 12. (page size 4096) These shift values are for getting the index to into each table.
But in http://lxr.free-electrons.com/source/arch/sparc/include/asm/pgtable_32.h#L35
#define PMD_SHIFT 22.
and in http://lxr.free-electrons.com/source/arch/sparc/include/asm/page_32.h#L84
typedef struct { unsigned long pmdv[16]; } pmd_t;
Why is it like this? (those sources are for sparc)
I'm having some confusion from this..
Could someone please explain it or give me a good reference about this?
Best regards,
Chan
More information about the Kernelnewbies
mailing list