29 Jun, 2009

5 commits

  • * git://git.infradead.org/iommu-2.6:
    intel-iommu: fix Identity Mapping to be arch independent

    Linus Torvalds
     
  • …git/tip/linux-2.6-tip

    * 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
    x86, delay: tsc based udelay should have rdtsc_barrier
    x86, setup: correct include file in <asm/boot.h>
    x86, setup: Fix typo "CONFIG_x86_64" in <asm/boot.h>
    x86, mce: percpu mcheck_timer should be pinned
    x86: Add sysctl to allow panic on IOCK NMI error
    x86: Fix uv bau sending buffer initialization
    x86, mce: Fix mce resume on 32bit
    x86: Move init_gbpages() to setup_arch()
    x86: ensure percpu lpage doesn't consume too much vmalloc space
    x86: implement percpu_alloc kernel parameter
    x86: fix pageattr handling for lpage percpu allocator and re-enable it
    x86: reorganize cpa_process_alias()
    x86: prepare setup_pcpu_lpage() for pageattr fix
    x86: rename remap percpu first chunk allocator to lpage
    x86: fix duplicate free in setup_pcpu_remap() failure path
    percpu: fix too lazy vunmap cache flushing
    x86: Set cpu_llc_id on AMD CPUs

    Linus Torvalds
     
  • …el/git/tip/linux-2.6-tip

    * 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
    timer stats: Optimize by adding quick check to avoid function calls
    timers: Fix timer_migration interface which accepts any number as input

    Linus Torvalds
     
  • …nel/git/tip/linux-2.6-tip

    * 'tracing-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
    ftrace: Fix the output of profile
    ring-buffer: Make it generally available
    ftrace: Remove duplicate newline
    tracing: Fix trace_buf_size boot option
    ftrace: Fix t_hash_start()
    ftrace: Don't manipulate @pos in t_start()
    ftrace: Don't increment @pos in g_start()
    tracing: Reset iterator in t_start()
    trace_stat: Don't increment @pos in seq start()
    tracing_bprintk: Don't increment @pos in t_start()
    tracing/events: Don't increment @pos in s_start()

    Linus Torvalds
     
  • * 'for-linus' of git://git.o-hand.com/linux-rpurdie-leds:
    leds: Futher document blink_set
    leds: Add options to have GPIO LEDs start on or keep their state
    leds: LED driver for National Semiconductor LP3944 Funlight Chip
    leds: pca9532 - Indent using tabs, not spaces.
    leds: Remove an orphan Kconfig entry
    leds: Further document parameters for blink_set()
    leds: alix-leds2 fixed for Award BIOS
    leds: leds-gpio - fix a section mismatch
    leds: add the sysfs interface into the leds-bd2802 driver for changing wave pattern and led current.
    leds: change the license information
    leds: fix led-bd2802 errors while resuming

    Linus Torvalds
     

27 Jun, 2009

