diff options
Diffstat (limited to 'sys/scsi/st.c')
-rw-r--r-- | sys/scsi/st.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/scsi/st.c b/sys/scsi/st.c index f39b44cb75d..8a3d7f99c39 100644 --- a/sys/scsi/st.c +++ b/sys/scsi/st.c @@ -1,4 +1,4 @@ -/* $OpenBSD: st.c,v 1.169 2019/09/29 17:57:36 krw Exp $ */ +/* $OpenBSD: st.c,v 1.170 2019/11/23 17:10:13 krw Exp $ */ /* $NetBSD: st.c,v 1.71 1997/02/21 23:03:49 thorpej Exp $ */ /* @@ -1357,7 +1357,7 @@ st_mode_sense(struct st_softc *st, int flags) else dev_spec = data->hdr.dev_spec; - if (dev_spec & SMH_DSP_WRITE_PROT) + if (ISSET(dev_spec, SMH_DSP_WRITE_PROT)) SET(link->flags, SDEV_READONLY); else CLR(link->flags, SDEV_READONLY); @@ -1913,7 +1913,7 @@ st_interpret_sense(struct scsi_xfer *xs) * to store datalen in the same units as resid and to adjust * xs->resid to be in bytes. */ - if (sense->error_code & SSD_ERRCODE_VALID) { + if (ISSET(sense->error_code, SSD_ERRCODE_VALID)) { if (ISSET(st->flags, ST_FIXEDBLOCKS)) resid = info * st->blksize; /* XXXX overflow? */ else |