12 Oct, 2011

1 commit

  • Add:
    - Setup dts node for USB
    - pin description and setup for SMC1 (serial interface)

    Update and cleanup mgcoge_defconfig:
    - enable: TIPC, UBIFS, USB_GADGET driver, SQUASHFS, HIGHRES timers
    POSIX_MQUEUE, EMBEDDED
    - disable: EXT3, PPC_PMAC

    Signed-off-by: Holger Brunck
    Acked-by: Heiko Schocher
    cc: Kumar Gala
    Signed-off-by: Kumar Gala

    Holger Brunck
     

07 Oct, 2011

10 commits


29 Sep, 2011

4 commits

  • The firmware on old 970 blades supports some kind of takeover called
    "TNK takeover" which will crash if we try to probe for OPAL takeover,
    so don't do it.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • The current L1 cache read event code 0x80082 only counts for thread 0. The
    event code 0x280030 should be used to count events on thread 0 and 1. The
    patch fixes the event code for the L1 cache read.

    The current L1 cache write event code 0x80086 only counts for thread 0. The
    event code 0x180032 should be used to count events on thread 0 and 1. The
    patch fixes the event code for the L1 cache write.

    FYI, the documentation lists three event codes for the L1 cache read event
    and three event codes for the L1 cache write event. The event description
    for the event codes is as follows:

    L1 cache read requests 0x80082 LSU 0 only
    L1 cache read requests 0x8008A LSU 1 only
    L1 cache read requests 0x80030 LSU 1 or LSU 0, counter 2 only.

    L1 cache store requests 0x80086 LSU 0 only
    L1 cache store requests 0x8008E LSU 1 only
    L1 cache store requests 0x80032 LSU 0 or LSU 1, counter 1 only.

    There can only be one request from either LSU 0 or 1 active at a time.

    Signed-off-by: Carl Love
    Acked-by: Paul Mackerras
    Signed-off-by: Benjamin Herrenschmidt

    Carl E. Love
     
  • gcc (rightfully) complains that we are accessing beyond the
    end of the fpr array (we do, to access the fpscr).

    The only sane thing to do (whether anything in that code can be
    called remotely sane is debatable) is to special case fpscr and
    handle it as a separate statement.

    I initially tried to do it it by making the array access conditional
    to index < PT_FPSCR and using a 3rd else leg but for some reason gcc
    was unable to understand it and still spewed the warning.

    So I ended up with something a tad more intricated but it seems to
    build on 32-bit and on 64-bit with and without VSX.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • Based on patch by David Gibson

    xmon has a longstanding bug on systems which are SMP-capable but lack
    the MSR[RI] bit. In these cases, xmon invoked by IPI on secondary
    CPUs will not properly keep quiet, but will print stuff, thereby
    garbling the primary xmon's output. This patch fixes it, by ignoring
    the RI bit if the processor does not support it.

    There's already a version of this for 4xx upstream, which we'll need
    to extend to other RI-lacking CPUs at some point. For now this adds
    Book3e processors to the mix.

    Signed-off-by: Jimi Xenidis
    Signed-off-by: Benjamin Herrenschmidt

    Jimi Xenidis
     

26 Sep, 2011

1 commit


23 Sep, 2011

9 commits


20 Sep, 2011

