1. 25 Apr, 2008 1 commit
    • Jeff Garzik's avatar
      [SCSI] aha152x, eata, u14-34f: minor irq handler cleanups · e19166d5
      Jeff Garzik authored
      
      
      - remove pointless casts from void*
      
      - remove needless references to 'irq' function argument, when that
        information is already stored somewhere in a driver-private struct.
      
      - where the 'irq' function argument is known never to be used, rename
        it to 'dummy' to make this more obvious
      
      - remove always-false tests for dev_id==NULL
      
      - remove always-true tests for 'irq == host_struct->irq'
      
      - replace per-irq lookup functions and tables with a direct reference
        to data object obtained via 'dev_id' function argument, passed from
        request_irq()
      
      This change's main purpose is to prepare for the patchset in
      jgarzik/misc-2.6.git#irq-remove, that explores removal of the
      never-used 'irq' argument in each interrupt handler.
      Signed-off-by: default avatarJeff Garzik <jgarzik@redhat.com>
      Signed-off-by: default avatarJames Bottomley <James.Bottomley@HansenPartnership.com>
      e19166d5
  2. 24 Apr, 2008 3 commits
  3. 22 Apr, 2008 8 commits
  4. 21 Apr, 2008 1 commit
    • FUJITA Tomonori's avatar
      block: move the padding adjustment to blk_rq_map_sg · f18573ab
      FUJITA Tomonori authored
      blk_rq_map_user adjusts bi_size of the last bio. It breaks the rule
      that req->data_len (the true data length) is equal to sum(bio). It
      broke the scsi command completion code.
      
      commit e97a294e
      
       was introduced to fix
      the above issue. However, the partial completion code doesn't work
      with it. The commit is also a layer violation (scsi mid-layer should
      not know about the block layer's padding).
      
      This patch moves the padding adjustment to blk_rq_map_sg (suggested by
      James). The padding works like the drain buffer. This patch breaks the
      rule that req->data_len is equal to sum(sg), however, the drain buffer
      already broke it. So this patch just restores the rule that
      req->data_len is equal to sub(bio) without breaking anything new.
      
      Now when a low level driver needs padding, blk_rq_map_user and
      blk_rq_map_user_iov guarantee there's enough room for padding.
      blk_rq_map_sg can safely extend the last entry of a scatter list.
      
      blk_rq_map_sg must extend the last entry of a scatter list only for a
      request that got through bio_copy_user_iov. This patches introduces
      new REQ_COPY_USER flag.
      Signed-off-by: default avatarFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
      Cc: Tejun Heo <htejun@gmail.com>
      Cc: Mike Christie <michaelc@cs.wisc.edu>
      Cc: James Bottomley <James.Bottomley@HansenPartnership.com>
      Signed-off-by: default avatarJens Axboe <jens.axboe@oracle.com>
      f18573ab
  5. 19 Apr, 2008 1 commit
  6. 18 Apr, 2008 5 commits
  7. 17 Apr, 2008 12 commits
    • Borislav Petkov's avatar
      ide-scsi: do non-atomic pc->flags testing · e3bfae4c
      Borislav Petkov authored
      
      
      ...also, convert ide-scsi to using the generic pc->flags defines.
      Signed-off-by: default avatarBorislav Petkov <petkovbb@gmail.com>
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      e3bfae4c
    • Borislav Petkov's avatar
    • Bartlomiej Zolnierkiewicz's avatar
      ide: remove IDE_*_REG macros · 23579a2a
      Bartlomiej Zolnierkiewicz authored
      
      
      * Add IDE_{ALTSTATUS,IREASON,BCOUNTL,BCOUNTH}_OFFSET defines.
      
      * Remove IDE_*_REG macros - this results in more readable
        and slightly smaller code.
      
      There should be no functional changes caused by this patch.
      
      Cc: Borislav Petkov <petkovbb@gmail.com>
      Acked-by: default avatarSergei Shtylyov <sshtylyov@ru.mvista.com>
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      23579a2a
    • Bartlomiej Zolnierkiewicz's avatar
      ide: add ide_atapi_{discard_data,write_zeros} inline helpers · 7616c0ad
      Bartlomiej Zolnierkiewicz authored
      
      
      Add ide_atapi_{discard_data,write_zeros} inline helpers to <linux/ide.h>
      and use them instead of home-brewn helpers in ide-{floppy,tape,scsi}.
      
      There should be no functional changes caused by this patch.
      
      Cc: Borislav Petkov <petkovbb@gmail.com>
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      7616c0ad
    • Tejun Heo's avatar
      libata: kill ata_noop_dev_select() · c9f75b04
      Tejun Heo authored
      
      
      Now that SFF assumptions are separated out from non-SFF reset
      sequence, port_ops->sff_dev_select() is no longer necessary for
      non-SFF controllers.  Kill ata_noop_dev_select() and ->sff_dev_select
      initialization from base and other non-SFF port_ops.
      Signed-off-by: default avatarTejun Heo <htejun@gmail.com>
      c9f75b04
    • Tejun Heo's avatar
      libata: remove check_status from non-SFF drivers · 520d06f9
      Tejun Heo authored
      
      
      Now that all SFF stuff is separated out of core layer, core layer
      doesn't call ops->[alt_]check_status().  In fact, no one calls them
      for non-SFF drivers anymore.  Kill them.
      Signed-off-by: default avatarTejun Heo <htejun@gmail.com>
      520d06f9
    • Tejun Heo's avatar
      libata: replace tf_read with qc_fill_rtf for non-SFF drivers · 4c9bf4e7
      Tejun Heo authored
      
      
      Now that all SFF stuff is separated out of core layer, core layer
      doesn't call ops->tf_read directly.  It gets called only via
      ops->qc_fill_rtf() for non-SFF drivers.  This patch directly
      implements private ops->qc_fill_rtf() for non-SFF controllers and kill
      ops->tf_read().
      
      This is much cleaner for non-SFF controllers as some of them have to
      cache SFF register values in private data structure and report the
      cached values via ops->tf_read().  Also, ops->tf_read() gets nasty for
      controllers which don't have clear notion of TF registers when
      operation is not in progress.
      
      As this change makes default ops->qc_fill_rtf unnecessary, move
      ata_sff_qc_fill_rtf() form ata_base_port_ops to ata_sff_port_ops where
      it belongs.
      Signed-off-by: default avatarTejun Heo <htejun@gmail.com>
      4c9bf4e7
    • Tejun Heo's avatar
      libata: add qc_fill_rtf port operation · 22183bf5
      Tejun Heo authored
      
      
      On command completion, ata_qc_complete() directly called ops->tf_read
      to fill qc->result_tf.  This patch adds ops->qc_fill_rtf to replace
      hardcoded ops->tf_read usage.
      
      ata_sff_qc_fill_rtf() which uses ops->tf_read to fill result_tf is
      implemented and set in ata_base_port_ops and other ops tables which
      don't inherit from ata_base_port_ops, so this patch doesn't introduce
      any behavior change.
      
      ops->qc_fill_rtf() is similar to ops->sff_tf_read() but can only be
      called when a command finishes.  As some non-SFF controllers don't
      have TF registers defined unless they're associated with in-flight
      commands, this limited operation makes life easier for those drivers
      and help lifting SFF assumptions from libata core layer.
      Signed-off-by: default avatarTejun Heo <htejun@gmail.com>
      22183bf5
    • Tejun Heo's avatar
      libata: rename SFF port ops · 5682ed33
      Tejun Heo authored
      
      
      Add sff_ prefix to SFF specific port ops.
      
      This rename is in preparation of separating SFF support out of libata
      core layer.  This patch strictly renames ops and doesn't introduce any
      behavior difference.
      Signed-off-by: default avatarTejun Heo <htejun@gmail.com>
      5682ed33
    • Tejun Heo's avatar
      libata: make reset related methods proper port operations · a1efdaba
      Tejun Heo authored
      
      
      Currently reset methods are not specified directly in the
      ata_port_operations table.  If a LLD wants to use custom reset
      methods, it should construct and use a error_handler which uses those
      reset methods.  It's done this way for two reasons.
      
      First, the ops table already contained too many methods and adding
      four more of them would noticeably increase the amount of necessary
      boilerplate code all over low level drivers.
      
      Second, as ->error_handler uses those reset methods, it can get
      confusing.  ie. By overriding ->error_handler, those reset ops can be
      made useless making layering a bit hazy.
      
      Now that ops table uses inheritance, the first problem doesn't exist
      anymore.  The second isn't completely solved but is relieved by
      providing default values - most drivers can just override what it has
      implemented and don't have to concern itself about higher level
      callbacks.  In fact, there currently is no driver which actually
      modifies error handling behavior.  Drivers which override
      ->error_handler just wraps the standard error handler only to prepare
      the controller for EH.  I don't think making ops layering strict has
      any noticeable benefit.
      
      This patch makes ->prereset, ->softreset, ->hardreset, ->postreset and
      their PMP counterparts propoer ops.  Default ops are provided in the
      base ops tables and drivers are converted to override individual reset
      methods instead of creating custom error_handler.
      
      * ata_std_error_handler() doesn't use sata_std_hardreset() if SCRs
        aren't accessible.  sata_promise doesn't need to use separate
        error_handlers for PATA and SATA anymore.
      
      * softreset is broken for sata_inic162x and sata_sx4.  As libata now
        always prefers hardreset, this doesn't really matter but the ops are
        forced to NULL using ATA_OP_NULL for documentation purpose.
      
      * pata_hpt374 needs to use different prereset for the first and second
        PCI functions.  This used to be done by branching from
        hpt374_error_handler().  The proper way to do this is to use
        separate ops and port_info tables for each function.  Converted.
      Signed-off-by: default avatarTejun Heo <htejun@gmail.com>
      a1efdaba
    • Adrian Bunk's avatar
      [SCSI] qla1280: remove version check · 0e4ff797
      Adrian Bunk authored
      
      
      There's no point for an in-kernel driver to check whether it's compiled
      under kernel < 2.6.0 .
      Signed-off-by: default avatarAdrian Bunk <bunk@kernel.org>
      Cc: Jes Sorensen <jes@sgi.com>
      Signed-off-by: default avatarJames Bottomley <James.Bottomley@HansenPartnership.com>
      0e4ff797
    • Al Viro's avatar
  8. 16 Apr, 2008 5 commits
  9. 11 Apr, 2008 1 commit
  10. 10 Apr, 2008 3 commits