On Wed, 17 Oct 2007 11:10:23 +0200 (CEST) Jiri Kosina <jikos@jikos.cz> wrote:Maybe this can be fix. Thanks, -Kame == ia32 on x86_64 seems to be handled as it is. arch/x86_64/mm/mmap.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) Index: devel-2.6.23-mm1/arch/x86_64/mm/mmap.c =================================================================== --- devel-2.6.23-mm1.orig/arch/x86_64/mm/mmap.c +++ devel-2.6.23-mm1/arch/x86_64/mm/mmap.c @@ -54,13 +54,17 @@ static inline unsigned long mmap_base(vo return TASK_SIZE - (gap & PAGE_MASK); } -static inline int mmap_is_legacy(void) +static inline int mmap_is_32(void) { #ifdef CONFIG_IA32_EMULATION if (test_thread_flag(TIF_IA32)) return 1; #endif + return 0; +} +static inline int mmap_is_legacy(void) +{ if (current->personality & ADDR_COMPAT_LAYOUT) return 1; @@ -89,7 +93,12 @@ void arch_pick_mmap_layout(struct mm_str * Fall back to the standard layout if the personality * bit is set, or if the expected stack growth is unlimited: */ - if (mmap_is_legacy()) { + if (mmap_is_32()) { +#ifdef CONFIG_IA32_EMULATION + /* ia32_pick_mmap_layout has its own. */ + return ia32_pick_mmap_layout(mm); +#endif + } else if(mmap_is_legacy()) { mm->mmap_base = TASK_UNMAPPED_BASE; mm->get_unmapped_area = arch_get_unmapped_area; mm->unmap_area = arch_unmap_area; -
| Linus Torvalds | Linux 2.6.27-rc8 |
| Trent Piepho | [PATCH] [POWERPC] Improve (in|out)_beXX() asm code |
| Satyam Sharma | Re: 2.6.23-rc4-mm1 "no CRC" MODPOST warnings |
| Bart Van Assche | Integration of SCST in the mainstream Linux kernel |
git: | |
| Bill Lear | Dangers of working on a tracking branch |
| Jeff King | Re: What's cooking in git/spearce.git (topics) |
| Jason Garber | git push [rejected] question |
| Maxim Gordienko | [GIT-P4] usage under Windows |
| Richard Stallman | Real men don't attack straw men |
| Leon Dippenaar | New tcp stack attack |
| GVG GVG | ssh_exchange_identification: Connection closed by remote host |
| Brandon Lee | DELL PERC 5iR slow performance |
| Jeff Garzik | Re: [PATCH] drivers/net: remove network drivers' last few uses of IRQF_SAMPLE_RANDOM |
| Paul Moore | [PATCH v7 00/17] Labeled networking patches for 2.6.28 |
| Denys Vlasenko | Re: bnx2 dirver's firmware images |
| Herbert Xu | Re: csum offload and af_packet |