15 commits

  • perf events, powerpc: Add POWER7 stalled-cycles-frontend/backend events

    Extent the POWER7 PMU driver with definitions for generic front-end and back-end
    stall events.

    As explained in Ingo's original comment(8f62242246351b5a4bc0c1f00c0c7003edea128a
    ), the exact definitions of the stall events are very much processor specific as

    different things mean different in their respective instruction pipeline. These
    two Power7 raw events are the closest approximation to the concept detailed in
    Ingo's comment.

    [PERF_COUNT_HW_STALLED_CYCLES_FRONTEND] = 0x100f8, /* GCT_NOSLOT_CYC */
    It means cycles when the Global Completion Table has no slots from this thread

    [PERF_COUNT_HW_STALLED_CYCLES_BACKEND] = 0x4000a, /* CMPLU_STALL */
    It means no groups completed and GCT not empty for this thread

    Signed-off-by: Anshuman Khandual
    Signed-off-by: Benjamin Herrenschmidt

    Anshuman Khandual
     
  • The firmware doesn't wait after lifting the PCI reset. However it does
    timestamp it in the device tree. We use that to ensure we wait long
    enough (3s is our current arbitrary setting) from that timestamp to
    actually probing the bus.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • This implements support for MSIs on p5ioc2 PHBs. We only support
    MSIs on the PCIe PHBs, not the PCI-X ones as the later hasn't been
    properly verified in HW.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • This adds support for PCI-X and PCIe on the p5ioc2 IO hub using
    OPAL. This includes allocating & setting up TCE tables and config
    space access routines.

    This also supports fallbacks via RTAS when OPAL is absent, using
    legacy TCE format pre-allocated via the device-tree (BML style)

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • OPAL can handle various interrupt for us such as Machine Checks (it
    performs all sorts of recovery tasks and passes back control to us with
    informations about the error), Hardware Management Interrupts and Softpatch
    interrupts.

    This wires up the mechanisms and prints out specific informations returned
    by HAL when a machine check occurs.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • We do the minimum which is to "pass" interrupts to HAL, which
    makes the console smoother and will allow us to implement
    interrupt based completion and console.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • OPAL handles HW access to the various ICS or equivalent chips
    for us (with the exception of p5ioc2 based HEA which uses a

    different backend) similarily to what RTAS does on pSeries.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • Implements OPAL RTC and NVRAM support and wire all that up to
    the powernv platform.

    We use RTAS for RTC as a fallback if available. Using RTAS for nvram
    is not supported yet, pending some rework/cleanup and generalization
    of the pSeries & CHRP code. We also use RTAS fallbacks for power off
    and reboot

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • This calls the respective HAL functions, and spin on hal_poll_event()
    to ensure the HAL has a chance to communicate with the FSP to trigger
    the reboot or shutdown operation

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • This adds a udbg and an hvc console backend for supporting a console
    using the OPAL console interfaces.

    On OPAL v1 we have hvc0 mapped to whatever console the system was
    configured for (network or hvsi serial port) via the service
    processor.

    On OPAL v2 we have hvcN mapped to the Nth console provided by OPAL
    which generally corresponds to:

    hvc0 : network console (raw protocol)
    hvc1 : serial port S1 (hvsi)
    hvc2 : serial port S2 (hvsi)

    Note: At this point, early debug console only works with OPAL v1
    and shouldn't be enabled in a normal kernel.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • OPAL v2 is instantiated in a way similar to RTAS using Open Firmware
    client interface calls, and the resulting address and entry point are
    put in the device-tree

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • Add definition of OPAL interfaces along with the wrappers to call
    into OPAL runtime and the early device-tree parsing hook to locate
    the OPAL runtime firmware.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • We stash it in boot_command_line which isn't in BSS and so won't
    be overwritten. We then use that as a default cmd_line before
    we walk the device-tree.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • On machines supporting the OPAL firmware version 1, the system
    is initially booted under pHyp. We then use a special hypercall
    to verify if OPAL is available and if it is, we then trigger
    a "takeover" which disables pHyp and loads the OPAL runtime
    firmware, giving control to the kernel in hypervisor mode.

    This patch add the necessary code to detect that the OPAL takeover
    capability is present when running under PowerVM (aka pHyp) and
    perform said takeover to get hypervisor control of the processor.

    To perform the takeover, we must first use RTAS (within Open
    Firmware runtime environment) to start all processors & threads,
    in order to give control to OPAL on all of them. We then call
    the takeover hypercall on everybody, OPAL will re-enter the kernel
    main entry point passing it a flat device-tree.

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt
     
  • Unplugged CPU go into NAP mode in a loop until woken up

    Signed-off-by: Benjamin Herrenschmidt

    Benjamin Herrenschmidt