All new accounts created on Gitlab now require administrator approval. If you invite any collaborators, please let Flux staff know so they can approve the accounts.

  1. 17 Apr, 2008 1 commit
    • Tejun Heo's avatar
      libata: implement and use ata_noop_irq_clear() · 358f9a77
      Tejun Heo authored
      ->irq_clear() is used to clear IRQ bit of a SFF controller and isn't
      useful for drivers which don't use libata SFF HSM implementation.
      However, it's a required callback and many drivers implement their own
      noop version as placeholder.  This patch implements ata_noop_irq_clear
      and use it to replace those custom placeholders.
      Also, SFF drivers which don't support BMDMA don't need to use
      ata_bmdma_irq_clear().  It becomes noop if BMDMA address isn't
      initialized.  Convert them to use ata_noop_irq_clear().
      Signed-off-by: default avatarTejun Heo <>
  2. 19 Feb, 2008 1 commit
    • James Bottomley's avatar
      libata: eliminate the home grown dma padding in favour of · dde20207
      James Bottomley authored
      that provided by the block layer
      ATA requires that all DMA transfers begin and end on word boundaries.
      Because of this, a large amount of machinery grew up in ide to adjust
      scatterlists on this basis.  However, as of 2.5, the block layer has a
      dma_alignment variable which ensures both the beginning and length of a
      DMA transfer are aligned on the dma_alignment boundary.  Although the
      block layer does adjust the beginning of the transfer to ensure this
      happens, it doesn't actually adjust the length, it merely makes sure
      that space is allocated for transfers beyond the declared length.  The
      upshot of this is that scatterlists may be padded to any size between
      the actual length and the length adjusted to the dma_alignment safely
      knowing that memory is allocated in this region.
      Right at the moment, SCSI takes the default dma_aligment which is on a
      512 byte boundary.  Note that this aligment only applies to transfers
      coming in from user space.  However, since all kernel allocations are
      automatically aligned on a minimum of 32 byte boundaries, it is safe to
      adjust them in this manner as well.
      tj: * Adjusting sg after padding is done in block layer.  Make libata
            set queue alignment correctly for ATAPI devices and drop broken
            sg mangling from ata_sg_setup().
          * Use request->raw_data_len for ATAPI transfer chunk size.
          * Killed qc->raw_nbytes.
          * Separated out killing qc->n_iter.
      Signed-off-by: default avatarJames Bottomley <>
      Signed-off-by: default avatarTejun Heo <>
      Signed-off-by: default avatarJens Axboe <>
  3. 23 Jan, 2008 1 commit
    • Tejun Heo's avatar
      libata: convert to chained sg · ff2aeb1e
      Tejun Heo authored
      libata used private sg iterator to handle padding sg.  Now that sg can
      be chained, padding can be handled using standard sg ops.  Convert to
      chained sg.
      * s/qc->__sg/qc->sg/
      * s/qc->pad_sgent/qc->extra_sg[]/.  Because chaining consumes one sg
        entry.  There need to be two extra sg entries.  The renaming is also
        for future addition of other extra sg entries.
      * Padding setup is moved into ata_sg_setup_extra() which is organized
        in a way that future addition of other extra sg entries is easy.
      * qc->orig_n_elem is unused and removed.
      * qc->n_elem now contains the number of sg entries that LLDs should
        map.  qc->mapped_n_elem is added to carry the original number of
        mapped sgs for unmapping.
      * The last sg of the original sg list is used to chain to extra sg
        list.  The original last sg is pointed to by qc->last_sg and the
        content is stored in qc->saved_last_sg.  It's restored during
      * All sg walking code has been updated.  Unnecessary assertions and
        checks for conditions the core layer already guarantees are removed.
      Signed-off-by: default avatarTejun Heo <>
      Cc: Jens Axboe <>
      Signed-off-by: default avatarJeff Garzik <>
  4. 25 Oct, 2007 1 commit
  5. 12 Oct, 2007 3 commits
    • Tejun Heo's avatar
      libata: implement and use ata_port_desc() to report port configuration · cbcdd875
      Tejun Heo authored
      Currently, port configuration reporting has the following problems.
      * iomapped address is reported instead of raw address
      * report contains irrelevant fields or lacks necessary fields for
        non-SFF controllers.
      * host->irq/irq2 are there just for reporting and hacky.
      This patch implements and uses ata_port_desc() and
      ata_port_pbar_desc().  ata_port_desc() is almost identical to
      ata_ehi_push_desc() except that it takes @ap instead of @ehi, has no
      locking requirement, can only be used during host initialization and "
      " is used as separator instead of ", ".  ata_port_pbar_desc() is a
      helper to ease reporting of a PCI BAR or an offsetted address into it.
      LLD pushes whatever description it wants using the above two
      functions.  The accumulated description is printed on host
      registration after "[S/P]ATA max MAX_XFERMODE ".
      SFF init helpers and ata_host_activate() automatically add
      descriptions for addresses and irq respectively, so only LLDs which
      isn't standard SFF need to add custom descriptions.  In many cases,
      such controllers need to report different things anyway.
      Signed-off-by: default avatarTejun Heo <>
      Signed-off-by: default avatarJeff Garzik <>
    • Jeff Garzik's avatar
      [libata] Remove ->port_disable() hook · ac8869d5
      Jeff Garzik authored
      It was always set to ata_port_disable().  Removed the hook, and replaced
      the very few ap->ops->port_disable() callsites with direct calls to
      Signed-off-by: default avatarJeff Garzik <>
    • Jeff Garzik's avatar
      [libata] Remove ->irq_ack() hook, and ata_dummy_irq_on() · 6d32d30f
      Jeff Garzik authored
      * ->irq_ack() is redundant to what the irq handler already
        performs... chk-status + irq-clear.  Furthermore, it is only
        called in one place, when screaming-irq-debugging is enabled,
        so we don't want to bother with a hook just for that.
      * ata_dummy_irq_on() is only ever used in drivers that have
        no callpath reaching ->irq_on().  Remove .irq_on hook from
        those drivers, and the now-unused ata_dummy_irq_on()
      Signed-off-by: default avatarJeff Garzik <>
  6. 06 Aug, 2007 1 commit
  7. 09 Jul, 2007 1 commit
  8. 11 May, 2007 3 commits
  9. 03 May, 2007 1 commit