1. 05 12月, 2009 3 次提交
    • Y
      PCI: show dma_mask bits in /sys · bb965401
      Yinghai Lu 提交于
      So we can catch if the driver sets an incorrect dma_mask.
      Reviewed-by: NGrant Grundler <grundler@google.com>
      Signed-off-by: NYinghai Lu <yinghai@kernel.org>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      bb965401
    • Y
      PCI: add debug output for DMA mask info · c6a41576
      Yinghai Lu 提交于
      This allows us to find out what DMA mask is used for each PCI device at boot
      time; useful for debugging.
      
      After the patch:
      ehci_hcd 0000:00:02.1: using 31bit consistent DMA mask
      e1000 0000:0b:01.0: using 64bit DMA mask
      e1000 0000:0b:01.0: using 64bit consistent DMA mask
      e1000e 0000:04:00.0: using 64bit DMA mask
      e1000e 0000:04:00.0: using 64bit consistent DMA mask
      ixgb 0000:0c:01.0: using 64bit DMA mask
      ixgb 0000:0c:01.0: using 64bit consistent DMA mask
      aacraid 0000:86:00.0: using 32bit DMA mask
      aacraid 0000:86:00.0: using 32bit consistent DMA mask
      aacraid 0000:86:00.0: using 64bit DMA mask
      aacraid 0000:86:00.0: using 64bit consistent DMA mask
      qla2xxx 0000:0c:02.0: using 64bit consistent DMA mask
      qla2xxx 0000:0c:02.1: using 64bit consistent DMA mask
      lpfc 0000:06:00.0: using 64bit DMA mask
      lpfc 0000:06:00.1: using 64bit DMA mask
      pata_amd 0000:00:06.0: using 32bit DMA mask
      pata_amd 0000:00:06.0: using 32bit consistent DMA mask
      mptsas 0000:0c:04.0: using 64bit DMA mask
      mptsas 0000:0c:04.0: using 64bit consistent DMA mask
      
      forcedeth 0000:00:08.0: using 39bit DMA mask
      forcedeth 0000:00:08.0: using 39bit consistent DMA mask
      niu 0000:02:00.0: using 44bit DMA mask
      niu 0000:02:00.0: using 44bit consistent DMA mask
      sata_nv 0000:00:05.0: using 32bit DMA mask
      sata_nv 0000:00:05.0: using 32bit consistent DMA mask
      ib_mthca 0000:03:00.0: using 64bit DMA mask
      ib_mthca 0000:03:00.0: using 64bit consistent DMA mask
      Reviewed-by: NGrant Grundler <grundler@google.com>
      Signed-off-by: NYinghai Lu <yinghai@kernel.org>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      c6a41576
    • J
      PCI: ibmphp_hpc: don't release hw sem twice if kthread stops · 5c788a69
      Jesse Barnes 提交于
      If we stop the kthread, we may end up up'ing the sem twice, which seems
      unintended.
      Reported-by: NDan Carpenter <error27@gmail.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      5c788a69
  2. 25 11月, 2009 11 次提交
  3. 11 11月, 2009 1 次提交
    • L
      PCI: allow matching of prefetchable resources to non-prefetchable windows · 8c8def26
      Linus Torvalds 提交于
      I'm not entirely sure it needs to go into 32, but it's probably the right
      thing to do. Another way of explaining the patch is:
      
       - we currently pick the _first_ exactly matching bus resource entry, but
         the _last_ inexactly matching one. Normally first/last shouldn't
         matter, but bus resource entries aren't actually all created equal: in
         a transparent bus, the last resources will be the parent resources,
         which we should generally try to avoid unless we have no choice. So
         "first matching" is the thing we should always aim for.
      
       - the patch is a bit bigger than it needs to be, because I simplified the
         logic at the same time. It used to be a fairly incomprehensible
      
      	if ((res->flags & IORESOURCE_PREFETCH) && !(r->flags & IORESOURCE_PREFETCH))
      		best = r;       /* Approximating prefetchable by non-prefetchable */
      
         and technically, all the patch did was to make that complex choice be
         even more complex (it basically added a "&& !best" to say that if we
         already gound a non-prefetchable window for the prefetchable resource,
         then we won't override an earlier one with that later one: remember
         "first matching").
      
       - So instead of that complex one with three separate conditionals in one,
         I split it up a bit, and am taking advantage of the fact that we
         already handled the exact case, so if 'res->flags' has the PREFETCH
         bit, then we already know that 'r->flags' will _not_ have it. So the
         simplified code drops the redundant test, and does the new '!best' test
         separately. It also uses 'continue' as a way to ignore the bus
         resource we know doesn't work (ie a prefetchable bus resource is _not_
         acceptable for anything but an exact match), so it turns into:
      
      	/* We can't insert a non-prefetch resource inside a prefetchable parent .. */
      	if (r->flags & IORESOURCE_PREFETCH)
      		continue;
      	/* .. but we can put a prefetchable resource inside a non-prefetchable one */
      	if (!best)
      		best = r;
      
         instead. With the comments, it's now six lines instead of two, but it's
         conceptually simpler, and I _could_ have written it as two lines:
      
      	if ((res->flags & IORESOURCE_PREFETCH) && !best)
      		best = r;	/* Approximating prefetchable by non-prefetchable */
      
         but I thought that was too damn subtle.
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      8c8def26
  4. 07 11月, 2009 4 次提交
  5. 05 11月, 2009 21 次提交