15 Apr, 2006

1 commit

  • The init function for the RPA PCI Hotplug driver returns -ENODEV in the
    case that no hotplug-capable slots are detected in the system. This is
    bad, since hot-capable slots can be added after boot to a purely virtual
    POWER partition. This is also bad because DLPAR I/O operations depend
    on the rpaphp module.

    Change the rpaphp init module to return success for the case of
    partitions that own no hotplug-capable slots at boot. Such slots can be
    dynamically added after boot.

    Signed-off-by: John Rose
    Signed-off-by: Greg Kroah-Hartman

    John Rose
     

27 Mar, 2006

1 commit

  • Semaphore to mutex conversion.

    The conversion was generated via scripts, and the result was validated
    automatically via a script as well.

    Signed-off-by: Ingo Molnar
    Cc: Dave Jones
    Cc: Paul Mackerras
    Cc: Ralf Baechle
    Cc: Jens Axboe
    Cc: Neil Brown
    Acked-by: Alasdair G Kergon
    Cc: Greg KH
    Cc: Dominik Brodowski
    Cc: Adam Belay
    Cc: Martin Schwidefsky
    Cc: "David S. Miller"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ingo Molnar
     

24 Mar, 2006

29 commits

  • I encountered the problem that the insmod of the acpiphp
    fails because of the mis-freeing of the memory.

    I tested this patch on my tiger4 box.

    Signed-off-by: MUNEDA Takahiro
    Signed-off-by: Greg Kroah-Hartman

    MUNEDA Takahiro
     
  • This patch removes the defines TRUE and FALSE and just uses 0 or 1.

    Signed-off-by: Kristen Carlson Accardi
    Signed-off-by: Greg Kroah-Hartman

    Kristen Accardi
     
  • shpchprm_acpi.c and pciehprm_acpi.c are nearly identical. In addition,
    there are functions in both these files that are also in acpiphp_glue.c.
    This patch will remove duplicate functions from shpchp, pciehp, and
    acpiphp and move this functionality to pci_hotplug, as it is not
    hardware specific. Get rid of shpchprm* and pciehprm* files since they
    are no longer needed. shpchprm_nonacpi.c and pciehprm_nonacpi.c are
    identical, as well as shpchprm_legacy.c and can be replaced with a
    macro.

    This patch also changes acpiphp to use the common hpp code.

    Signed-off-by: Kristen Carlson Accardi
    Signed-off-by: Greg Kroah-Hartman

    Kristen Accardi
     
  • this patch converts drivers/pci to kzalloc usage.
    Compile tested with allyes config.

    Signed-off-by: Eric Sesterhenn
    Signed-off-by: Greg Kroah-Hartman

    Eric Sesterhenn
     
  • Current ACPIPHP driver scans only slots under the top level PCI-to-PCI
    bridge. So hotplug PCI slots under the nested PCI-to-PCI bridge would
    not be detected. For example, if the system has the ACPI namespace
    like below, hotplug slots woule not be detected.

    Device (PCI0) { /* Root bridge */
    Name (_HID, "PNP0A03")
    Device (P2PA) { /* PCI-to-PCI bridge */
    Name (_ADR, ...)
    Device (P2PB) { /* PCI-to-PCI bridge */
    Name (_ADR, ...)
    Device (S0F0) { /* hotplug slot */
    Name (_ADR, ...)
    Name (_SUN, ...)
    Method (_EJ0, ...) { ... }
    }
    ...
    Device (S0F7) { /* hotplug slot */
    Name (_ADR, ...)
    Name (_SUN, ...)
    Method (_EJ0, ...) { ... }
    }
    Device (S1F0) { /* hotplug slot */
    Name (_ADR, ...)
    Name (_SUN, ...)
    Method (_EJ0, ...) { ... }
    }
    ...
    }
    }
    }

    This patch fixes this issue.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • When doing a hotplug removal of a PPB, sn_bus_store_sysdata()
    needs to be called for the PPB and all of its children.

    Acked-by: Prarit Bhargava
    Signed-off-by: John Keller
    Signed-off-by: Greg Kroah-Hartman

    John Keller
     
  • The code related to handling bus speed in SHPCHP driver is
    unnecessarily complex. This patch cleans up and simplify that.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • The Coverity checker correctly noted, that in function board_replaced in
    drivers/pci/hotplug/cpqphp_ctrl.c, the variable src always has the
    value 8, and therefore much code after the

    ...
    if (rc || src) {
    ...
    if (rc)
    return rc;
    else
    return 1;
    }
    ...

    can never be called.

    This patch removes the unreachable code in this function fixing kernel
    Bugzilla #6073.

    Signed-off-by: Adrian Bunk
    Signed-off-by: Greg Kroah-Hartman

    Adrian Bunk
     
  • When hotplug slot is under the host bridge,
    DEVICE_ACPI_HANDLE(&bus->self->dev) fails since '&bus->self' was not set.
    This patch fixes it.

    This patch is based on kristen's latest patches.
    I tested this patch on my Tiger4.

    Signed-off-by: MUNEDA Takahiro
    Signed-off-by: Greg Kroah-Hartman

    MUNEDA Takahiro
     
  • o This patch removes IDs (for slots management).
    o This patch removes the slot register/unregister processes
    from the init/exit phases. Instead, adds these processes
    in the bridge add/cleanup phases.
    o Currently, this change doesn't have any meanings. But
    these changes are needed to support p2p bridge(with
    hotplug slot)

    Signed-off-by: MUNEDA Takahiro
    Signed-off-by: Kristen Carlson Accardi
    Signed-off-by: Greg Kroah-Hartman

    MUNEDA Takahiro
     
  • These patches add generic dock event handling to acpiphp. If there are
    pci devices that need to be inserted/removed after the dock event, the
    event notification will be handed down to the normal pci hotplug event
    handler in acpiphp so that new bridges/devices can be enumerated.

    Because some dock stations do not have pci bridges or pci devices that
    need to be inserted after a dock, acpiphp will remain loaded to handle
    dock events even if no hotpluggable pci slots are discovered.

    You probably need to have the pci=assign-busses kernel parameter enabled
    to use these patches, and you may not allow ibm_acpi to handle docking
    notifications and use this patch.

    This patch incorporates feedback provided by many.

    Signed-off-by: Kristen Carlson Accardi
    Signed-off-by: Greg Kroah-Hartman

    Kristen Accardi
     
  • If we add a new bridge with subordinate busses, we should call make sure
    that acpi is notified so that the PRT (if present) can be read and drivers
    who have registered on this bus will be notified when it is started.
    Also make sure to use the max reserved bus number for the starting the bus
    scan.

    Signed-off-by: Kristen Carlson Accardi
    Signed-off-by: Greg Kroah-Hartman

    Kristen Accardi
     
  • This patch adapts SHPCHP driver to the PCI device driver model.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Kristen Carlson Accardi
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • Current SHPCHP driver doesn't care about the confliction between
    hotplug operation via sysfs and hotplug operation via attention
    button. So if those ware conflicted, slot could be an unexpected
    state.

    This patch changes SHPCHP driver to handle slot state properly. With
    this patch, slot events are handled according to the current slot
    state as shown at the Table below.

    Table. Slot States and Event Handling
    =========================================================================
    Slot State Event and Action
    =========================================================================
    STATIC - Go to POWERON state if user initiates
    (Slot enabled, insertion request via sysfs
    Slot disabled) - Go to POWEROFF state if user initiates removal
    request via sysfs
    - Go to BLINKINGON state if user presses
    attention button when the slot is disabled
    - Go to BLINKINGOFF state if user presses
    attention button when the slot is enabled

    Kenji Kaneshige
     
  • The event handler of SHPCHP driver is unnecessarily very complex. In
    addition, current event handler can only a fixed number of events at
    the same time, and some of events would be lost if several number of
    events happened at the same time.

    This patch simplify the event handler by using 'work queue', and it
    also fix the above-mentioned issue.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Kristen Carlson Accardi
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • The wait_for_ctrl_irq() function in SHPCHP driver is no longer needed.
    This patch removes that. This patch has no functional change.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Kristen Carlson Accardi
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • This patch removes unused 'pci_bus' member from controller structure.
    This patch have no functional change.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Kristen Carlson Accardi
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • Current SHPCHP driver has a bug in its interrupt handler which cause
    "IRQ #: nobody cared" oops. This problem can be reproduced easily by
    the following operation.

    # cd /sys/bus/pci/slots/
    # while true; do echo 1 > attention ; done &

    The reason is that when command complete interrupt is raised, current
    SHPCHP driver's interrupt handler returns IRQ_NONE regardless of if
    the interrupt is handled or not.

    This patch fixes this issue.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • This patch moves slot name area into struct slot.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • This patch removes unnecessary 'magic' member from struct slot of
    SHPCHP driver.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • This patch replaces kmalloc() and memset() pair with kzalloc() and
    cleans up the arg of sizeof() in SHPCHP driver.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • This patch cleans up pcihp_skelton.c as follows.

    o Move slot name area into struct slot.
    o Replace kmalloc with kzalloc and clean up the arg of sizeof()
    o Fix the wrong use of get_*_status() functions.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • Current shpchp driver might cause system panic because of lack of
    serialization. It can be reproduced very easily by the following
    operation.

    # cd /sys/bus/pci/slots/
    # while true; do echo 0 > power ; echo 1 > power ; done &
    # while true; do echo 0 > power ; echo 1 > power ; done &

    This patch fixes this issue by changing shpchp to get appropreate
    semaphore for hot-plug operation.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • This patch cleanups codes that check the command status. For this, it
    introduces a new semaphore "cmd_sem" for each controller.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • This patch changes SHPCHP driver to use list_head structure for
    managing controller list.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • This patch changes SHPCHP driver to use list_head structure for
    managing slot list.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • This patch cleanups some codes in shpchp_core.c. This patch has no
    functional changes.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • This patch cleanups init_slots() function of SHPCHP driver based on
    pcihp_skelton.c. This patch has no functional change.

    Signed-off-by: Kenji Kaneshige
    Signed-off-by: Greg Kroah-Hartman

    Kenji Kaneshige
     
  • semaphore to mutex conversion.

    the conversion was generated via scripts, and the result was validated
    automatically via a script as well.

    build tested with allyesconfig.

    Signed-off-by: Ingo Molnar
    Signed-off-by: Greg Kroah-Hartman

    Ingo Molnar
     

02 Feb, 2006

1 commit

  • Build break: Building PCI hotplug on PowerPC results in
    a build break, due to failure to export symbols.

    Reported today by Dave Jones :
    drivers/pci/hotplug/rpaphp.ko needs unknown symbol pcibios_add_pci_devices

    This patch fixes same problem in drivers/pci tree
    Previous patch fixes the break in the arch/powerpc tree.

    Signed-off-by: Linas Vepstas
    Signed-off-by: Linus Torvalds

    Linas Vepstas
     

01 Feb, 2006

8 commits