10 May, 2007

6 commits


09 May, 2007

34 commits

  • Commit d1953c8888ef034b912ee33bc2ea2cce6a414402 removed the use of
    4level-fixup.h for 32-bit systems under arch/powerpc. However, I
    missed a few things activated on some configurations, resulting in
    some warnings (at least with STRICT_MM_TYPECHECKS enabled) and build
    errors in some circumstances. This fixes it.

    Signed-off-by: David Gibson
    Signed-off-by: Paul Mackerras

    David Gibson
     
  • When an EEH event is detected, and after the device driver
    has been notified, but before the device is reset, enable
    MMIO to the adapter, and grab the contents of the PCI status
    and command registers, the PCI-X status and command, and the
    PCI-E capability 10 and AER registers. Pass these up to the
    RTAS error log, and also printk them.

    Signed-off-by: Linas Vepstas
    Signed-off-by: Paul Mackerras

    Linas Vepstas
     
  • If an EEH event is observed, capture PCI config space info about
    the device, wrap it up and pass it to the event logger. This
    pach just slots in the basic logging function. A later patch
    will provide for more through data gathering.

    Signed-off-by: Linas Vepstas
    Signed-off-by: Paul Mackerras

    Linas Vepstas
     
  • Make some minor adjustments to the EEH error messages.

    Signed-off-by: Linas Vepstas
    Signed-off-by: Paul Mackerras

    Linas Vepstas
     
  • It turns out many/most versions of firmware enable MMIO when
    the slto-error-detail rtas call is made (in violation of the
    architecture). Thus, it would be best to call slot-error-detail
    only after notifying device drivers of a freeze, as otherwise,
    a variety of strange and unexpected things may happen.

    Signed-off-by: Linas Vepstas
    Signed-off-by: Paul Mackerras

    Linas Vepstas
     
  • of_get_mac_address() returns a const pointer, so the result
    should be stored in a const pointer.

    Signed-off-by: Scott Wood
    Signed-off-by: Paul Mackerras

    Scott Wood
     
  • The SLUB allocator relies on struct page fields first_page and slab,
    overwritten by ptl when SPLIT_PTLOCK: so the SLUB allocator cannot then
    be used for the lowest level of pagetable pages. This was obstructing
    SLUB on PowerPC, which uses kmem_caches for its pagetables. So convert
    its pte level to use normal gfp pages (whereas pmd, pud and 64k-page pgd
    want partpages, so continue to use kmem_caches for pmd, pud and pgd).

    Signed-off-by: Hugh Dickins
    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Hugh Dickins
     
  • This adds an option to spufs when the kernel is configured for
    4K page to give it the ability to use 64K pages for SPE local store
    mappings.

    Currently, we are optimistic and try order 4 allocations when creating
    contexts. If that fails, the code will fallback to 4K automatically.

    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Benjamin Herrenschmidt
     
  • This adds the ability for a kernel compiled with 4K page size
    to have special slices containing 64K pages and hash the right type
    of hash PTEs.

    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Benjamin Herrenschmidt
     
  • The basic issue is to be able to do what hugetlbfs does but with
    different page sizes for some other special filesystems; more
    specifically, my need is:

    - Huge pages

    - SPE local store mappings using 64K pages on a 4K base page size
    kernel on Cell

    - Some special 4K segments in 64K-page kernels for mapping a dodgy
    type of powerpc-specific infiniband hardware that requires 4K MMU
    mappings for various reasons I won't explain here.

    The main issues are:

    - To maintain/keep track of the page size per "segment" (as we can
    only have one page size per segment on powerpc, which are 256MB
    divisions of the address space).

    - To make sure special mappings stay within their allotted
    "segments" (including MAP_FIXED crap)

    - To make sure everybody else doesn't mmap/brk/grow_stack into a
    "segment" that is used for a special mapping

    Some of the necessary mechanisms to handle that were present in the
    hugetlbfs code, but mostly in ways not suitable for anything else.

    The patch relies on some changes to the generic get_unmapped_area()
    that just got merged. It still hijacks hugetlb callbacks here or
    there as the generic code hasn't been entirely cleaned up yet but
    that shouldn't be a problem.

    So what is a slice ? Well, I re-used the mechanism used formerly by our
    hugetlbfs implementation which divides the address space in
    "meta-segments" which I called "slices". The division is done using
    256MB slices below 4G, and 1T slices above. Thus the address space is
    divided currently into 16 "low" slices and 16 "high" slices. (Special
    case: high slice 0 is the area between 4G and 1T).

    Doing so simplifies significantly the tracking of segments and avoids
    having to keep track of all the 256MB segments in the address space.

    While I used the "concepts" of hugetlbfs, I mostly re-implemented
    everything in a more generic way and "ported" hugetlbfs to it.

    Slices can have an associated page size, which is encoded in the mmu
    context and used by the SLB miss handler to set the segment sizes. The
    hash code currently doesn't care, it has a specific check for hugepages,
    though I might add a mechanism to provide per-slice hash mapping
    functions in the future.

    The slice code provide a pair of "generic" get_unmapped_area() (bottomup
    and topdown) functions that should work with any slice size. There is
    some trickiness here so I would appreciate people to have a look at the
    implementation of these and let me know if I got something wrong.

    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Benjamin Herrenschmidt
     
  • The code for demoting segments to 4K had some issues, like for example,
    when using _PAGE_4K_PFN flag, the first CPU to hit it would do the
    demotion, but other CPUs hitting the same page wouldn't properly flush
    their SLBs if mmu_ci_restriction isn't set. There are also potential
    issues with hash_preload not handling _PAGE_4K_PFN. All of these are
    non issues on current hardware but might bite us in the future.

    This patch thus fixes it by:

    - Taking the test comparing the mm and current CPU context page
    sizes to decide to flush SLBs out of the mmu_ci_restrictions test
    since that can also be triggered by _PAGE_4K_PFN pages

    - Due to the above being done all the time, demote_segment_4k
    doesn't need update the context and flush the SLB

    - demote_segment_4k can be static and doesn't need an EXPORT_SYMBOL

    - Making hash_preload ignore anything that has either _PAGE_4K_PFN
    or _PAGE_NO_CACHE set, thus avoiding duplication of the complicated
    logic in hash_page() (and possibly making hash_preload a little bit
    faster for the normal case).

    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Benjamin Herrenschmidt
     
  • This makes the new iSeries virtual console drivers (nvc_iseries) the
    default and prevents viocons being built unless explicitly selected.
    Also it makes no sense to have the console as a module.

    Signed-off-by: Stephen Rothwell
    Signed-off-by: Paul Mackerras

    Stephen Rothwell
     
  • lparmap.c: Assembler messages:
    lparmap.c:51: Warning: ignoring changed section attributes for .text

    Idea from Segher Boessenkool.

    Signed-off-by: Stephen Rothwell
    Signed-off-by: Paul Mackerras

    Stephen Rothwell
     
  • On some powerpc architectures (notably 64-bit powermac) there is a memory
    hole, for example on powermacs between 2G and 4G. Since we use the flat
    memory model regardless, these pages must be marked as nosave (for suspend
    to disk.)

    Signed-off-by: Johannes Berg
    Cc: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Johannes Berg
     
  • This patch introduces a new register_nosave_region_late function that
    can be called from initcalls when register_nosave_region can no longer
    be used because it uses bootmem.

    Signed-off-by: Johannes Berg
    Acked-by: Rafael J. Wysocki
    Signed-off-by: Paul Mackerras

    Johannes Berg
     
  • In the process of rewriting the x86 setup code, I found a number of
    inaccuracies and outdated recommendations in the boot protocol
    documentation. Revamp to make it more up to date.

    In particular, the common use of the heap actually requires (slightly)
    more than 4K of heap plus stack, which is the recommended amount in
    the document; currently the code compensates by being smaller than
    specified, but we can't assume that will be true forever. Thus,
    recommend that if we have a modern bzImage kernel, that the bootloader
    maximizes the available space.

    Signed-off-by: H. Peter Anvin
    Signed-off-by: Linus Torvalds

    H. Peter Anvin
     
  • … from the "expired" array'

    Revert commit bd53f96ca54a21c07e7a0ae1886fa623d370b85f.

    Con says:

    This is no good, sorry. The one I saw originally was with the staircase
    deadline cpu scheduler in situ and was different.

    #define TASK_PREEMPTS_CURR(p, rq) \
    ((p)->prio < (rq)->curr->prio)
    (((p)->prio < (rq)->curr->prio) && ((p)->array == (rq)->active))

    This will fail to wake up a runqueue for a task that has been migrated to the
    expired array of a runqueue which is otherwise idle which can happen with smp
    balancing,

    Cc: Dmitry Adamushko <dmitry.adamushko@gmail.com>
    Cc: Con Kolivas <kernel@kolivas.org>
    Cc: Ingo Molnar <mingo@elte.hu>
    Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
    Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

    Andrew Morton
     
  • We have a standard suffix to associate a designation string to a sensor:
    _label. Use it instead of _position so that libsensors will catch it.
    (This isn't implemented yet, but should be soon.)

    Signed-off-by: Jean Delvare
    Cc: Nicolas Boichat
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jean Delvare
     
  • Let the applesmc device export its address to userspace. libsensors needs
    this to recognize the device and give it a unique ID.

    Signed-off-by: Jean Delvare
    Cc: Nicolas Boichat
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jean Delvare
     
  • Zero-sized allocations are pointless anyway, and the SLUB allocator
    complains about them, so stop doing that.

    Signed-off-by: Tilman Schmidt
    Signed-off-by: Hansjoerg Lipp
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Tilman Schmidt
     
  • The recent cleanup uncovered that include/asm-m68k/scatterlist.h
    needs to include

    Signed-off-by: Geert Uytterhoeven
    Cc: Roman Zippel
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Geert Uytterhoeven
     
  • Miscellaneous fixes to bring FRV up to date:

    (1) Copy the new syscall numbers from i386 to asm-frv/unistd.h and fill out
    the syscall table in entry.S too.

    (2) Mark __frv_uart0 and __frv_uart1 __pminitdata rather than __initdata so
    that determine_clocks() can access them when CONFIG_PM=y.

    (3) Make arch/frv/mm/elf-fdpic.c include asm/mman.h so that MAP_FIXED is
    available (fixes commit 2fd3bebaad9da3b3b99c46a3389099424bf7ee35).

    Signed-off-by: David Howells
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Howells
     
  • /proc/pid/clear_refs is only defined in the CONFIG_MMU case, so make sure we
    don't have any references to clear_refs_smap() in generic procfs code.

    Signed-off-by: David Rientjes
    Signed-off-by: David Howells
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Rientjes
     
  • This is to fix unnecessary __meminit definition. These are exported for
    kernel modules.

    I compiled on ia64/x86-64 with memory hotplug on/off.

    Signed-off-by: Yasunori Goto
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Yasunori Goto
     
  • * master.kernel.org:/pub/scm/linux/kernel/git/herbert/crypto-2.6:
    [CRYPTO] cryptomgr: Fix use after free

    Linus Torvalds
     
  • * master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6:
    [SPARC64]: Optimize fault kprobe handling just like powerpc.
    [SPARC]: Wire up utimensat syscall.
    [SPARC64]: Fix request_irq() ignored result warnings in PCI controller code.
    [SPARC64]: Kill asm-sparc64/pbm.h
    [ATYFB]: Fix sparc includes.
    [QLA2XXX]: Fix build on sparc.
    [SPARC64]: Removal of trivial pci_controller_info uses.
    [SPARC64]: Move index info pci_pbm_info.
    [SPARC64]: Move {setup,teardown}_msi_irq into pci_pbm_info.
    [SPARC64]: Move pci_ops into pci_pbm_info.
    [SPARC64] SBUS: Error interrupt registry cleanups.
    [SPARC64] PCI: Use root list of pbm's instead of pci_controller_info's
    [SPARC64] PCI: Kill PROM_PCIRNG_MAX and PROM_PCIIMAP_MAX.
    [SPARC64] PCI: Use common routine to fetch PBM properties.

    Linus Torvalds
     
  • * master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6: (58 commits)
    [SCSI] zfcp: clear boxed flag on unit reopen.
    [SCSI] zfcp: clear adapter failed flag if an fsf request times out.
    [SCSI] zfcp: rework request ID management.
    [SCSI] zfcp: Fix deadlock between zfcp ERP and SCSI
    [SCSI] zfcp: Locking for req_no and req_seq_no
    [SCSI] zfcp: print S_ID and D_ID with 3 bytes
    [SCSI] ipr: Use PCI-E reset API for new ipr adapter
    [SCSI] qla2xxx: Update version number to 8.01.07-k7.
    [SCSI] qla2xxx: Add MSI support.
    [SCSI] qla2xxx: Correct pci_set_msi() usage semantics.
    [SCSI] qla2xxx: Attempt to stop firmware only if it had been previously executed.
    [SCSI] qla2xxx: Honor NVRAM port-down-retry-count settings.
    [SCSI] qla2xxx: Error-out during probe() if we're unable to complete HBA initialization.
    [SCSI] zfcp: Stop system after memory corruption
    [SCSI] mesh: cleanup variable usage in interrupt handler
    [SCSI] megaraid: replace yield() with cond_resched()
    [SCSI] megaraid: fix warnings when CONFIG_PROC_FS=n
    [SCSI] aacraid: correct SUN products to README
    [SCSI] aacraid: superfluous adapter reset for IBM 8 series ServeRAID controllers
    [SCSI] aacraid: kexec fix (reset interrupt handler)
    ...

    Linus Torvalds
     
  • This reverts commit 464bdd33e9baad9806c7adbd8dfc37081a55f27e.

    Peter Anvin correctly points out that VESA modes have nothing to do with
    frame buffers per se - they are often just regular extended text modes.
    Disabling them just because we don't have frame buffer support is very
    wrong.

    Cc: H. Peter Anvin
    Cc: Antonino A. Daplas ,
    Cc: Andrew Morton
    Signed-off-by: Linus Torvalds

    Linus Torvalds
     
  • .. to match what we do on write(). This way, people who write to files
    by using [f]truncate + writable mmap have the same semantics as if they
    were using the write() family of system calls.

    Signed-off-by: Linus Torvalds

    Linus Torvalds
     
  • By the time kthread_run returns the param may have already been freed
    so writing the returned thread_struct pointer to param is wrong.

    In fact, we don't need it in param anyway so this patch simply puts it
    on the stack.

    Signed-off-by: Herbert Xu

    Herbert Xu
     
  • And eliminate DIE_GPF while we're at it.

    Signed-off-by: David S. Miller

    David S. Miller
     
  • Signed-off-by: David S. Miller

    David S. Miller
     
  • Signed-off-by: David S. Miller

    David S. Miller
     
  • Everything it contains can be hidden in pci_impl.h

    Signed-off-by: David S. Miller

    David S. Miller