1. 23 10月, 2008 3 次提交
  2. 21 10月, 2008 7 次提交
  3. 16 10月, 2008 1 次提交
  4. 27 9月, 2008 1 次提交
  5. 17 9月, 2008 1 次提交
  6. 08 8月, 2008 1 次提交
  7. 07 8月, 2008 1 次提交
    • A
      PCI: make pci_register_driver() a macro · bba81165
      Andrew Morton 提交于
      alpha:
      
      CC [M]  drivers/usb/gadget/u_ether.o
      In file included from include/asm/dma-mapping.h:7,
                       from include/linux/dma-mapping.h:52,
                       from include/linux/dmaengine.h:29,
                       from include/linux/skbuff.h:29,
                       from include/linux/if_ether.h:114,
                       from include/linux/etherdevice.h:27,
                       from drivers/usb/gadget/u_ether.c:29:
      include/linux/pci.h: In function 'pci_register_driver':
      include/linux/pci.h:673: error: 'KBUILD_MODNAME' undeclared (first use in this function)
      include/linux/pci.h:673: error: (Each undeclared identifier is reported only once
      include/linux/pci.h:673: error: for each function it appears in.)
      
      Sam says:
      
      The problem is that u_ether.o is used by two modules so when we build it
      KBUILD_MODNAME is not defined because kbuild does not know what value to
      use.
      
      And in pci.h we have the following inline:
      
      static inline int __must_check pci_register_driver(struct pci_driver *driver)
      {
              return __pci_register_driver(driver, THIS_MODULE, KBUILD_MODNAME);
      }
      
      And alpha uses dma-mapping.h to nullify a number of functions that seem to
      require something from pci.h.
      
      Making it a macro fixes this particular problem.  However, the underlying issue
      of a file using KBUILD_MODNAME and being shared between multiple modules is
      *not* addressed.  I guess the answer there is "don't do that".
      
      Cc: Sam Ravnborg <sam@ravnborg.org>
      Cc: Greg KH <greg@kroah.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      bba81165
  8. 29 7月, 2008 1 次提交
  9. 23 7月, 2008 1 次提交
  10. 08 7月, 2008 3 次提交
  11. 01 7月, 2008 1 次提交
  12. 28 6月, 2008 1 次提交
  13. 12 6月, 2008 1 次提交
  14. 11 6月, 2008 4 次提交
    • 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
    • R
      PCI: implement new suspend/resume callbacks · bbb44d9f
      Rafael J. Wysocki 提交于
      Implement new suspend and hibernation callbacks for the PCI bus type.
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Acked-by: NPavel Machek <pavel@ucw.cz>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      bbb44d9f
    • R
      Suspend/Resume bug in PCI layer wrt quirks · e1a2a51e
      Rafael J. Wysocki 提交于
      Some quirks should be called with interrupt disabled, we can't directly
      call them in .resume_early. Also the patch introduces
      pci_fixup_resume_early and pci_fixup_suspend, which matches current
      device core callbacks (.suspend/.resume_early).
      
      TBD: Somebody knows why we need quirk resume should double check if a
      quirk should be called in resume or resume_early. I changed some per my
      understanding, but can't make sure I fixed all.
      Signed-off-by: NShaohua Li <shaohua.li@intel.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      e1a2a51e
    • A
      PCI: drivers/pci/pci.c: add prototypes · 19792a08
      Adrian Bunk 提交于
      This patch adds prototypes for pcibios_disable_device() and
      pcibios_set_pcie_reset_state() in include/linux/pci.h
      
      While I was at it, I also removed the unneeded "extern" from the
      prototype of pcibios_add_platform_entries().
      Signed-off-by: NAdrian Bunk <bunk@kernel.org>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      19792a08
  15. 13 5月, 2008 1 次提交
  16. 30 4月, 2008 3 次提交
    • Y
      x86/pci: remove flag in pci_cfg_space_size_ext · 70b9f7dc
      Yinghai Lu 提交于
      so let pci_cfg_space_size call it directly without flag.
      Signed-off-by: NYinghai Lu <yhlu.kernel@gmail.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      70b9f7dc
    • S
      x86: fix section mismatch in pci_scan_bus · 98db6f19
      Sam Ravnborg 提交于
      Fix following section mismatch warning:
      WARNING: vmlinux.o(.text+0x275616): Section mismatch in reference from the function pci_scan_bus() to the function .devinit.text:pci_scan_bus_parented()
      
      The warning was seen with a CONFIG_DEBUG_SECTION_MISMATCH=y build.
      The inline function pci_scan_bus refer to functions annotated
      __devinit - so annotate it __devinit too.
      This revealed a few x86 specific functions that were only
      used from __init or __devinit context.
      So annotate these __devinit and the warning was killed.
      
      The added include in pci.h was not strictly required but
      added to avoid being dependent on indirect includes.
      Signed-off-by: NSam Ravnborg <sam@ravnborg.org>
      Signed-off-by: NJesse Barnes <jbarnes@hobbes.lan>
      98db6f19
    • Y
      pci/irq: let pci_device_shutdown to call pci_msi_shutdown v2 · d52877c7
      Yinghai Lu 提交于
      [PATCH 2/2] pci/irq: let pci_device_shutdown to call pci_msi_shutdown v2
      
      this change
      
      | commit 23a274c8
      | Author: Prakash, Sathya <sathya.prakash@lsi.com>
      | Date:   Fri Mar 7 15:53:21 2008 +0530
      |
      |     [SCSI] mpt fusion: Enable MSI by default for SAS controllers
      |
      |     This patch modifies the driver to enable MSI by default for all SAS chips.
      |
      |     Signed-off-by: Sathya Prakash <sathya.prakash@lsi.com>
      |     Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
      |
      Causes the kexec of a RHEL 5.1 kernel to fail.
      
      root casue: the rhel 5.1 kernel still uses INTx emulation.  and
      mptscsih_shutdown doesn't call pci_disable_msi to reenable INTx on kexec path
      
      So call pci_msi_shutdown in the shutdown path to do the same thing to msix
      Signed-off-by: NYinghai Lu <yhlu.kernel@gmail.com>
      Signed-off-by: NJesse Barnes <jbarnes@hobbes.lan>
      d52877c7
  17. 29 4月, 2008 1 次提交
  18. 27 4月, 2008 4 次提交
  19. 21 4月, 2008 4 次提交
    • B
      PCI: Expose PCI VPD through sysfs · 94e61088
      Ben Hutchings 提交于
      Vital Product Data (VPD) may be exposed by PCI devices in several
      ways.  It is generally unsafe to read this information through the
      existing interfaces to user-land because of stateful interfaces.
      
      This adds:
      - abstract operations for VPD access (struct pci_vpd_ops)
      - VPD state information in struct pci_dev (struct pci_vpd)
      - an implementation of the VPD access method specified in PCI 2.2
        (in access.c)
      - a 'vpd' binary file in sysfs directories for PCI devices with VPD
        operations defined
      
      It adds a probe for PCI 2.2 VPD in pci_scan_device() and release of
      VPD state in pci_release_dev().
      Signed-off-by: NBen Hutchings <bhutchings@solarflare.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      94e61088
    • B
      PCI: add generic pci_enable_resources() · 842de40d
      Bjorn Helgaas 提交于
      Each architecture has its own pcibios_enable_resources() implementation.
      These differ in many minor ways that have nothing to do with actual
      architectural differences.  Follow-on patches will make most arches
      use this generic version instead.
      
      This version is based on powerpc, which seemed most up-to-date.  The only
      functional difference from the x86 version is that this uses "!r->parent"
      to check for resource collisions instead of "!r->start && r->end".
      Signed-off-by: NBjorn Helgaas <bjorn.helgaas@hp.com>
      Acked-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Acked-by: NDavid Howells <dhowells@redhat.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      842de40d
    • S
      PCI: add PCI Express ASPM support · 7d715a6c
      Shaohua Li 提交于
      PCI Express ASPM defines a protocol for PCI Express components in the D0
      state to reduce Link power by placing their Links into a low power state
      and instructing the other end of the Link to do likewise. This
      capability allows hardware-autonomous, dynamic Link power reduction
      beyond what is achievable by software-only controlled power management.
      However, The device should be configured by software appropriately.
      Enabling ASPM will save power, but will introduce device latency.
      
      This patch adds ASPM support in Linux. It introduces a global policy for
      ASPM, a sysfs file /sys/module/pcie_aspm/parameters/policy can control
      it. The interface can be used as a boot option too. Currently we have
      below setting:
              -default, BIOS default setting
              -powersave, highest power saving mode, enable all available ASPM
      state and clock power management
              -performance, highest performance, disable ASPM and clock power
      management
      By default, the 'default' policy is used currently.
      
      In my test, power difference between powersave mode and performance mode
      is about 1.3w in a system with 3 PCIE links.
      
      Note: some devices might not work well with aspm, either because chipset
      issue or device issue. The patch provide API (pci_disable_link_state),
      driver can disable ASPM for specific device.
      Signed-off-by: NShaohua Li <shaohua.li@intel.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      7d715a6c
    • G
      PCI: remove global list of PCI devices · 5ff580c1
      Greg Kroah-Hartman 提交于
      This patch finally removes the global list of PCI devices.  We are
      relying entirely on the list held in the driver core now, and do not
      need a separate "shadow" list as no one uses it.
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      5ff580c1