Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 30905
b: refs/heads/master
c: e58eb58
h: refs/heads/master
i:
  30903: 5d2a4bb
v: v3
  • Loading branch information
Tejun Heo authored and Jeff Garzik committed Jun 27, 2006
1 parent 98467c1 commit d521acb
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 24 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: beb07c1a56e2cff3842e22c473bd1aaaea08e532
refs/heads/master: e58eb583969ff662c8c337e9b3b50ab5ef37e27e
46 changes: 23 additions & 23 deletions trunk/drivers/scsi/libata-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1131,6 +1131,29 @@ unsigned ata_exec_internal(struct ata_device *dev,
return err_mask;
}

/*
* Execute a 'simple' command, that only consists of the opcode 'cmd' itself,
* without filling any other registers
*/
static int ata_do_simple_cmd(struct ata_device *dev, u8 cmd)
{
struct ata_taskfile tf;
int err;

ata_tf_init(dev, &tf);

tf.command = cmd;
tf.flags |= ATA_TFLAG_DEVICE;
tf.protocol = ATA_PROT_NODATA;

err = ata_exec_internal(dev, &tf, NULL, DMA_NONE, NULL, 0);
if (err)
ata_dev_printk(dev, KERN_ERR, "%s: ata command failed: %d\n",
__FUNCTION__, err);

return err;
}

/**
* ata_pio_need_iordy - check if iordy needed
* @adev: ATA device
Expand Down Expand Up @@ -4946,29 +4969,6 @@ int ata_port_offline(struct ata_port *ap)
return 0;
}

/*
* Execute a 'simple' command, that only consists of the opcode 'cmd' itself,
* without filling any other registers
*/
static int ata_do_simple_cmd(struct ata_device *dev, u8 cmd)
{
struct ata_taskfile tf;
int err;

ata_tf_init(dev, &tf);

tf.command = cmd;
tf.flags |= ATA_TFLAG_DEVICE;
tf.protocol = ATA_PROT_NODATA;

err = ata_exec_internal(dev, &tf, NULL, DMA_NONE, NULL, 0);
if (err)
ata_dev_printk(dev, KERN_ERR, "%s: ata command failed: %d\n",
__FUNCTION__, err);

return err;
}

static int ata_flush_cache(struct ata_device *dev)
{
u8 cmd;
Expand Down

0 comments on commit d521acb

Please sign in to comment.