1. 11 1月, 2011 1 次提交
  2. 05 11月, 2009 1 次提交
    • B
      PCI hotplug: move IOAPIC support from acpiphp to ioapic driver · 204d49a5
      Bjorn Helgaas 提交于
      This patch moves PCI I/O APIC support from acpiphp to a separate driver.
      
      Like pciehp and shpchp, acpiphp handles PCI hotplug, i.e., addition and
      removal of PCI adapters.  But in addition, acpiphp handles some ACPI
      hotplug, such as the addition of new host bridges, and the I/O APIC
      support was tangled up with that.
      
      I don't think the I/O APIC support needs to be in acpiphp; PCI I/O APICs
      usually appear as a function on a PCI host bridge, and we'll enumerate the
      APIC before any of the devices behind the bridge that use it.
      
      As far as I know, nobody actually uses I/O APIC hotplug.  It depends on
      acpi_register_ioapic(), which is only implemented for ia64, and I don't
      think any vendors have supported I/O chassis hotplug yet.
      Signed-off-by: NBjorn Helgaas <bjorn.helgaas@hp.com>
      Reviewed-by: NKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
      CC: Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com>
      CC: MUNEDA Takahiro <muneda.takahiro@jp.fujitsu.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      204d49a5
  3. 15 9月, 2009 1 次提交
  4. 27 5月, 2009 1 次提交
    • A
      PCI Hotplug: acpiphp: don't store a pci_dev in acpiphp_func · 9d911d79
      Alex Chiang 提交于
      An oops can occur if a user attempts to use both PCI logical
      hotplug and the ACPI physical hotplug driver (acpiphp) in this
      sequence, where $slot/address == $device.
      
      In other words, if acpiphp has claimed a PCI device, and that
      device is logically removed, then acpiphp may oops when it
      attempts to access it again.
      
      	# echo 1 > /sys/bus/pci/devices/$device/remove
      	# echo 0 > /sys/bus/pci/slots/$slot/power
      
      Unable to handle kernel NULL pointer dereference (address 0000000000000000)
      Call Trace:
       [<a000000100016390>] show_stack+0x50/0xa0
       [<a000000100016c60>] show_regs+0x820/0x860
       [<a00000010003b390>] die+0x190/0x2a0
       [<a000000100066a40>] ia64_do_page_fault+0x8e0/0xa40
       [<a00000010000c7a0>] ia64_native_leave_kernel+0x0/0x270
       [<a0000001003b2660>] pci_remove_bus_device+0x120/0x260
       [<a0000002060549f0>] acpiphp_disable_slot+0x410/0x540 [acpiphp]
       [<a0000002060505c0>] disable_slot+0xc0/0x120 [acpiphp]
       [<a0000002040d21c0>] power_write_file+0x1e0/0x2a0 [pci_hotplug]
       [<a0000001003bb820>] pci_slot_attr_store+0x60/0xa0
       [<a000000100240f70>] sysfs_write_file+0x230/0x2c0
       [<a000000100195750>] vfs_write+0x190/0x2e0
       [<a0000001001961a0>] sys_write+0x80/0x100
       [<a00000010000c600>] ia64_ret_from_syscall+0x0/0x20
       [<a000000000010720>] __kernel_syscall_via_break+0x0/0x20
      
      The root cause of this oops is that the logical remove ("echo 1 >
      /sys/bus/pci/devices/$device/remove") destroyed the pci_dev. The
      pci_dev struct itself wasn't deallocated because acpiphp kept a
      reference, but some of its fields became invalid.
      
      acpiphp doesn't have any real reason to keep a pointer to a
      pci_dev around. It can always derive it using pci_get_slot().
      
      If a logical remove destroys the pci_dev, acpiphp won't find it
      and is thus prevented from causing mischief.
      Reviewed-by: NMatthew Wilcox <willy@linux.intel.com>
      Reviewed-by: NKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
      Tested-by: NKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
      Reported-by: NKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
      Acked-by: NBjorn Helgaas <bjorn.helgaas@hp.com>
      Signed-off-by: NAlex Chiang <achiang@hp.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      9d911d79
  5. 08 1月, 2009 1 次提交
  6. 17 12月, 2008 1 次提交
  7. 23 10月, 2008 1 次提交
  8. 22 7月, 2008 1 次提交
  9. 11 6月, 2008 1 次提交
    • A
      PCI: introduce pci_slot · f46753c5
      Alex Chiang 提交于
      Currently, /sys/bus/pci/slots/ only exposes hotplug attributes when a
      hotplug driver is loaded, but PCI slots have attributes such as address,
      speed, width, etc.  that are not related to hotplug at all.
      
      Introduce pci_slot as the primary data structure and kobject model.
      Hotplug attributes described in hotplug_slot become a secondary
      structure associated with the pci_slot.
      
      This patch only creates the infrastructure that allows the separation of
      PCI slot attributes and hotplug attributes.  In this patch, the PCI
      hotplug core remains the only user of this infrastructure, and thus,
      /sys/bus/pci/slots/ will still only become populated when a hotplug
      driver is loaded.
      
      A later patch in this series will add a second user of this new
      infrastructure and demonstrate splitting the task of exposing pci_slot
      attributes from hotplug_slot attributes.
      
        - Make pci_slot the primary sysfs entity. hotplug_slot becomes a
          subsidiary structure.
          o pci_create_slot() creates and registers a slot with the PCI core
          o pci_slot_add_hotplug() gives it hotplug capability
      
        - Change the prototype of pci_hp_register() to take the bus and
          slot number (on parent bus) as parameters.
      
        - Remove all the ->get_address methods since this functionality is
          now handled by pci_slot directly.
      
      [achiang@hp.com: rpaphp-correctly-pci_hp_register-for-empty-pci-slots]
      Tested-by: NBadari Pulavarty <pbadari@us.ibm.com>
      Acked-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      [akpm@linux-foundation.org: build fix]
      [akpm@linux-foundation.org: make headers_check happy]
      [akpm@linux-foundation.org: nuther build fix]
      [akpm@linux-foundation.org: fix typo in #include]
      Signed-off-by: NAlex Chiang <achiang@hp.com>
      Signed-off-by: NMatthew Wilcox <matthew@wil.cx>
      Cc: Greg KH <greg@kroah.com>
      Cc: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
      Cc: Len Brown <lenb@kernel.org>
      Acked-by: NKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      f46753c5
  10. 02 2月, 2008 1 次提交
  11. 29 11月, 2007 1 次提交
    • R
      pci hotplug: kernel-doc fixes · 26e6c66e
      Randy Dunlap 提交于
      acpiphp.h: not using kernel-doc, so change /** to /*
      acpiphp_core.c: lots of kernel-doc cleanups
      acpiphp_glue.c: lots of kernel-doc cleanups
      acpiphp_ibm.c: lots of kernel-doc cleanups
      cpqphp_core.c: lots of kernel-doc cleanups
      cpqphp_ctrl.c: lots of kernel-doc cleanups
      fakephp.c:  correct kernel-doc notation
      pciehp_ctrl.c: correct kernel-doc notation
      rpadlpar_core.c: correct function names & kernel-doc notation
      rpaphp_core.c: correct kernel-doc notation
      shpchp_ctrl.c: correct kernel-doc notation
      Signed-off-by: NRandy Dunlap <randy.dunlap@oracle.com>
      Cc: Kristen Accardi <kristen.c.accardi@intel.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      26e6c66e
  12. 12 7月, 2007 1 次提交
  13. 02 12月, 2006 1 次提交
    • R
      PCI: Change memory allocation for acpiphp slots · ac9e9891
      Rolf Eike Beer 提交于
      Change memory allocation for acpiphp slots
      
      Change the "struct slot" that acpiphp uses for managing it's slots to
      directly contain the memory for the needed struct hotplug_slot_info and
      the slot's name. This way we need only two memory allocations per slot
      instead of four.
      
      While we are at it: make_slot_name() is just a wrapper around snprintf()
      knowing the right arguments to call it. Since the function makes just one
      function call and is only called from one place I inlined it by hand.
      
      Finally this fixes a possible bug waiting for someone to hit it. There were
      two unused local variables in acpiphp_register_hotplug_slot(). gcc did not
      find them because they were used in memory allocations with sizeof(*var).
      They had the same types as the target of the allocation, but nevertheless
      this was just weird.
      Signed-off-by: NRolf Eike Beer <eike-hotplug@sf-tec.de>
      Acked-by: NMatthew Wilcox <matthew@wil.cx>
      Signed-off-by: NKristen Carlson Accardi <kristen.c.accardi@intel.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      
      ac9e9891
  14. 19 10月, 2006 1 次提交
  15. 27 9月, 2006 1 次提交
  16. 28 6月, 2006 2 次提交
  17. 20 6月, 2006 1 次提交
    • M
      [PATCH] acpiphp: hotplug slot hotplug · 551bcb75
      MUNEDA Takahiro 提交于
      o hotplug slots add
        When the hot-added PCI device is p2p bridge, acpiphp calls
        find_p2p_bridge() to add hotplug slots.
      
      o hotplug slots remove
        When the hot-removing PCI device is p2p bridge, acpiphp
        calls cleanup_p2p_bridge() to remove hotplug slots.
      
      o notify handler exchange
        When the p2p bridge is added, acpiphp changes the notify
        hanlder.
        If no bridge device is inserted into the hotpluggable PCI
        slot, acpiphp installs the notify handler for function.
        After the p2p bridge hot-add, acpiphp has to install the
        notify handler for bridge. Because, the role of the
        handlers are not same. The hot-remove case is ditto.
      Signed-off-by: NMUNEDA Takahiro <muneda.takahiro@jp.fujitsu.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      551bcb75
  18. 24 3月, 2006 4 次提交
  19. 28 6月, 2005 1 次提交
  20. 17 4月, 2005 1 次提交
    • L
      Linux-2.6.12-rc2 · 1da177e4
      Linus Torvalds 提交于
      Initial git repository build. I'm not bothering with the full history,
      even though we have it. We can create a separate "historical" git
      archive of that later if we want to, and in the meantime it's about
      3.2GB when imported into git - space that would just make the early
      git days unnecessarily complicated, when we don't have a lot of good
      infrastructure for it.
      
      Let it rip!
      1da177e4