1. 16 7月, 2007 1 次提交
  2. 14 7月, 2007 26 次提交
  3. 13 7月, 2007 13 次提交
    • D
      ioatdma: add the unisys "i/oat" pci vendor/device id · 3039f073
      Dan Williams 提交于
      Cc: John Magolan <john.magolan@unisys.com>
      Signed-off-by: NShannon Nelson <shannon.nelson@intel.com>
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      3039f073
    • D
      ARM: Add drivers/dma to arch/arm/Kconfig · 5816815f
      Dan Williams 提交于
      Cc: Russell King <rmk@arm.linux.org.uk>
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      5816815f
    • D
      iop3xx: surface the iop3xx DMA and AAU units to the iop-adma driver · 2492c845
      Dan Williams 提交于
      Adds the platform device definitions and the architecture specific support
      routines (i.e. register initialization and descriptor formats) for the
      iop-adma driver.
      
      Changelog:
      * add support for > 1k zero sum buffer sizes
      * added dma/aau platform devices to iq80321 and iq80332 setup
      * fixed the calculation in iop_desc_is_aligned
      * support xor buffer sizes larger than 16MB
      * fix places where software descriptors are assumed to be contiguous, only
        hardware descriptors are contiguous for up to a PAGE_SIZE buffer size
      * convert to async_tx
      * add interrupt support
      * add platform devices for 80219 boards
      * do not call platform register macros in driver code
      * remove switch() statements for compatible register offsets/layouts
      * change over to bitmap based capabilities
      * remove unnecessary ARM assembly statement
      * checkpatch.pl fixes
      * gpl v2 only correction
      * phys move to dma_async_tx_descriptor
      
      Cc: Russell King <rmk@arm.linux.org.uk>
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      2492c845
    • D
      iop13xx: surface the iop13xx adma units to the iop-adma driver · 39a8d7d1
      Dan Williams 提交于
      Adds the platform device definitions and the architecture specific
      support routines (i.e. register initialization and descriptor formats) for the
      iop-adma driver.
      
      Changelog:
      * added 'descriptor pool size' to the platform data
      * add base support for buffer sizes larger than 16MB (hw max)
      * build error fix from Kirill A. Shutemov
      * rebase for async_tx changes
      * add interrupt support
      * do not call platform register macros in driver code
      * remove unnecessary ARM assembly statement
      * checkpatch.pl fixes
      * gpl v2 only correction
      
      Cc: Russell King <rmk@arm.linux.org.uk>
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      39a8d7d1
    • D
      dmaengine: driver for the iop32x, iop33x, and iop13xx raid engines · c2110923
      Dan Williams 提交于
      The Intel(R) IOP series of i/o processors integrate an Xscale core with
      raid acceleration engines.  The capabilities per platform are:
      
      iop219:
       (2) copy engines
      iop321:
       (2) copy engines
       (1) xor and block fill engine
      iop33x:
       (2) copy and crc32c engines
       (1) xor, xor zero sum, pq, pq zero sum, and block fill engine
      iop34x (iop13xx):
       (2) copy, crc32c, xor, xor zero sum, and block fill engines
       (1) copy, crc32c, xor, xor zero sum, pq, pq zero sum, and block fill engine
      
      The driver supports the features of the async_tx api:
      * asynchronous notification of operation completion
      * implicit (interupt triggered) handling of inter-channel transaction
        dependencies
      
      The driver adapts to the platform it is running by two methods.
      1/ #include <asm/arch/adma.h> which defines the hardware specific
         iop_chan_* and iop_desc_* routines as a series of static inline
         functions
      2/ The private platform data attached to the platform_device defines the
         capabilities of the channels
      
      20070626: Callbacks are run in a tasklet.  Given the recent discussion on
      LKML about killing tasklets in favor of workqueues I did a quick conversion
      of the driver.  Raid5 resync performance dropped from 50MB/s to 30MB/s, so
      the tasklet implementation remains until a generic softirq interface is
      available.
      
      Changelog:
      * fixed a slot allocation bug in do_iop13xx_adma_xor that caused too few
      slots to be requested eventually leading to data corruption
      * enabled the slot allocation routine to attempt to free slots before
      returning -ENOMEM
      * switched the cleanup routine to solely use the software chain and the
      status register to determine if a descriptor is complete.  This is
      necessary to support other IOP engines that do not have status writeback
      capability
      * make the driver iop generic
      * modified the allocation routines to understand allocating a group of
      slots for a single operation
      * added a null xor initialization operation for the xor only channel on
      iop3xx
      * support xor operations on buffers larger than the hardware maximum
      * split the do_* routines into separate prep, src/dest set, submit stages
      * added async_tx support (dependent operations initiation at cleanup time)
      * simplified group handling
      * added interrupt support (callbacks via tasklets)
      * brought the pending depth inline with ioat (i.e. 4 descriptors)
      * drop dma mapping methods, suggested by Chris Leech
      * don't use inline in C files, Adrian Bunk
      * remove static tasklet declarations
      * make iop_adma_alloc_slots easier to read and remove chances for a
        corrupted descriptor chain
      * fix locking bug in iop_adma_alloc_chan_resources, Benjamin Herrenschmidt
      * convert capabilities over to dma_cap_mask_t
      * fixup sparse warnings
      * add descriptor flush before iop_chan_enable
      * checkpatch.pl fixes
      * gpl v2 only correction
      * move set_src, set_dest, submit to async_tx methods
      * move group_list and phys to async_tx
      
      Cc: Russell King <rmk@arm.linux.org.uk>
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      c2110923
    • D
      md: remove raid5 compute_block and compute_parity5 · f6dff381
      Dan Williams 提交于
      replaced by raid5_run_ops
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Acked-By: NNeilBrown <neilb@suse.de>
      f6dff381
    • D
      md: handle_stripe5 - request io processing in raid5_run_ops · 830ea016
      Dan Williams 提交于
      I/O submission requests were already handled outside of the stripe lock in
      handle_stripe.  Now that handle_stripe is only tasked with finding work,
      this logic belongs in raid5_run_ops.
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Acked-By: NNeilBrown <neilb@suse.de>
      830ea016
    • D
      md: handle_stripe5 - add request/completion logic for async expand ops · f0a50d37
      Dan Williams 提交于
      When a stripe is being expanded bulk copying takes place to move the data
      from the old stripe to the new.  Since raid5_run_ops only operates on one
      stripe at a time these bulk copies are handled in-line under the stripe
      lock.  In the dma offload case we poll for the completion of the operation.
      
      After the data has been copied into the new stripe the parity needs to be
      recalculated across the new disks.  We reuse the existing postxor
      functionality to carry out this calculation.  By setting STRIPE_OP_POSTXOR
      without setting STRIPE_OP_BIODRAIN the completion path in handle stripe
      can differentiate expand operations from normal write operations.
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Acked-By: NNeilBrown <neilb@suse.de>
      f0a50d37
    • D
      md: handle_stripe5 - add request/completion logic for async read ops · b5e98d65
      Dan Williams 提交于
      When a read bio is attached to the stripe and the corresponding block is
      marked R5_UPTODATE, then a read (biofill) operation is scheduled to copy
      the data from the stripe cache to the bio buffer.  handle_stripe flags the
      blocks to be operated on with the R5_Wantfill flag.  If new read requests
      arrive while raid5_run_ops is running they will not be handled until
      handle_stripe is scheduled to run again.
      
      Changelog:
      * cleanup to_read and to_fill accounting
      * do not fail reads that have reached the cache
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Acked-By: NNeilBrown <neilb@suse.de>
      b5e98d65
    • D
      md: handle_stripe5 - add request/completion logic for async check ops · e89f8962
      Dan Williams 提交于
      Check operations are scheduled when the array is being resynced or an
      explicit 'check/repair' command was sent to the array.  Previously check
      operations would destroy the parity block in the cache such that even if
      parity turned out to be correct the parity block would be marked
      !R5_UPTODATE at the completion of the check.  When the operation can be
      carried out by a dma engine the assumption is that it can check parity as a
      read-only operation.  If raid5_run_ops notices that the check was handled
      by hardware it will preserve the R5_UPTODATE status of the parity disk.
      
      When a check operation determines that the parity needs to be repaired we
      reuse the existing compute block infrastructure to carry out the operation.
      Repair operations imply an immediate write back of the data, so to
      differentiate a repair from a normal compute operation the
      STRIPE_OP_MOD_REPAIR_PD flag is added.
      
      Changelog:
      * remove test_and_set/test_and_clear BUG_ONs, Neil Brown
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Acked-By: NNeilBrown <neilb@suse.de>
      e89f8962
    • D
      md: handle_stripe5 - add request/completion logic for async compute ops · f38e1219
      Dan Williams 提交于
      handle_stripe will compute a block when a backing disk has failed, or when
      it determines it can save a disk read by computing the block from all the
      other up-to-date blocks.
      
      Previously a block would be computed under the lock and subsequent logic in
      handle_stripe could use the newly up-to-date block.  With the raid5_run_ops
      implementation the compute operation is carried out a later time outside
      the lock.  To preserve the old functionality we take advantage of the
      dependency chain feature of async_tx to flag the block as R5_Wantcompute
      and then let other parts of handle_stripe operate on the block as if it
      were up-to-date.  raid5_run_ops guarantees that the block will be ready
      before it is used in another operation.
      
      However, this only works in cases where the compute and the dependent
      operation are scheduled at the same time.  If a previous call to
      handle_stripe sets the R5_Wantcompute flag there is no facility to pass the
      async_tx dependency chain across successive calls to raid5_run_ops.  The
      req_compute variable protects against this case.
      
      Changelog:
      * remove the req_compute BUG_ON
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Acked-By: NNeilBrown <neilb@suse.de>
      f38e1219
    • D
      md: handle_stripe5 - add request/completion logic for async write ops · e33129d8
      Dan Williams 提交于
      After handle_stripe5 decides whether it wants to perform a
      read-modify-write, or a reconstruct write it calls
      handle_write_operations5.  A read-modify-write operation will perform an
      xor subtraction of the blocks marked with the R5_Wantprexor flag, copy the
      new data into the stripe (biodrain) and perform a postxor operation across
      all up-to-date blocks to generate the new parity.  A reconstruct write is run
      when all blocks are already up-to-date in the cache so all that is needed
      is a biodrain and postxor.
      
      On the completion path STRIPE_OP_PREXOR will be set if the operation was a
      read-modify-write.  The STRIPE_OP_BIODRAIN flag is used in the completion
      path to differentiate write-initiated postxor operations versus
      expansion-initiated postxor operations.  Completion of a write triggers i/o
      to the drives.
      
      Changelog:
      * make the 'rcw' parameter to handle_write_operations5 a simple flag, Neil Brown
      * remove test_and_set/test_and_clear BUG_ONs, Neil Brown
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Acked-By: NNeilBrown <neilb@suse.de>
      e33129d8
    • D
      md: common infrastructure for running operations with raid5_run_ops · d84e0f10
      Dan Williams 提交于
      All the handle_stripe operations that are to be transitioned to use
      raid5_run_ops need a method to coherently gather work under the stripe-lock
      and hand that work off to raid5_run_ops.  The 'get_stripe_work' routine
      runs under the lock to read all the bits in sh->ops.pending that do not
      have the corresponding bit set in sh->ops.ack.  This modified 'pending'
      bitmap is then passed to raid5_run_ops for processing.
      
      The transition from 'ack' to 'completion' does not need similar protection
      as the existing release_stripe infrastructure will guarantee that
      handle_stripe will run again after a completion bit is set, and
      handle_stripe can tolerate a sh->ops.completed bit being set while the lock
      is held.
      
      A call to async_tx_issue_pending_all() is added to raid5d to kick the
      offload engines once all pending stripe operations work has been submitted.
      This enables batching of the submission and completion of operations.
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Acked-By: NNeilBrown <neilb@suse.de>
      d84e0f10