1. 23 10月, 2008 2 次提交
  2. 06 2月, 2008 3 次提交
    • J
      uml: cover stubs with a VMA · 3963333f
      Jeff Dike 提交于
      Give the stubs a VMA.  This allows the removal of a truly nasty kludge to make
      sure that mm->nr_ptes was correct in exit_mmap.  The underlying problem was
      always that the stubs, which have ptes, and thus allocated a page table,
      weren't covered by a VMA.
      
      This patch fixes that by using install_special_mapping in arch_dup_mmap and
      activate_context to create the VMA.  The stubs have to be moved, since
      shift_arg_pages seems to assume that the stack is the only VMA present at that
      point during exec, and uses vma_adjust to fiddle its VMA.  However, that
      extends the stub VMA by the amount removed from the stack VMA.
      
      To avoid this problem, the stubs were moved to a different fixed location at
      the start of the address space.
      
      The init_stub_pte calls were moved from init_new_context to arch_dup_mmap
      because I was occasionally seeing arch_dup_mmap not being called, causing
      exit_mmap to die.  Rather than figure out what was really happening, I decided
      it was cleaner to just move the calls so that there's no doubt that both the
      pte and VMA creation happen, no matter what.  arch_exit_mmap is used to clear
      the stub ptes at exit time.
      
      The STUB_* constants in as-layout.h no longer depend on UM_TASK_SIZE, that
      that definition is removed, along with the comments complaining about gcc.
      
      Because the stubs are no longer at the top of the address space, some care is
      needed while flushing TLBs.  update_pte_range checks for addresses in the stub
      range and skips them.  flush_thread now issues two unmaps, one for the range
      before STUB_START and one for the range after STUB_END.
      Signed-off-by: NJeff Dike <jdike@linux.intel.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      3963333f
    • J
      uml: clean up TASK_SIZE usage · 42a2b54c
      Jeff Dike 提交于
      Clean up the calculation and use of the usable address space size on the host.
      
      task_size is gone, replaced with TASK_SIZE, which is calculated from
      CONFIG_TOP_ADDR.  get_kmem_end and set_task_sizes_skas are also gone.
      
      host_task_size, which refers to the entire address space usable by the UML
      kernel and which may be larger than the address space usable by a UML process,
      since that has to end on a pgdir boundary, is replaced by CONFIG_TOP_ADDR.
      
      STACK_TOP is now TASK_SIZE minus the two stub pages.
      Signed-off-by: NJeff Dike <jdike@linux.intel.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      42a2b54c
    • K
      uml: improve detection of host cmov · 235a6f06
      Karol Swietlicki 提交于
      This patch introduces a new way of checking for the cmov instruction.  I use
      signal handling instead of reading /proc/cpuinfo.
      
      [ jdike - Fiddled the asm to make it obvious that it didn't mess with
      any in-use registers and made test_for_host_cmov void ]
      
      [akpm@linux-foundation.org: coding-style fixes]
      Signed-off-by: NKarol Swietlicki <magotari@gmail.com>
      Signed-off-by: NJeff Dike <jdike@linux.intel.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      235a6f06
  3. 17 10月, 2007 4 次提交
    • J
      uml: use *SEC_PER_*SEC constants · 1a805219
      Jeff Dike 提交于
      There are various uses of powers of 1000, plus the odd BILLION constant in the
      time code.  However, there are perfectly good definitions of *SEC_PER_*SEC in
      linux/time.h which can be used instaed.
      
      These are replaced directly in kernel code.  Userspace code imports those
      constants as UM_*SEC_PER_*SEC and uses these.
      Signed-off-by: NJeff Dike <jdike@linux.intel.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      1a805219
    • J
      uml: eliminate hz() · 532d0fa4
      Jeff Dike 提交于
      Eliminate hz() since its only purpose was to provide a kernel-space constant
      to userspace code.  This can be done instead by providing the constant
      directly through kernel_constants.h.
      Signed-off-by: NJeff Dike <jdike@linux.intel.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      532d0fa4
    • J
      uml: throw out CONFIG_MODE_TT · 42fda663
      Jeff Dike 提交于
      This patchset throws out tt mode, which has been non-functional for a while.
      
      This is done in phases, interspersed with code cleanups on the affected files.
      
      The removal is done as follows:
      	remove all code, config options, and files which depend on
      CONFIG_MODE_TT
      	get rid of the CHOOSE_MODE macro, which decided whether to
      call tt-mode or skas-mode code, and replace invocations with their
      skas portions
      	replace all now-trivial procedures with their skas equivalents
      
      There are now a bunch of now-redundant pieces of data structures, including
      mode-specific pieces of the thread structure, pt_regs, and mm_context.  These
      are all replaced with their skas-specific contents.
      
      As part of the ongoing style compliance project, I made a style pass over all
      files that were changed.  There are three such patches, one for each phase,
      covering the files affected by that phase but no later ones.
      
      I noticed that we weren't freeing the LDT state associated with a process when
      it exited, so that's fixed in one of the later patches.
      
      The last patch is a tidying patch which I've had for a while, but which caused
      inexplicable crashes under tt mode.  Since that is no longer a problem, this
      can now go in.
      
      This patch:
      
      Start getting rid of tt mode support.
      
      This patch throws out CONFIG_MODE_TT and all config options, code, and files
      which depend on it.
      
      CONFIG_MODE_SKAS is gone and everything that depends on it is included
      unconditionally.
      
      The few changed lines are in re-written Kconfig help, lines which needed
      something skas-related removed from them, and a few more which weren't
      strictly deletions.
      Signed-off-by: NJeff Dike <jdike@linux.intel.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      42fda663
    • J
      uml: stop using libc asm/page.h · 71f926f2
      Jeff Dike 提交于
      Remove includes of asm/page.h from libc code.  This header seems to be
      disappearing, and UML doesn't make much use of it anyway.
      
      The one use, PAGE_SHIFT in stub.h, is handled by copying the constant from the
      kernel side of the house in common_offsets.h.
      Signed-off-by: NJeff Dike <jdike@linux.intel.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      71f926f2
  4. 17 7月, 2007 1 次提交
    • J
      uml: Eliminate kernel allocator wrappers · e4c4bf99
      Jeff Dike 提交于
      UML had two wrapper procedures for kmalloc, um_kmalloc and um_kmalloc_atomic
      because the flag constants weren't available in userspace code.
      kern_constants.h had made kernel constants available for a long time, so there
      is no need for these wrappers any more.  Rather, userspace code calls kmalloc
      directly with the userspace versions of the gfp flags.
      
      kmalloc isn't a real procedure, so I had to essentially copy the inline
      wrapper around __kmalloc.
      
      vmalloc also had its own wrapper for no good reason.  This is now gone.
      Signed-off-by: NJeff Dike <jdike@linux.intel.com>
      Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      e4c4bf99
  5. 17 6月, 2007 1 次提交
  6. 11 5月, 2007 1 次提交
  7. 08 5月, 2007 1 次提交
  8. 12 10月, 2006 2 次提交
  9. 29 9月, 2005 1 次提交
    • A
      [PATCH] uml makefiles sanitized · ecba97d4
      Al Viro 提交于
      UML makefiles sanitized:
       - number of generated headers reduced to 2 (from user-offsets.c and
         kernel-offsets.c resp.).  The rest is made constant and simply
         includes those two.
       - mk_... helpers are gone now that we don't need to generate these
         headers
       - arch/um/include2 removed since everything under arch/um/include/sysdep
         is constant now and symlink can point straight to source tree.
       - dependencies seriously simplified.
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      ecba97d4
  10. 22 9月, 2005 1 次提交
  11. 08 9月, 2005 1 次提交
  12. 06 5月, 2005 1 次提交