diff options
author | Alexander Yurchenko <grange@cvs.openbsd.org> | 2004-02-13 23:47:30 +0000 |
---|---|---|
committer | Alexander Yurchenko <grange@cvs.openbsd.org> | 2004-02-13 23:47:30 +0000 |
commit | 3665490c88a0927e4a671887ffa561d84d17774a (patch) | |
tree | d9ba1ff5ae4c4c9ead30992b65802f9b75120422 /sys | |
parent | 989c08c34b86bdf91aa83a9afc331313eee70539 (diff) |
Cleanup debug messages: use %b for status, %x -> 0x%x, wrap lines.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/atapiscsi/atapiscsi.c | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/sys/dev/atapiscsi/atapiscsi.c b/sys/dev/atapiscsi/atapiscsi.c index a03735f79a3..c1b06d02e3a 100644 --- a/sys/dev/atapiscsi/atapiscsi.c +++ b/sys/dev/atapiscsi/atapiscsi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: atapiscsi.c,v 1.70 2004/02/07 19:59:43 grange Exp $ */ +/* $OpenBSD: atapiscsi.c,v 1.71 2004/02/13 23:47:29 grange Exp $ */ /* * This code is derived from code with the copyright below. @@ -362,8 +362,8 @@ wdc_atapi_send_cmd(sc_xfer) s = splbio(); if (drvp->atapi_cap & ACAP_DSC) { - WDCDEBUG_PRINT(("about to send cmd %x ", sc_xfer->cmd->opcode), - DEBUG_DSC); + WDCDEBUG_PRINT(("about to send cmd 0x%x ", + sc_xfer->cmd->opcode), DEBUG_DSC); switch (sc_xfer->cmd->opcode) { case READ: case WRITE: @@ -754,7 +754,8 @@ wdc_atapi_real_start(chp, xfer, timeout, ret) xfer->next = wdc_atapi_real_start_2; ret->timeout = ATAPI_DELAY; - WDCDEBUG_PRINT(("wdc_atapi_start %s:%d:%d, scsi flags 0x%x, ATA flags 0x%x\n", + WDCDEBUG_PRINT(("wdc_atapi_start %s:%d:%d, scsi flags 0x%x, " + "ATA flags 0x%x\n", chp->wdc->sc_dev.dv_xname, chp->channel, drvp->drive, sc_xfer->flags, xfer->c_flags), DEBUG_XFERS); @@ -1036,9 +1037,10 @@ wdc_atapi_intr_data(chp, xfer, timeout, ret) if (xfer->c_bcount >= len) { WDCDEBUG_PRINT(("wdc_atapi_intr: c_bcount %d len %d " - "st 0x%x err 0x%x " + "st 0x%b err 0x%x " "ire 0x%x\n", xfer->c_bcount, - len, chp->ch_status, chp->ch_error, ire), DEBUG_INTR); + len, chp->ch_status, WDCS_BITS, chp->ch_error, ire), + DEBUG_INTR); /* Common case */ if (sc_xfer->flags & SCSI_DATA_OUT) @@ -1256,7 +1258,8 @@ wdc_atapi_pio_intr(chp, xfer, timeout, ret) ireason = CHP_READ_REG(chp, wdr_ireason); WDC_LOG_REG(chp, wdr_ireason, ireason); - WDCDEBUG_PRINT(("Phase %d, (%x, %x) ", as->protocol_phase, chp->ch_status, ireason), DEBUG_INTR ); + WDCDEBUG_PRINT(("Phase %d, (0x%b, 0x%x) ", as->protocol_phase, + chp->ch_status, WDCS_BITS, ireason), DEBUG_INTR ); switch (as->protocol_phase) { case as_data: @@ -1295,9 +1298,9 @@ timeout: WDC_LOG_REG(chp, wdr_ireason, ireason); printf("%s:%d:%d: device timeout, c_bcount=%d, c_skip=%d, " - "status=%02x, ireason=%02x\n", + "status=0x%b, ireason=0x%x\n", chp->wdc->sc_dev.dv_xname, chp->channel, xfer->drive, - xfer->c_bcount, xfer->c_skip, chp->ch_status, ireason); + xfer->c_bcount, xfer->c_skip, chp->ch_status, WDCS_BITS, ireason); sc_xfer->error = XS_TIMEOUT; xfer->next = wdc_atapi_reset; |