Skip to content

Commit

Permalink
[PATCH] uml: fix vsyscall brokenness
Browse files Browse the repository at this point in the history
The #if/#ifdef cleanup exposed a bug in UML's ELF header processing.  With
this bug fixed, UML recognizes the vsyscall info coming from the host.  On
FC4, there is a vsyscall page low in the address space, which UML doesn't
provide.  This causes an infinite page fault loop and a hang on boot.

This patch works around that by making this look like a no-vsyscall system.

Signed-off-by: Jeff Dike <jdike@addtoit.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Jeff Dike authored and Linus Torvalds committed Jul 29, 2005
1 parent e4c5c82 commit a502a35
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion arch/um/os-Linux/elf_aux.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,10 @@
*/
#include <elf.h>
#include <stddef.h>
#include <asm/elf.h>
#include "init.h"
#include "elf_user.h"
#include <asm/elf.h>
#include "mem_user.h"

#if ELF_CLASS == ELFCLASS32
typedef Elf32_auxv_t elf_auxv_t;
Expand Down Expand Up @@ -41,6 +42,9 @@ __init void scan_elf_aux( char **envp)
break;
case AT_SYSINFO_EHDR:
vsyscall_ehdr = auxv->a_un.a_val;
/* See if the page is under TASK_SIZE */
if (vsyscall_ehdr < (unsigned long) envp)
vsyscall_ehdr = 0;
break;
case AT_HWCAP:
elf_aux_hwcap = auxv->a_un.a_val;
Expand Down

0 comments on commit a502a35

Please sign in to comment.