1. 28 1月, 2009 1 次提交
  2. 17 1月, 2009 1 次提交
  3. 08 1月, 2009 1 次提交
  4. 08 12月, 2008 1 次提交
  5. 23 10月, 2008 1 次提交
  6. 21 10月, 2008 1 次提交
  7. 07 8月, 2008 1 次提交
  8. 29 7月, 2008 1 次提交
  9. 26 6月, 2008 1 次提交
    • B
      PCI: use dev_printk when possible · 80ccba11
      Bjorn Helgaas 提交于
      Convert printks to use dev_printk().
      
      I converted pr_debug() to dev_dbg().  Both use KERN_DEBUG and are enabled
      only when DEBUG is defined.
      
      I converted printk(KERN_DEBUG) to dev_printk(KERN_DEBUG), not to dev_dbg(),
      because dev_dbg() is only enabled when DEBUG is defined.
      
      I converted DBG(KERN_INFO) (only in setup-bus.c) to dev_info().  The DBG()
      name makes it sound like debug, but it's been enabled forever, so dev_info()
      preserves the previous behavior.
      
      I tried to make the resource assignment formats more consistent, e.g.,
        "BAR %d: got res [%#llx-%#llx] bus [%#llx-%#llx] flags %#lx\n"
      instead of sometimes using "start-end" and sometimes using "size@start".
      I'm not attached to one or the other; I'd just like them consistent.
      Signed-off-by: NBjorn Helgaas <bjorn.helgaas@hp.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      80ccba11
  10. 11 6月, 2008 1 次提交
  11. 30 4月, 2008 2 次提交
    • 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
    • Y
      pci/irq: restore mask_bits in msi shutdown -v3 · 8e149e09
      Yinghai Lu 提交于
      [PATCH 1/2] pci/irq: restore mask_bits in msi shutdown -v3
      
      Yinghai found that kexec'ing a RHEL 5.1 kernel with 2.6.25-rc3+ kernels
      prevents his NIC from working.  He bisected to
      
      | commit 89d694b9
      | Author: Thomas Gleixner <tglx@linutronix.de>
      | Date:   Mon Feb 18 18:25:17 2008 +0100
      |
      |   genirq: do not leave interupts enabled on free_irq
      |
      |   The default_disable() function was changed in commit:
      |
      |    76d21601
      |    genirq: do not mask interrupts by default
      |
      
      For MSI, default_shutdown will call mask_bit for msi device.  All mask bits
      will left disabled after free_irq.  Then in the kexec case, the next kernel
      can only use msi_enable bit, so all device's MSI can not be used.
      
      So lets to restore the mask bit to its pci reset defined value (enabled) when
      we disable the kernels use of msi to be a little friendlier to kexec'd kernels.
      
      Extend msi_set_mask_bit to msi_set_mask_bits to take mask, so we can fully
      restore that to 0x00 instead of 0xfe.
      Signed-off-by: NYinghai Lu <yhlu.kernel@gmail.com>
      Signed-off-by: NJesse Barnes <jbarnes@hobbes.lan>
      8e149e09
  12. 02 2月, 2008 2 次提交
    • A
      PCI: drivers/pci/msi.c: move arch hooks to the top · 6a9e7f20
      Adrian Bunk 提交于
      This patch fixes the following problem present with older gcc versions:
      
      <--  snip  -->
      
      ...
        CC      drivers/pci/msi.o
      /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/pci/msi.c:692: warning: weak declaration of `arch_msi_check_device' after first use results in unspecified behavior
      /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/pci/msi.c:704: warning: weak declaration of `arch_setup_msi_irqs' after first use results in unspecified behavior
      /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/pci/msi.c:724: warning: weak declaration of `arch_teardown_msi_irqs' after first use results in unspecified behavior
      ...
      
      <--  snip  -->
      Signed-off-by: NAdrian Bunk <bunk@kernel.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      6a9e7f20
    • L
      PCI: export pci_restore_msi_state() · 94688cf2
      Linas Vepstas 提交于
      PCI error recovery usually involves the PCI adapter being reset.
      If the device is using MSI, the reset will cause the MSI state
      to be lost; the device driver needs to restore the MSI state.
      
      The pci_restore_msi_state() routine is currently protected
      by CONFIG_PM; remove this, and also export the symbol, so
      that it can be used in a modle.
      Signed-off-by: NLinas Vepstas <linas@austin.ibm.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      
      94688cf2
  13. 06 11月, 2007 1 次提交
  14. 13 10月, 2007 1 次提交
  15. 01 6月, 2007 3 次提交
    • E
      msi: mask the msix vector before we unmap it · 78b7611c
      Eric W. Biederman 提交于
      With these two lines in the reverse order the drives/block/ccis.c was
      oopsing in msi_free_irqs.  Silly us calling writel on an area after
      we unmap it.
      
      BUG: unable to handle kernel paging request at virtual address f8b2200c
       printing eip:
      c01e9cc7
      *pdpt = 0000000000003001
      *pde = 0000000037e48067
      *pte = 0000000000000000
      Oops: 0002 [#1]
      SMP
      Modules linked in: cciss ipv6 parport_pc lp parport autofs4 i2c_dev i2c_core
      sunrpc loop dm_multipath button battery asus_acpi ac tg3 floppy sg dm_snapshot
      dm_zero dm_mirror ext3 jbd dm_mod ata_piix libata mptsas scsi_transport_sas
      mptspi scsi_transport_spi mptscsih mptbase sd_mod scsi_mod
      CPU:    1
      EIP:    0060:[<c01e9cc7>]    Not tainted VLI
      EFLAGS: 00010286   (2.6.22-rc2-gd2579053 #1)
      EIP is at msi_free_irqs+0x81/0xbe
      eax: f8b22000   ebx: f71f3180   ecx: f7fff280   edx: c1886eb8
      esi: f7c4e800   edi: f7c4ec48   ebp: 00000002   esp: f5a0dec8
      ds: 007b   es: 007b   fs: 00d8  gs: 0033  ss: 0068
      Process rmmod (pid: 5286, ti=f5a0d000 task=c47d2550 task.ti=f5a0d000)
      Stack: 00000002 f8b72294 00000400 f8b69ca7 f8b6bc6c 00000002 00000000 00000000
             00000000 00000000 00000000 f5a997f4 f8b69d61 f7c5a4b0 f7c4e848 f7c4e848
             f7c4e800 f7c4e800 f8b72294 f7c4e848 f8b72294 c01e3cdf f7c4e848 c024c469
      Call Trace:
       [<f8b69ca7>] cciss_shutdown+0xae/0xc3 [cciss]
       [<f8b69d61>] cciss_remove_one+0xa5/0x178 [cciss]
       [<c01e3cdf>] pci_device_remove+0x16/0x35
       [<c024c469>] __device_release_driver+0x71/0x8e
       [<c024c56e>] driver_detach+0xa0/0xde
       [<c024bc5c>] bus_remove_driver+0x27/0x41
       [<c01e3ef3>] pci_unregister_driver+0xb/0x13
       [<f8b6a343>] cciss_cleanup+0xf/0x51 [cciss]
       [<c0139ced>] sys_delete_module+0x110/0x135
       [<c0104c7a>] sysenter_past_esp+0x5f/0x85
      
      Here's a patch that just reverses the 2 lines of code as Eric suggests. Please
      consider this for inclusion.
      Signed-off-by: NMike Miller <mike.miller@hp.com>
      Signed-off-by: NChase Maupin <chase.maupin@hp.com>
      Signed-off-by: N"Eric W. Biederman" <ebiederm@xmission.com>
      Cc: Andi Kleen <ak@suse.de>
      Cc: Greg KH <greg@kroah.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      78b7611c
    • E
      msi: fix the ordering of msix irqs · 0dd11f9b
      Eric W. Biederman 提交于
      "Mike Miller (OS Dev)" <mikem@beardog.cca.cpqcorp.net> writes:
      
      Found what seems the problem with our vectors being listed backward.  In
      drivers/pci/msi.c we should be using list_add_tail rather than list_add to
      preserve the ordering across various kernels.  Please consider this for
      inclusion.
      Signed-off-by: N"Eric W. Biederman" <ebiederm@xmission.com>
      Screwed-up-by: NMichael Ellerman <michael@ellerman.id.au>
      Cc: "Mike Miller (OS Dev)" <mikem@beardog.cca.cpqcorp.net>
      Cc: Andi Kleen <ak@suse.de>
      Cc: Greg KH <greg@kroah.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      0dd11f9b
    • D
      msi: fix ARM compile · 4fdadebc
      Dan Williams 提交于
      In file included from drivers/pci/msi.c:22:
      include/asm/smp.h:17:26: asm/arch/smp.h: No such file or directory
      include/asm/smp.h:20:3: #error "<asm-arm/smp.h> included in non-SMP build"
      include/asm/smp.h:23:1: warning: "raw_smp_processor_id" redefined
      In file included from include/linux/sched.h:65,
                       from include/linux/mm.h:4,
                       from drivers/pci/msi.c:10:
      include/linux/smp.h:85:1: warning: this is the location of the previous
      definition
      
      Tested on powerpc, i386, and x86_64.
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Acked-by: NEric W. Biederman <ebiederm@xmission.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      4fdadebc
  16. 12 5月, 2007 1 次提交
    • D
      Fix assertion failure with MSI on sparc64 · b3b7cc7b
      David Miller 提交于
      Today's find is a triggered assertion in msi_free_irqs() when the system
      doesn't support MSI, in which case arch_setup_msi_irqs() always returns
      an error.
      
      The problem is that when this happens we branch into msi_free_irqs(), to
      which you added the following assertion loop:
      
      	list_for_each_entry(entry, &dev->msi_list, list)
      		BUG_ON(irq_has_action(entry->irq));
      
      Well, if arch_setup_msi_irqs() fails, entry->irq will be zero and
      although that's never assigned to any normal devices we use that IRQ
      number for the timer interrupt on sparc64 so this assertion triggers.
      
      Better to test for zero before doing the irq_has_action() assertion
      thing.
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      b3b7cc7b
  17. 09 5月, 2007 1 次提交
  18. 03 5月, 2007 18 次提交
  19. 04 4月, 2007 1 次提交
    • E
      [PATCH] msi: synchronously mask and unmask msi-x irqs. · 348e3fd1
      Eric W. Biederman 提交于
      This is a simplified and actually more comprehensive form of a bug
      fix from Mitch Williams <mitch.a.williams@intel.com>.
      
      When we mask or unmask a msi-x irqs the writes may be posted because
      we are writing to memory mapped region.  This means the mask and
      unmask don't happen immediately but at some unspecified time in the
      future.  Which is out of sync with how the mask/unmask logic work
      for ioapic irqs.
      
      The practical result is that we get very subtle and hard to track down
      irq migration bugs.
      
      This patch performs a read flush after writes to the MSI-X table for mask
      and unmask operations.  Since the SMP affinity is set while the interrupt
      is masked, and since it's unmasked immediately after, no additional flushes
      are required in the various affinity setting routines.
      
      The testing by Mitch Williams on his especially problematic system should
      still be valid as I have only simplified the code, not changed the
      functionality.
      
      We currently have 7 drivers: cciss, mthca, cxgb3, forceth, s2io,
      pcie/portdrv_core, and qla2xxx in 2.6.21 that are affected by this
      problem when the hardware they driver is plugged into the right slot.
      
      Given the difficulty of reproducing this bug and tracing it down to
      anything that even remotely resembles a cause, even if people are
      being affected we aren't likely to see many meaningful bug reports, and
      the people who see this bug aren't likely to be able to reproduce this
      bug in a timely fashion.  So it is best to get this problem fixed
      as soon as we can so people don't have problems.
      
      Then if people do have a kernel message stating "No irq for vector" we
      will know it is yet another novel cause that needs a complete new
      investigation.
      
      Cc: Greg KH <greg@kroah.com>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Signed-off-by: N"Eric W. Biederman" <ebiederm@xmission.com>
      Acked-by: NMitch Williams <mitch.a.williams@intel.com>
      Acked-by: N"Siddha, Suresh B" <suresh.b.siddha@intel.com>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      348e3fd1