aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ata/libata-core.c
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2008-07-31 04:02:42 -0400
committerJeff Garzik <jgarzik@redhat.com>2008-09-29 00:22:32 -0400
commitb5b3fa386b8f96c7fa92e507e5deddc2637924b4 (patch)
tree2d203860958d43b430974bcf365f4d8d3aa36b24 /drivers/ata/libata-core.c
parentaadffb682cc5572f48cc24883681db65530bd284 (diff)
libata: misc updates to prepare for slave link
* Add ATA_EH_ALL_ACTIONS. * Make sata_link_{on|off}_line() return bool instead of int. Signed-off-by: Tejun Heo <tj@kernel.org> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers/ata/libata-core.c')
-rw-r--r--drivers/ata/libata-core.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index d156616f45f5..71024e94c576 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -4976,16 +4976,16 @@ int sata_scr_write_flush(struct ata_link *link, int reg, u32 val)
4976 * None. 4976 * None.
4977 * 4977 *
4978 * RETURNS: 4978 * RETURNS:
4979 * 1 if the port online status is available and online. 4979 * True if the port online status is available and online.
4980 */ 4980 */
4981int ata_link_online(struct ata_link *link) 4981bool ata_link_online(struct ata_link *link)
4982{ 4982{
4983 u32 sstatus; 4983 u32 sstatus;
4984 4984
4985 if (sata_scr_read(link, SCR_STATUS, &sstatus) == 0 && 4985 if (sata_scr_read(link, SCR_STATUS, &sstatus) == 0 &&
4986 (sstatus & 0xf) == 0x3) 4986 (sstatus & 0xf) == 0x3)
4987 return 1; 4987 return true;
4988 return 0; 4988 return false;
4989} 4989}
4990 4990
4991/** 4991/**
@@ -5000,16 +5000,16 @@ int ata_link_online(struct ata_link *link)
5000 * None. 5000 * None.
5001 * 5001 *
5002 * RETURNS: 5002 * RETURNS:
5003 * 1 if the port offline status is available and offline. 5003 * True if the port offline status is available and offline.
5004 */ 5004 */
5005int ata_link_offline(struct ata_link *link) 5005bool ata_link_offline(struct ata_link *link)
5006{ 5006{
5007 u32 sstatus; 5007 u32 sstatus;
5008 5008
5009 if (sata_scr_read(link, SCR_STATUS, &sstatus) == 0 && 5009 if (sata_scr_read(link, SCR_STATUS, &sstatus) == 0 &&
5010 (sstatus & 0xf) != 0x3) 5010 (sstatus & 0xf) != 0x3)
5011 return 1; 5011 return true;
5012 return 0; 5012 return false;
5013} 5013}
5014 5014
5015#ifdef CONFIG_PM 5015#ifdef CONFIG_PM