4 commits

  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/bp/bp:
    amd64_edac: misc small cleanups
    amd64_edac: fix ecc_enable_override handling
    amd64_edac: check only ECC bit in amd64_determine_edac_cap

    Linus Torvalds
     
  • * 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc: (29 commits)
    powerpc/rtas: Fix watchdog driver temperature read functionality
    powerpc/mm: Fix potential access to freed pages when using hugetlbfs
    powerpc/440: Fix warning early debug code
    powerpc/of: Fix usage of dev_set_name() in of_device_alloc()
    powerpc/pasemi: Use raw spinlock in SMP TB sync
    powerpc: Use one common impl. of RTAS timebase sync and use raw spinlock
    powerpc/rtas: Turn rtas lock into a raw spinlock
    powerpc: Add irqtrace support for 32-bit powerpc
    powerpc/BSR: Fix BSR to allow mmap of small BSR on 64k kernel
    powerpc/BSR: add 4096 byte BSR size
    powerpc: Map more memory early on 601 processors
    powerpc/pmac: Fix DMA ops for MacIO devices
    powerpc/mm: Make k(un)map_atomic out of line
    powerpc: Fix mpic alloc warning
    powerpc: Fix output from show_regs
    powerpc/pmac: Fix issues with PowerMac "PowerSurge" SMP
    powerpc/amigaone: Limit ISA I/O range to 4k in the device tree
    powerpc/warp: Platform fix for i2c change
    powerpc: Have git ignore generated files from dtc compile
    powerpc/mpic: Fix mapping of "DCR" based MPIC variants
    ...

    Linus Torvalds
     
  • * 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6:
    ACPI: video: prevent NULL deref in acpi_get_pci_dev()
    eeepc-laptop: add rfkill support for the 3G modem in Eee PC 901 Go
    eeepc-laptop: get the right value for CMSG
    eeepc-laptop: makes get_acpi() returns -ENODEV
    eeepc-laptop: right parent device
    eeepc-laptop: rfkill refactoring
    eeepc-laptop.c: use pr_fmt and pr_
    eeepc-laptop: Register as a pci-hotplug device

    Linus Torvalds
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6:
    [CIFS] remove unknown mount option warning message
    [CIFS] remove bkl usage from umount begin
    cifs: Fix incorrect return code being printed in cFYI messages
    [CIFS] cleanup asn handling for ntlmssp
    [CIFS] Copy struct *after* setting the port, instead of before.
    cifs: remove rw/ro options
    cifs: fix problems with earlier patches
    cifs: have cifs parse scope_id out of IPv6 addresses and use it
    [CIFS] Do not send tree disconnect if session is already disconnected
    [CIFS] Fix build break
    cifs: display scopeid in /proc/mounts
    cifs: add new routine for converting AF_INET and AF_INET6 addrs
    cifs: have cifs_show_options show forceuid/forcegid options
    cifs: remove unneeded NULL checks from cifs_show_options

    Linus Torvalds
     

26 Jun, 2009

