diff options
author | Jeff Garzik <jgarzik@pobox.com> | 2005-10-24 18:05:09 -0400 |
---|---|---|
committer | James Bottomley <jejb@mulgrave.(none)> | 2005-10-28 22:10:16 -0400 |
commit | 422c0d61d591cbfb70f029e13505fb437e169d68 (patch) | |
tree | ebafa14e1c1564ddf263868c3b6907642a8fdf1e /drivers/scsi/qlogicfas408.c | |
parent | 017560fca496f72ed9dd734ffde63ce39dfe0411 (diff) |
[SCSI] use scmd_id(), scmd_channel() throughout code
Wrap a highly common idiom. Makes the code easier to read, helps pave
the way for sdev->{id,channel} removal, and adds a token that can easily
by grepped-for in the future.
There are a couple sdev_id() and scmd_printk() updates thrown in as well.
Rejections fixed up and
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/qlogicfas408.c')
-rw-r--r-- | drivers/scsi/qlogicfas408.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/scsi/qlogicfas408.c b/drivers/scsi/qlogicfas408.c index cb75e0b7baea..52fb2ec3da70 100644 --- a/drivers/scsi/qlogicfas408.c +++ b/drivers/scsi/qlogicfas408.c | |||
@@ -243,7 +243,7 @@ static void ql_icmd(Scsi_Cmnd * cmd) | |||
243 | /**/ outb(qlcfg5, qbase + 5); /* select timer */ | 243 | /**/ outb(qlcfg5, qbase + 5); /* select timer */ |
244 | outb(qlcfg9 & 7, qbase + 9); /* prescaler */ | 244 | outb(qlcfg9 & 7, qbase + 9); /* prescaler */ |
245 | /* outb(0x99, qbase + 5); */ | 245 | /* outb(0x99, qbase + 5); */ |
246 | outb(cmd->device->id, qbase + 4); | 246 | outb(scmd_id(cmd), qbase + 4); |
247 | 247 | ||
248 | for (i = 0; i < cmd->cmd_len; i++) | 248 | for (i = 0; i < cmd->cmd_len; i++) |
249 | outb(cmd->cmnd[i], qbase + 2); | 249 | outb(cmd->cmnd[i], qbase + 2); |
@@ -450,7 +450,7 @@ irqreturn_t qlogicfas408_ihandl(int irq, void *dev_id, struct pt_regs *regs) | |||
450 | int qlogicfas408_queuecommand(Scsi_Cmnd * cmd, void (*done) (Scsi_Cmnd *)) | 450 | int qlogicfas408_queuecommand(Scsi_Cmnd * cmd, void (*done) (Scsi_Cmnd *)) |
451 | { | 451 | { |
452 | struct qlogicfas408_priv *priv = get_priv_by_cmd(cmd); | 452 | struct qlogicfas408_priv *priv = get_priv_by_cmd(cmd); |
453 | if (cmd->device->id == priv->qinitid) { | 453 | if (scmd_id(cmd) == priv->qinitid) { |
454 | cmd->result = DID_BAD_TARGET << 16; | 454 | cmd->result = DID_BAD_TARGET << 16; |
455 | done(cmd); | 455 | done(cmd); |
456 | return 0; | 456 | return 0; |