aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ata/sata_sil24.c
diff options
context:
space:
mode:
authorTejun Heo <htejun@gmail.com>2007-07-16 01:29:39 -0400
committerJeff Garzik <jeff@garzik.org>2007-07-20 08:02:11 -0400
commitb64bbc39f2122a2276578e40144af69ef01decd4 (patch)
treebd760da68bc785490ecd31060d892eeb7123782d /drivers/ata/sata_sil24.c
parent975530e8a33fdeb1ad80d82fde11d56bf9ed2760 (diff)
libata: improve EH report formatting
Requiring LLDs to format multiple error description messages properly doesn't work too well. Help LLDs a bit by making ata_ehi_push_desc() insert ", " on each invocation. __ata_ehi_push_desc() is the raw version without the automatic separator. While at it, make ehi_desc interface proper functions instead of macros. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/ata/sata_sil24.c')
-rw-r--r--drivers/ata/sata_sil24.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/ata/sata_sil24.c b/drivers/ata/sata_sil24.c
index e538edc1b4ea..e201f1cab66d 100644
--- a/drivers/ata/sata_sil24.c
+++ b/drivers/ata/sata_sil24.c
@@ -814,16 +814,16 @@ static void sil24_error_intr(struct ata_port *ap)
814 814
815 if (irq_stat & (PORT_IRQ_PHYRDY_CHG | PORT_IRQ_DEV_XCHG)) { 815 if (irq_stat & (PORT_IRQ_PHYRDY_CHG | PORT_IRQ_DEV_XCHG)) {
816 ata_ehi_hotplugged(ehi); 816 ata_ehi_hotplugged(ehi);
817 ata_ehi_push_desc(ehi, ", %s", 817 ata_ehi_push_desc(ehi, "%s",
818 irq_stat & PORT_IRQ_PHYRDY_CHG ? 818 irq_stat & PORT_IRQ_PHYRDY_CHG ?
819 "PHY RDY changed" : "device exchanged"); 819 "PHY RDY changed" : "device exchanged");
820 freeze = 1; 820 freeze = 1;
821 } 821 }
822 822
823 if (irq_stat & PORT_IRQ_UNK_FIS) { 823 if (irq_stat & PORT_IRQ_UNK_FIS) {
824 ehi->err_mask |= AC_ERR_HSM; 824 ehi->err_mask |= AC_ERR_HSM;
825 ehi->action |= ATA_EH_SOFTRESET; 825 ehi->action |= ATA_EH_SOFTRESET;
826 ata_ehi_push_desc(ehi , ", unknown FIS"); 826 ata_ehi_push_desc(ehi, "unknown FIS");
827 freeze = 1; 827 freeze = 1;
828 } 828 }
829 829
@@ -842,11 +842,11 @@ static void sil24_error_intr(struct ata_port *ap)
842 if (ci && ci->desc) { 842 if (ci && ci->desc) {
843 err_mask |= ci->err_mask; 843 err_mask |= ci->err_mask;
844 action |= ci->action; 844 action |= ci->action;
845 ata_ehi_push_desc(ehi, ", %s", ci->desc); 845 ata_ehi_push_desc(ehi, "%s", ci->desc);
846 } else { 846 } else {
847 err_mask |= AC_ERR_OTHER; 847 err_mask |= AC_ERR_OTHER;
848 action |= ATA_EH_SOFTRESET; 848 action |= ATA_EH_SOFTRESET;
849 ata_ehi_push_desc(ehi, ", unknown command error %d", 849 ata_ehi_push_desc(ehi, "unknown command error %d",
850 cerr); 850 cerr);
851 } 851 }
852 852