31 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6:
    sparc32: Fix makefile not generating required files
    sparc32: Fix tftpboot.img Makefile
    sparc: fix tftpboot.img build
    sparc32: Fix obvious build issues for tftpboot.img build.
    sparc64: Fix build warnings in piggyback_64.c
    sparc64: Don't use alloc_bootmem() in init_IRQ() code paths.

    Linus Torvalds
     
  • - cleanup debug calls
    - shorten function names
    - cleanup error exit paths

    Signed-off-by: Borislav Petkov

    Borislav Petkov
     
  • amd64_check_ecc_enabled() returns non-zero status when ECC
    checking/correcting is disabled and this fails further loading of the
    driver even when 'ecc_enable_override' boot param is used.

    Fix that by clearing return status in that case.

    Signed-off-by: Borislav Petkov

    Borislav Petkov
     
  • Checking whether the machine is using ECC enabled DRAM is done through
    testing the DimmEccEn bit in the DRAM Cfg Low register (F2x[1,0]90). Do
    that instead of testing all bits from the DimmEccEn upwards.

    Also, remove mci->edac_cap assignment and use value returned from
    amd64_determine_edac_cap().

    Signed-off-by: Borislav Petkov

    Borislav Petkov
     
  • Drop the e820 scanning and use existing function for finding valid
    RAM regions to add to 1:1 mapping.

    Signed-off-by: Chris Wright
    Signed-off-by: David Woodhouse

    Chris Wright
     
  • The first entry of the ftrace profile was always skipped when
    reading trace_stat/functionX.

    Signed-off-by: Li Zefan
    Cc: Steven Rostedt
    Cc: Frederic Weisbecker
    LKML-Reference:
    Signed-off-by: Ingo Molnar

    Li Zefan
     
  • Benjamin Herrenschmidt
     
  • Using the RTAS watchdog driver to read out the temperature crashes
    on a PXCAB:

    Unable to handle kernel paging request for data at address 0xfe347b50
    Faulting instruction address: 0xc00000000001af64
    Oops: Kernel access of bad area, sig: 11 [#1]

    The wrong usage of "(void *)__pa(&temperature)" in rtas_call() is
    removed by using the function rtas_get_sensor() which does the
    right thing.

    Signed-off-by: Adrian Reber
    Acked-by: Utz Bacher
    Signed-off-by: Benjamin Herrenschmidt

    Adrian Reber
     
  • When using 64k page sizes, our PTE pages are split in two halves,
    the second half containing the "extension" used to keep track of
    individual 4k pages when not using HW 64k pages.

    However, our page tables used for hugetlb have a slightly different
    format and don't carry that "second half".

    Our code that batched PTEs to be invalidated unconditionally reads
    the "second half" (to put it into the batch), which means that when
    called to invalidate hugetlb PTEs, it will access unrelated memory.

    It breaks when CONFIG_DEBUG_PAGEALLOC is enabled.

    This fixes it by only accessing the second half when the _PAGE_COMBO
    bit is set in the first half, which indicates that we are dealing with
    a "combo" page which represents 16x4k subpages. Anything else shouldn't
    have this bit set and thus not require loading from the second half.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • The function udbg_44x_as1_flush() has the wrong prototype causing
    a warning when enabling 440 early debug.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • dev_set_name() takes a format string, so use it properly and avoid
    a warning with recent gcc's

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • spin_lock() can hang if called while the timebase is frozen,
    so use a raw lock instead, also disable interrupts while
    at it.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • Several platforms use their own copy of what is essentially the same code,
    using RTAS to synchronize the timebases when bringing up new CPUs. This
    moves it all into a single common implementation and additionally
    turns the spinlock into a raw spinlock since the former can rely on
    the timebase not being frozen when spinlock debugging is enabled, and finally
    masks interrupts while the timebase is disabled.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • RTAS currently uses a normal spinlock. However it can be called from
    contexts where this is not necessarily a good idea. For example, it
    can be called while syncing timebases, with the core timebase being
    frozen. Unfortunately, that will deadlock in case of lock contention
    when spinlock debugging is enabled as the spin lock debugging code
    will try to use __delay() which ... relies on the timebase being
    enabled.

    Also RTAS can be used in some low level IRQ handling code path so it
    may as well be a raw spinlock for -rt sake.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • Based on initial work from: Dale Farnsworth

    Add the low level irq tracing hooks for 32-bit powerpc needed
    to enable full lockdep functionality.

    The approach taken to deal with the code in entry_32.S is that
    we don't trace all the transitions of MSR:EE when we just turn
    it off to peek at TI_FLAGS without races. Only when we are
    calling into C code or returning from exceptions with a state
    that have changed from what lockdep thinks.

    There's a little bugger though: If we take an exception that
    keeps interrupts enabled (such as an alignment exception) while
    interrupts are enabled, we will call trace_hardirqs_on() on the
    way back spurriously. Not a big deal, but to get rid of it would
    require remembering in pt_regs that the exception was one of the
    type that kept interrupts enabled which we don't know at this
    stage. (Well, we could test all cases for regs->trap but that
    sucks too much).

    Signed-off-by: Benjamin Herrenschmidt
    Tested-by: Kumar Gala

    Benjamin Herrenschmidt
     
  • On Mon, Nov 17, 2008 at 01:26:13AM -0600, Sonny Rao wrote:
    > On Fri, Nov 07, 2008 at 04:28:29PM +1100, Paul Mackerras wrote:
    > > Sonny Rao writes:
    > >
    > > > Fix the BSR driver to allow small BSR devices, which are limited to a
    > > > single 4k space, on a 64k page kernel. Previously the driver would
    > > > reject the mmap since the size was smaller than PAGESIZE (or because
    > > > the size was greater than the size of the device). Now, we check for
    > > > this case use remap_4k_pfn(). Also, take out code to set vm_flags,
    > > > as the remap_pfn functions will do this for us.
    > >
    > > Thanks.
    > >
    > > Do we know that the BSR size will always be 4k if it's not a multiple
    > > of 64k? Is it possible that we could get 8k, 16k or 32k or BSRs?
    > > If it is possible, what does the user need to be able to do? Do they
    > > just want to map 4k, or might then want to map the whole thing?
    >
    >
    > Hi Paul, I took a look at changing the driver to reject a request for
    > mapping more than a single 4k page, however the only indication we get
    > of the requested size in the mmap function is the vma size, and this
    > is always one page at minimum. So, it's not possible to determine if
    > the user wants one 4k page or more. As I noted in my first response,
    > there is only one case where this is even possible and I don't think
    > it is a significant concern.
    >
    > I did notice that I left out the check to see if the user is trying to
    > map more than the device length, so I fixed that. Here's the revised
    > patch.

    Alright, I've reworked this now so that if we get one of these cases
    where there's a bsr that's > 4k and < 64k on a 64k kernel we'll only
    advertise that it is a 4k BSR to userspace. I think this is the best
    solution since user programs are only supposed to look at sysfs to
    determine how much can be mapped, and libbsr does this as well.

    Please consider for 2.6.31 as a fix, thanks.

    Signed-off-by: Benjamin Herrenschmidt

    Sonny Rao
     
  • Add a 4096 byte BSR size which will be used on new machines. Also, remove
    the warning when we run into an unknown size, as this can spam the kernel
    log excessively.

    Signed-off-by: Sonny Rao
    Signed-off-by: Benjamin Herrenschmidt

    Sonny Rao
     
  • The 32-bit kernel relies on some memory being mapped covering
    the kernel text,data and bss at least, early during boot before
    the full MMU setup is done. On 32-bit "classic" processors, this
    is done using BAT registers.

    On 601, the size of BATs is limited to 8M and we use 2 of them
    for that initial mapping. This can become quite tight when enabling
    features like lockdep, so let's use a 3rd one to bump that mapping
    from 16M to 24M. We keep the 4th BAT free as it can be useful for
    debugging early boot code to map things like serial ports.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • The macio_dev's created to map devices inside the MacIO ASICs
    don't have proper dma_ops. This causes crashes on some machines
    since the SCSI code calls dma_map_* on our behalf using the
    device we hang from.

    This fixes it by copying the parent PCI device dma_ops into
    the macio_dev when creating it.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • Those functions are way too big to be inline, besides, kmap_atomic()
    wants to call debug_kmap_atomic() which isn't exported for modules
    and causes module link failures.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • Since we can use kmalloc earlier we are getting the following since the
    mpic_alloc() code calls alloc_bootmem(). Move to using kzalloc() to
    remove the warning.

    ------------[ cut here ]------------
    Badness at c0583248 [verbose debug info unavailable]
    NIP: c0583248 LR: c0583210 CTR: 00000004
    REGS: c0741de0 TRAP: 0700 Not tainted (2.6.30-06736-g12a31df)
    MSR: 00021000 CR: 22024024 XER: 00000000
    TASK = c070d3b8[0] 'swapper' THREAD: c0740000 CPU: 0
    GPR00: 00000001 c0741e90 c070d3b8 00000001 00000210 00000020 3fffffff 00000000
    GPR08: 00000000 c0c85700 c04f8c40 0000002d 22044022 1004a388 7ffd9400 00000000
    GPR16: 00000000 7ffcd100 7ffcd100 7ffcd100 c04f8c40 00000000 c059f62c c075a0c0
    GPR24: c059f648 00000000 0000000f 00000210 00000020 00000000 3fffffff 00000210
    NIP [c0583248] alloc_arch_preferred_bootmem+0x50/0x80
    LR [c0583210] alloc_arch_preferred_bootmem+0x18/0x80
    Call Trace:
    [c0741e90] [c07343b0] devtree_lock+0x0/0x24 (unreliable)
    [c0741ea0] [c0583b14] ___alloc_bootmem_nopanic+0x54/0x108
    [c0741ee0] [c0583e18] ___alloc_bootmem+0x18/0x50
    [c0741ef0] [c057b9cc] mpic_alloc+0x48/0x710
    [c0741f40] [c057ecf4] mpc85xx_ds_pic_init+0x190/0x1b8
    [c0741f90] [c057633c] init_IRQ+0x24/0x34
    [c0741fa0] [c05738b8] start_kernel+0x260/0x3dc
    [c0741ff0] [c00003c8] skpinv+0x2e0/0x31c
    Instruction dump:
    409e001c 7c030378 80010014 83e1000c 38210010 7c0803a6 4e800020 3d20c0c8
    39295700 80090004 7c000034 5400d97e 2f800000 409e001c 38800000

    BenH: Changed to use GFP_KERNEL, the allocator will do the right thing

    Signed-off-by: Kumar Gala
    Signed-off-by: Benjamin Herrenschmidt

    Kumar Gala
     
  • For some reason we've had an explicit KERN_INFO for GPR dumps. With
    recent changes we get output like:

    GPR00: 00000000 ef855eb0 ef858000 00000001 000000d0 f1000000 ffbc8000 ffffffff

    The KERN_INFO is causing the . Don't see any reason to keep it
    around.

    Signed-off-by: Kumar Gala
    Signed-off-by: Benjamin Herrenschmidt

    Kumar Gala
     
  • The old PowerSurge SMP (ie, dual or quad 604 machines) code has
    numerous issues in modern world.

    One is cpu_possible_map is set too late (the device-tree is bogus)
    so we fail to allocate the interrupt stacks and crash. Another
    problem is the fact the timebase is frozen by the bringup of the
    second CPU so the delays in the generic code will hang, we need
    to move some of the calling procedure to inside the powermac code.

    This makes it boot again for me

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • The kernel reserves the I/O address space from 0x0 to 0xfff for legacy
    ISA devices. Change the ranges property for the PCI2ISA bridge to match
    the kernels behavior, even if the ranges property isn't used for now.

    Signed-off-by: Gerhard Pircher
    Signed-off-by: Benjamin Herrenschmidt

    Gerhard Pircher
     
  • A change to the i2c subsystem breaks the warp platform code. The patch
    is cleaner anyway, the old way was a bit crufty.

    For those with keen eyes, the gratuitous change in the string from
    PIKA to Warp is just so the logs look a bit nicer. The following two
    lines tend to be printed one after another.

    Warp POST OK
    Warp DTM thread running.

    Yeah, this will be the third patch to warp.c submitted in this
    release....

    Cheers,
    Sean

    The i2c_client struct changed, breaking the code that looked for the ad7414
    chip. Use the new of_find_i2c_device_by_node function added in 2.6.29.

    Signed-off-by: Sean MacLennan
    Signed-off-by: Benjamin Herrenschmidt

    Sean MacLennan
     
  • Have git ignore generated files from dtc compile

    Signed-off-by: Jon Smirl
    Acked-by: David Gibson
    Acked-by: Sean MacLennan
    Signed-off-by: Benjamin Herrenschmidt

    Jon Smirl
     
  • Commit 31207dab7d2e63795eb15823947bd2f7025b08e2
    "Fix incorrect allocation of interrupt rev-map"
    introduced a regression crashing on boot on machines using
    a "DCR" based MPIC, such as the Cell blades.

    The reason is that the irq host data structure is initialized
    much later as a result of that patch, causing our calls to
    mpic_map() do be done before we have a host setup.

    Unfortunately, this breaks _mpic_map_dcr() which uses the
    mpic->irqhost to get to the device node.

    This fixes it by, instead, passing the device node explicitely
    to mpic_map().

    Signed-off-by: Benjamin Herrenschmidt
    Acked-by: Akira Tsukamoto

    Benjamin Herrenschmidt
     
  • Turning on SWIOTLB selects or enables PPC_NEED_DMA_SYNC_OPS, which means
    we get the non empty versions of dma_sync_* in asm/dma-mapping.h

    On my pseries machine the dma_ops have no such routines and we die with
    a null pointer - this patch gets it booting, is there a more elegant way
    to do it?

    Signed-off-by: Michael Ellerman
    Signed-off-by: Benjamin Herrenschmidt

    Michael Ellerman
     
  • ref: http://thread.gmane.org/gmane.linux.kernel/857228/focus=857468

    When the ACPI video driver initializes, it does a namespace walk
    looking for for supported devices. When we find an appropriate
    handle, we walk up the ACPI tree looking for a PCI root bus, and
    then walk back down the PCI bus, assuming that every device
    inbetween is a P2P bridge.

    This assumption is not correct, and is reported broken on at
    least:

    Dell Latitude E6400
    ThinkPad X61
    Dell XPS M1330

    Add a NULL deref check to prevent boot panics.

    Reported-by: Alessandro Suardi
    Signed-off-by: Troy Moure
    Signed-off-by: Alex Chiang
    Signed-off-by: Len Brown

    Troy Moure
     
  • Signed-off-by: Janne Grunau
    Signed-off-by: Corentin Chary
    Signed-off-by: Len Brown

    Corentin Chary
     
  • CMSG is an ACPI method used to find features available on
    an Eee PC. But some features are never repported, even if present.

    If the getter of a feature is present, this patch will set
    the corresponding bit in cmsg.

    Signed-off-by: Corentin Chary
    Signed-off-by: Len Brown

    Corentin Chary