1. 11 7月, 2006 6 次提交
  2. 09 7月, 2006 5 次提交
  3. 08 7月, 2006 1 次提交
    • D
      [PATCH] Fix cpufreq vs hotplug lockdep recursion. · a496e25d
      Dave Jones 提交于
      [ There's some not quite baked bits in cpufreq-git right now
        so sending this on as a patch instead ]
      
      On Thu, 2006-07-06 at 07:58 -0700, Tom London wrote:
      
      > After installing .2356 I get this each time I boot:
      > =======================================================
      > [ INFO: possible circular locking dependency detected ]
      > -------------------------------------------------------
      > S06cpuspeed/1620 is trying to acquire lock:
      >  (dbs_mutex){--..}, at: [<c060d6bb>] mutex_lock+0x21/0x24
      >
      > but task is already holding lock:
      >  (cpucontrol){--..}, at: [<c060d6bb>] mutex_lock+0x21/0x24
      >
      > which lock already depends on the new lock.
      >
      
      make sure the cpu hotplug recursive mutex (yuck) is taken early in the
      cpufreq codepaths to avoid a AB-BA deadlock.
      Signed-off-by: NArjan van de Ven <arjan@linux.intel.com>
      Signed-off-by: NDave Jones <davej@redhat.com>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      a496e25d
  4. 06 7月, 2006 28 次提交
    • R
      [PATCH] ahci: Ensure that we don't grab both functions · 9545b578
      root 提交于
      When we force the chip into dual fn mode so we get PATA and AHCI we must
      be sure we don't then do anything dumb like try and grab both with the AHCI
      driver.
      Signed-off-by: NAlan Cox <alan@redhat.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      9545b578
    • B
      [PATCH] libata-core.c: restore configuration boot messages in ata_dev_configure(), v2 · 5afc8142
      Borislav Petkov 提交于
      This one looks better, IMHO.
      
      This restores the default libata configuration messages printed during booting.
      
      Signed-off-by: <petkov@math.uni-muenster.de>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      5afc8142
    • T
      [PATCH] sata_sil24: add suspend/sleep support · d2298dca
      Tejun Heo 提交于
      Add suspend/sleep support.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      d2298dca
    • T
      [PATCH] sata_sil24: separate out sil24_init_controller() · 2a41a610
      Tejun Heo 提交于
      Separate out controller initialization from sil24_init_one() into
      sil24_init_controller().  This will be used by resume.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      2a41a610
    • T
      [PATCH] sata_sil: add suspend/sleep support · afb5a7cb
      Tejun Heo 提交于
      Add suspend/sleep support.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      afb5a7cb
    • T
      [PATCH] sata_sil: separate out sil_init_controller() · 3d8ec913
      Tejun Heo 提交于
      Separate out controller initialization from sil_init_one() into
      sil_init_controller().  This will be used by resume.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      3d8ec913
    • T
      [PATCH] libata: reimplement controller-wide PM · 500530f6
      Tejun Heo 提交于
      Reimplement controller-wide PM.  ata_host_set_suspend/resume() are
      defined to suspend and resume a host_set.  While suspended, EHs for
      all ports in the host_set are pegged using ATA_FLAG_SUSPENDED and
      frozen.
      
      Because SCSI device hotplug is done asynchronously against the rest of
      libata EH and the same mutex is used when adding new device, suspend
      cannot wait for hotplug to complete.  So, if SCSI device hotplug is in
      progress, suspend fails with -EBUSY.
      
      In most cases, host_set resume is followed by device resume.  As each
      resume operation requires a reset, a single host_set-wide resume
      operation may result in multiple resets.  To avoid this, resume waits
      upto 1 second giving PM to request resume for devices.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      500530f6
    • T
      [PATCH] libata: reimplement per-dev PM · d6f26d1f
      Tejun Heo 提交于
      Reimplement per-dev PM.  The original implementation directly put the
      device into suspended mode and didn't synchronize w/ EH operations
      including hotplug.  This patch reimplements ata_scsi_device_suspend()
      and ata_scsi_device_resume() such that they request EH to perform the
      respective operations.  Both functions synchronize with hotplug such
      that it doesn't operate on detached devices.
      
      Suspend waits for completion but resume just issues request and
      returns.  This allows parallel wake up of devices and thus speeds up
      system resume.
      
      Due to sdev detach synchronization, it's not feasible to separate out
      EH requesting from sdev handling; thus, ata_device_suspend/resume()
      are removed and everything is implemented in the respective
      libata-scsi functions.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      d6f26d1f
    • T
      [PATCH] libata: implement PM EH actions · 02670bf3
      Tejun Heo 提交于
      Implement two PM per-dev EH actions - ATA_EH_SUSPEND and
      ATA_EH_RESUME.  Each action puts the target device into suspended mode
      and resumes from it respectively.
      
      Once a device is put to suspended mode, no EH operations other than
      RESUME is allowed on the device.  The device will stay suspended till
      it gets resumed and thus reset and revalidated.  To implement this, a
      new device state helper - ata_dev_ready() - is implemented and used in
      EH action implementations to make them operate only on attached &
      running devices.
      
      If all possible devices on a port are suspended, reset is skipped too.
      This prevents spurious events including hotplug events from disrupting
      suspended devices.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      02670bf3
    • T
      [PATCH] libata: implement ATA_EHI_NO_AUTOPSY and QUIET · 1cdaf534
      Tejun Heo 提交于
      Implement ATA_EHI_NO_AUTOPSY and QUIET.  These used to be implied by
      ATA_PFLAG_LOADING, but new power management and PMP support need to
      use these separately.  e.g. Suspend/resume operations shouldn't print
      full EH messages and resume shouldn't be recorded as an error.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      1cdaf534
    • T
      [PATCH] libata: clean up debounce parameters and improve parameter selection · e9c83914
      Tejun Heo 提交于
      The names of predefined debounce timing parameters didn't exactly
      match their usages.  Rename to more generic names and implement param
      selection helper sata_ehc_deb_timing() which uses EHI_HOTPLUGGED to
      select params.
      
      Combined with the previous EHI_RESUME_LINK differentiation, this makes
      parameter selection accurate.  e.g. user scan resumes link but normal
      deb param is used instead of hotplug param.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      e9c83914
    • T
      [PATCH] libata: implement ATA_EHI_RESUME_LINK · 28324304
      Tejun Heo 提交于
      Implement ATA_EHI_RESUME_LINK, which indicates that the link needs to
      be resumed.  This used to be implied by ATA_EHI_HOTPLUGGED.  However,
      hotplug isn't the only event which requires link resume and separating
      this out allows other places to request link resume.  This
      differentiation also allows better debounce timing selection.
      
      This patch converts user scan to use ATA_EHI_RESUME_LINK.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      28324304
    • T
      [PATCH] libata: replace ap_lock w/ ap->lock in ata_scsi_error() · e30349d2
      Tejun Heo 提交于
      ap_lock was used because &ap->host_set->lock was too long and used a
      lot.  Now that &ap->host_set->lock is replaced with ap->lock, there's
      no reason to keep ap_lock.
      
      [ed. note: that's not entirely true.  ap_lock is a local variable,
      caching the results of a de-ref.  In theory, if the compiler is smart
      enough, this patch is cosmetic.  However, since this is not a fast
      path (it is the error path), this patch is nonetheless acceptable,
      even though it _may_ introduce a performance regression.]
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      e30349d2
    • T
      [PATCH] libata: fix ehc->i.action setting in ata_eh_autopsy() · 0662c58b
      Tejun Heo 提交于
      ata_eh_autopsy() used to directly assign determined action mask to
      ehc->i.action thus overriding actions set by some of nested analyze
      functions.  This patch makes ata_eh_autopsy() add action masks just as
      it's done in other places.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      0662c58b
    • T
      [PATCH] libata: add ap->pflags and move core dynamic flags to it · b51e9e5d
      Tejun Heo 提交于
      ap->flags is way too clamped.  Separate out core dynamic flags to
      ap->pflags.  ATA_FLAG_DISABLED is a dynamic flag but left alone as
      it's referenced by a lot of LLDs and it's gonna be removed once all
      LLDs are converted to new EH.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      b51e9e5d
    • B
      [PATCH] libata: Conditionally set host->max_cmd_len · e6d902a3
      Brian King 提交于
      In preparation for SAS attached SATA devices, which will
      not have a libata scsi_host, only setup host->max_cmd_len
      if ap->host exists.
      Signed-off-by: NBrian King <brking@us.ibm.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      e6d902a3
    • M
      [PATCH] sata_vsc: data_xfer should use mmio · a93620b8
      Martin Hicks 提交于
      Hi,
      
      sata_vsc is an MMIO device, and should use the correct data_xfer
      function.  This problem was introduced by:
      
         commit a6b2c5d4
         Author: Alan Cox <alan@lxorguk.ukuu.org.uk>
         Date:   Mon May 22 16:59:59 2006 +0100
      
              [PATCH] PATCH: libata. Add ->data_xfer method
      Signed-off-by: NMartin Hicks <mort@bork.org>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      a93620b8
    • A
      [PATCH] 8139too deadlock fix · bce305f4
      Arjan van de Ven 提交于
      > stack backtrace:
      
      >  [<f9099d31>] rtl8139_start_xmit+0xd9/0xff [8139too]
      >  [<c11ad5ea>] netpoll_send_skb+0x98/0xea
      
      This seems to be a real deadlock...
      
      So netpoll_send_skb takes the _xmit_lock, which is all nitty gritty
      but then rtl8139_start_xmit comes around while that lock is taken, and
      does
      
            spin_unlock_irq(&tp->lock);
      
      which.. enables interrupts and softirqs; this is quite bad because the
      xmit lock is taken in softirq context for the watchdog like this:
        [<c1200376>] _spin_lock+0x23/0x32
        [<c11af282>] dev_watchdog+0x14/0xb1
        [<c101dab2>] run_timer_softirq+0xf2/0x14a
        [<c101a691>] __do_softirq+0x55/0xb0
        [<c1004a8d>] do_softirq+0x58/0xbd
      
      Which would deadlock now that the spin_unlock_irq() has enabled
      irqs/softirqs while the _xmit_lock is still held.
      
      The patch below turns this into a irqsave/irqrestore pair so that
      interrupts don't get enabled unconditionally.
      Signed-off-by: NArjan van de Ven <arjan@linux.intel.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      bce305f4
    • J
      [netdrvr] 3c59x: snip changelog from source code · 20ed7c09
      Jeff Garzik 提交于
      Driver source code is not the preferred place to store change history.
      Acked-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      20ed7c09
    • B
      [PATCH] myri10ge - Export more parameters to ethtool · 2c1a1088
      Brice Goglin 提交于
      Add the IRQ line, the tx_boundary, and whether Write-combining and MSI
      are enabled to the list of parameters that are exported to ethtool.
      Signed-off-by: NBrice Goglin <brice@myri.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      2c1a1088
    • B
      [PATCH] myri10ge - Use dev_info() when printing parameters after probe · d6020787
      Brice Goglin 提交于
      Displaying the interface name when listing the device parameters
      at the end of myri10ge_probe is not a good idea since udev might
      rename the interface soon afterwards.
      Print the bus id instead, using dev_info().
      Signed-off-by: NBrice Goglin <brice@myri.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      d6020787
    • B
      [PATCH] myri10ge - Drop ununsed nvidia chipset id · 18ac5443
      brice@myri.com 提交于
      The workaround for the AER capability of the nVidia chipset has been
      removed, we don't need this PCI id anymore. Drop it.
      Signed-off-by: NBrice Goglin <brice@myri.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      18ac5443
    • B
      [PATCH] myri10ge - Drop unused pm_state · ec590970
      brice@myri.com 提交于
      The pm_state field in the myri10ge_priv structure is unused. Drop it.
      Signed-off-by: NBrice Goglin <brice@myri.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      ec590970
    • R
      [PATCH] Fix freeing of net device · b07db75a
      Ralf Baechle 提交于
      Plus optical sugar.
      Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      b07db75a
    • P
      [PATCH] remove dead entry in net wan Kconfig · 22db99bd
      Paul Fulghum 提交于
      Remove dead entry from net wan Kconfig and net wan Makefile..  This entry is
      left over from 2.4 where synclink used syncppp driver directly.  synclink
      drivers now use generic HDLC
      Signed-off-by: NPaul Fulghum <paulkf@microgate.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      22db99bd
    • A
      [PATCH] NI5010 netcard cleanup · 5b552b16
      Andreas Mohr 提交于
      - updated MAINTAINERS entry to new format
      - updated Jan-Pascal's (ACKed) and my email address
      - driver cleanup/modernization (runtime-, not hardware-tested)
      
      [bunk@stusta.de: build fix]
      Signed-off-by: NAndreas Mohr <andi@lisas.de>
      Cc: Jeff Garzik <jeff@garzik.org>
      Cc: Jan-Pascal van Best <jvbest@qv3pluto.leidenuniv.nl>
      Signed-off-by: NAdrian Bunk <bunk@stusta.de>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      5b552b16
    • I
      [PATCH] lock validator: fix ns83820.c irq-flags bug · 3a10cceb
      Ingo Molnar 提交于
      Barry K. Nathan reported the following lockdep warning:
      
      [  197.343948] BUG: warning at kernel/lockdep.c:1856/trace_hardirqs_on()
      [  197.345928]  [<c010329b>] show_trace_log_lvl+0x5b/0x105
      [  197.346359]  [<c0103896>] show_trace+0x1b/0x20
      [  197.346759]  [<c01038ed>] dump_stack+0x1f/0x24
      [  197.347159]  [<c012efa2>] trace_hardirqs_on+0xfb/0x185
      [  197.348873]  [<c029b009>] _spin_unlock_irq+0x24/0x2d
      [  197.350620]  [<e09034e8>] do_tx_done+0x171/0x179 [ns83820]
      [  197.350895]  [<e090445c>] ns83820_irq+0x149/0x20b [ns83820]
      [  197.351166]  [<c013b4b8>] handle_IRQ_event+0x1d/0x52
      [  197.353216]  [<c013c6c2>] handle_level_irq+0x97/0xe1
      [  197.355157]  [<c01048c3>] do_IRQ+0x8b/0xac
      [  197.355612]  [<c0102d9d>] common_interrupt+0x25/0x2c
      
      this is caused because the ns83820 driver re-enables irq flags
      in hardirq context.
      
      While legal in theory, in practice it should only be done if the
      hardware is really old and has some very high overhead in its ISR.
      (such as PIO IDE)
      
      For modern hardware, running ISRs with irqs enabled is discouraged,
      because 1) new hardware is fast enough to not cause latency problems
      2) allowing the nesting of hardware interrupts only 'spreads out'
      the handling of the current ISR, causing extra cachemisses that would
      otherwise not happen. Furthermore, on architectures where ISRs share
      the kernel stacks, enabling interrupts in ISRs introduces a much
      higher kernel-stack-nesting and thus kernel-stack-overflow risk.
      3) not managing irq-flags via the _irqsave / _irqrestore variants
      is dangerous: it's easy to forget whether one function nests inside
      another, and irq flags might be mismanaged.
      
      In the few cases where re-enabling interrupts in an ISR is considered
      useful (and unavoidable), it has to be taught to the lock validator
      explicitly (because the lock validator needs the "no ISR ever enables
      hardirqs" artificial simplification to keep the IRQ/softirq locking
      dependencies manageable).
      
      This teaching is done via the explicit use local_irq_enable_in_hardirq().
      On a stock kernel this maps to local_irq_enable(). If the lock validator
      is enabled then this does not enable interrupts.
      
      Now, the analysis of drivers/net/ns83820.c's irq flags use: the
      irq-enabling in irq context seems intentional, but i dont think it's
      justified. Furthermore, the driver suffers from problem #3 above too,
      in ns83820_tx_timeout() it disables irqs via local_irq_save(), but
      then it calls do_tx_done() which does a spin_unlock_irq(),
      re-enabling for a function that does not expect it! While currently
      this bug seems harmless (only some debug printout seems to be
      affected by it), it's nevertheless something to be fixed.
      
      So this patch makes the ns83820 ISR irq-flags-safe, and cleans up
      do_tx_done() use and locking to avoid the ns83820_tx_timeout() bug.
      
      From: Arjan van de Ven <arjan@linux.intel.com>
      
        ns83820_mib_isr takes the misc_lock in IRQ context.  All other places that
        do this in the ISR already use _irqsave versions, make this consistent at
        least.  At some point in the future someone should audit the driver to see
        if all _irqsave's in the ISR can go away, this is generally an iffy/fragile
        proposition though; for now get it safe, simple and consistent.
      
      From: Arjan van de Ven <arjan@linux.intel.com>
      
      ok this is a real driver deadlock:
      
      The ns83820 driver enabled interrupts (by unlocking the misc_lock with
      _irq) while still holding the rx_info.lock, which is required to be irq
      safe since it's used in the ISR like this:
                      writel(1, dev->base + IER);
                      spin_unlock_irq(&dev->misc_lock);
                      kick_rx(ndev);
                      spin_unlock_irq(&dev->rx_info.lock);
      
      This is can cause a deadlock if an irq was pending at the first
      spin_unlock_irq already, or if one would hit during kick_rx().
      Simply remove the first _irq solves this
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      Cc: Benjamin LaHaise <bcrl@kvack.org>
      Cc: Jeff Garzik <jeff@garzik.org>
      Signed-off-by: NArjan van de Ven <arjan@linux.intel.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      3a10cceb
    • D
      [PATCH] pcnet32: Cleanup rx buffers after loopback test. · ac5bfe40
      Don Fry 提交于
      More cleanup to pcnet32_loopback_test to release receive buffers if
      device is not up.  Created common routine to free rx buffers.
      
      Tested ia32 and ppc64
      Signed-off-by: NDon Fry <brazilnut@us.ibm.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      ac5bfe40