1. 11 5月, 2010 1 次提交
    • P
      sh: bootmem refactoring. · 4bc277ac
      Paul Mundt 提交于
      This reworks much of the bootmem setup and initialization code allowing
      us to get rid of duplicate work between the NUMA and non-NUMA cases. The
      end result is that we end up with a much more flexible interface for
      supporting more complex topologies (fake NUMA, highmem, etc, etc.) which
      is entirely LMB backed. This is an incremental step for more NUMA work as
      well as gradually enabling migration off of bootmem entirely.
      Signed-off-by: NPaul Mundt <lethal@linux-sh.org>
      4bc277ac
  2. 10 5月, 2010 1 次提交
  3. 30 3月, 2010 1 次提交
    • T
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking... · 5a0e3ad6
      Tejun Heo 提交于
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h
      
      percpu.h is included by sched.h and module.h and thus ends up being
      included when building most .c files.  percpu.h includes slab.h which
      in turn includes gfp.h making everything defined by the two files
      universally available and complicating inclusion dependencies.
      
      percpu.h -> slab.h dependency is about to be removed.  Prepare for
      this change by updating users of gfp and slab facilities include those
      headers directly instead of assuming availability.  As this conversion
      needs to touch large number of source files, the following script is
      used as the basis of conversion.
      
        http://userweb.kernel.org/~tj/misc/slabh-sweep.py
      
      The script does the followings.
      
      * Scan files for gfp and slab usages and update includes such that
        only the necessary includes are there.  ie. if only gfp is used,
        gfp.h, if slab is used, slab.h.
      
      * When the script inserts a new include, it looks at the include
        blocks and try to put the new include such that its order conforms
        to its surrounding.  It's put in the include block which contains
        core kernel includes, in the same order that the rest are ordered -
        alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
        doesn't seem to be any matching order.
      
      * If the script can't find a place to put a new include (mostly
        because the file doesn't have fitting include block), it prints out
        an error message indicating which .h file needs to be added to the
        file.
      
      The conversion was done in the following steps.
      
      1. The initial automatic conversion of all .c files updated slightly
         over 4000 files, deleting around 700 includes and adding ~480 gfp.h
         and ~3000 slab.h inclusions.  The script emitted errors for ~400
         files.
      
      2. Each error was manually checked.  Some didn't need the inclusion,
         some needed manual addition while adding it to implementation .h or
         embedding .c file was more appropriate for others.  This step added
         inclusions to around 150 files.
      
      3. The script was run again and the output was compared to the edits
         from #2 to make sure no file was left behind.
      
      4. Several build tests were done and a couple of problems were fixed.
         e.g. lib/decompress_*.c used malloc/free() wrappers around slab
         APIs requiring slab.h to be added manually.
      
      5. The script was run on all .h files but without automatically
         editing them as sprinkling gfp.h and slab.h inclusions around .h
         files could easily lead to inclusion dependency hell.  Most gfp.h
         inclusion directives were ignored as stuff from gfp.h was usually
         wildly available and often used in preprocessor macros.  Each
         slab.h inclusion directive was examined and added manually as
         necessary.
      
      6. percpu.h was updated not to include slab.h.
      
      7. Build test were done on the following configurations and failures
         were fixed.  CONFIG_GCOV_KERNEL was turned off for all tests (as my
         distributed build env didn't work with gcov compiles) and a few
         more options had to be turned off depending on archs to make things
         build (like ipr on powerpc/64 which failed due to missing writeq).
      
         * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
         * powerpc and powerpc64 SMP allmodconfig
         * sparc and sparc64 SMP allmodconfig
         * ia64 SMP allmodconfig
         * s390 SMP allmodconfig
         * alpha SMP allmodconfig
         * um on x86_64 SMP allmodconfig
      
      8. percpu.h modifications were reverted so that it could be applied as
         a separate patch and serve as bisection point.
      
      Given the fact that I had only a couple of failures from tests on step
      6, I'm fairly confident about the coverage of this conversion patch.
      If there is a breakage, it's likely to be something in one of the arch
      headers which should be easily discoverable easily on most builds of
      the specific arch.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Guess-its-ok-by: NChristoph Lameter <cl@linux-foundation.org>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
      5a0e3ad6
  4. 18 2月, 2010 1 次提交
    • P
      sh: Merge legacy and dynamic PMB modes. · d01447b3
      Paul Mundt 提交于
      This implements a bit of rework for the PMB code, which permits us to
      kill off the legacy PMB mode completely. Rather than trusting the boot
      loader to do the right thing, we do a quick verification of the PMB
      contents to determine whether to have the kernel setup the initial
      mappings or whether it needs to mangle them later on instead.
      
      If we're booting from legacy mappings, the kernel will now take control
      of them and make them match the kernel's initial mapping configuration.
      This is accomplished by breaking the initialization phase out in to
      multiple steps: synchronization, merging, and resizing. With the recent
      rework, the synchronization code establishes page links for compound
      mappings already, so we build on top of this for promoting mappings and
      reclaiming unused slots.
      
      At the same time, the changes introduced for the uncached helpers also
      permit us to dynamically resize the uncached mapping without any
      particular headaches. The smallest page size is more than sufficient for
      mapping all of kernel text, and as we're careful not to jump to any far
      off locations in the setup code the mapping can safely be resized
      regardless of whether we are executing from it or not.
      Signed-off-by: NPaul Mundt <lethal@linux-sh.org>
      d01447b3
  5. 17 2月, 2010 1 次提交
    • P
      sh: uncached mapping helpers. · 9edef286
      Paul Mundt 提交于
      This adds some helper routines for uncached mapping support. This
      simplifies some of the cases where we need to check the uncached mapping
      boundaries in addition to giving us a centralized location for building
      more complex manipulation on top of.
      Signed-off-by: NPaul Mundt <lethal@linux-sh.org>
      9edef286
  6. 12 2月, 2010 1 次提交
    • P
      sh: Isolate uncached mapping support. · b0f3ae03
      Paul Mundt 提交于
      This splits out the uncached mapping support under its own config option,
      presently only used by 29-bit mode and 32-bit + PMB. This will make it
      possible to optionally add an uncached mapping on sh64 as well as booting
      without an uncached mapping for 32-bit.
      Signed-off-by: NPaul Mundt <lethal@linux-sh.org>
      b0f3ae03
  7. 21 1月, 2010 2 次提交
  8. 20 1月, 2010 2 次提交
  9. 19 1月, 2010 1 次提交
  10. 18 1月, 2010 1 次提交
  11. 16 1月, 2010 1 次提交
  12. 12 1月, 2010 1 次提交
  13. 17 12月, 2009 1 次提交
    • M
      sh: Definitions for 3-level page table layout · 5d9b4b19
      Matt Fleming 提交于
      If using 64-bit PTEs and 4K pages then each page table has 512 entries
      (as opposed to 1024 entries with 32-bit PTEs). Unlike MIPS, SH follows
      the convention that all structures in the page table (pgd_t, pmd_t,
      pgprot_t, etc) must be the same size. Therefore, 64-bit PTEs require
      64-bit PGD entries, etc. Using 2-levels of page tables and 64-bit PTEs
      it is only possible to map 1GB of virtual address space.
      
      In order to map all 4GB of virtual address space we need to adopt a
      3-level page table layout. This actually works out better for
      CONFIG_SUPERH32 because we only waste 2 PGD entries on the P1 and P2
      areas (which are untranslated) instead of 256.
      Signed-off-by: NMatt Fleming <matt@console-pimps.org>
      Signed-off-by: NPaul Mundt <lethal@linux-sh.org>
      5d9b4b19
  14. 27 10月, 2009 1 次提交
  15. 10 10月, 2009 1 次提交
  16. 23 9月, 2009 3 次提交
  17. 22 9月, 2009 1 次提交
  18. 03 9月, 2009 1 次提交
    • P
      sh: Fix up and optimize the kmap_coherent() interface. · 0906a3ad
      Paul Mundt 提交于
      This fixes up the kmap_coherent/kunmap_coherent() interface for recent
      changes both in the page fault path and the shared cache flushers, as
      well as adding in some optimizations.
      
      One of the key things to note here is that the TLB flush itself is
      deferred until the unmap, and the call in to update_mmu_cache() itself
      goes away, relying on the regular page fault path to handle the lazy
      dcache writeback if necessary.
      Signed-off-by: NPaul Mundt <lethal@linux-sh.org>
      0906a3ad
  19. 15 8月, 2009 2 次提交
  20. 23 6月, 2009 2 次提交
  21. 22 5月, 2009 1 次提交
  22. 07 1月, 2009 1 次提交
    • G
      mm: show node to memory section relationship with symlinks in sysfs · c04fc586
      Gary Hade 提交于
      Show node to memory section relationship with symlinks in sysfs
      
      Add /sys/devices/system/node/nodeX/memoryY symlinks for all
      the memory sections located on nodeX.  For example:
      /sys/devices/system/node/node1/memory135 -> ../../memory/memory135
      indicates that memory section 135 resides on node1.
      
      Also revises documentation to cover this change as well as updating
      Documentation/ABI/testing/sysfs-devices-memory to include descriptions
      of memory hotremove files 'phys_device', 'phys_index', and 'state'
      that were previously not described there.
      
      In addition to it always being a good policy to provide users with
      the maximum possible amount of physical location information for
      resources that can be hot-added and/or hot-removed, the following
      are some (but likely not all) of the user benefits provided by
      this change.
      Immediate:
        - Provides information needed to determine the specific node
          on which a defective DIMM is located.  This will reduce system
          downtime when the node or defective DIMM is swapped out.
        - Prevents unintended onlining of a memory section that was
          previously offlined due to a defective DIMM.  This could happen
          during node hot-add when the user or node hot-add assist script
          onlines _all_ offlined sections due to user or script inability
          to identify the specific memory sections located on the hot-added
          node.  The consequences of reintroducing the defective memory
          could be ugly.
        - Provides information needed to vary the amount and distribution
          of memory on specific nodes for testing or debugging purposes.
      Future:
        - Will provide information needed to identify the memory
          sections that need to be offlined prior to physical removal
          of a specific node.
      
      Symlink creation during boot was tested on 2-node x86_64, 2-node
      ppc64, and 2-node ia64 systems.  Symlink creation during physical
      memory hot-add tested on a 2-node x86_64 system.
      Signed-off-by: NGary Hade <garyhade@us.ibm.com>
      Signed-off-by: NBadari Pulavarty <pbadari@us.ibm.com>
      Acked-by: NIngo Molnar <mingo@elte.hu>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      c04fc586
  23. 10 11月, 2008 1 次提交
  24. 21 10月, 2008 1 次提交
  25. 20 9月, 2008 1 次提交
    • P
      sh: Support kernel stacks smaller than a page. · c15c5f8c
      Paul Mundt 提交于
      This follows the powerpc commit f6a61680
      '[POWERPC] Fix kernel stack allocation alignment'.
      
      SH has traditionally forced the thread order to be relative to the page
      size, so there were never any situations where the same bug was
      triggered by slub. Regardless, the usage of > 8kB stacks for the larger
      page sizes is overkill, so we switch to using slab allocations there,
      as per the powerpc change.
      Signed-off-by: NPaul Mundt <lethal@linux-sh.org>
      c15c5f8c
  26. 08 9月, 2008 3 次提交
  27. 27 7月, 2008 1 次提交
  28. 25 7月, 2008 1 次提交
  29. 28 4月, 2008 1 次提交
  30. 06 3月, 2008 1 次提交
  31. 14 2月, 2008 1 次提交
  32. 28 1月, 2008 1 次提交