summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMarco Peereboom <marco@cvs.openbsd.org>2007-02-13 02:38:32 +0000
committerMarco Peereboom <marco@cvs.openbsd.org>2007-02-13 02:38:32 +0000
commit3c3aee39417d6533ff4b40355aa7bd60d9c661ad (patch)
treeb502b8fbe6082e99ffa7f64bb7539558979547be /sys
parent2a04603a3dc5bab8417159fa47d7799f98fb3d60 (diff)
Fix subtle x ? y : z bug when calling mfi_create_sgl. This worked because
during runtime the bug condition does not happen. ok krw joris
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/ic/mfi.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/dev/ic/mfi.c b/sys/dev/ic/mfi.c
index d9ad56aef8c..0b73cac8623 100644
--- a/sys/dev/ic/mfi.c
+++ b/sys/dev/ic/mfi.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mfi.c,v 1.68 2007/02/08 03:20:52 ray Exp $ */
+/* $OpenBSD: mfi.c,v 1.69 2007/02/13 02:38:31 marco Exp $ */
/*
* Copyright (c) 2006 Marco Peereboom <marco@peereboom.us>
*
@@ -825,8 +825,8 @@ mfi_scsi_io(struct mfi_ccb *ccb, struct scsi_xfer *xs, uint32_t blockno,
ccb->ccb_data = xs->data;
ccb->ccb_len = xs->datalen;
- if (mfi_create_sgl(ccb, xs->flags & SCSI_NOSLEEP) ?
- BUS_DMA_NOWAIT : BUS_DMA_WAITOK)
+ if (mfi_create_sgl(ccb, (xs->flags & SCSI_NOSLEEP) ?
+ BUS_DMA_NOWAIT : BUS_DMA_WAITOK))
return (1);
return (0);
@@ -916,8 +916,8 @@ mfi_scsi_ld(struct mfi_ccb *ccb, struct scsi_xfer *xs)
ccb->ccb_data = xs->data;
ccb->ccb_len = xs->datalen;
- if (mfi_create_sgl(ccb, xs->flags & SCSI_NOSLEEP) ?
- BUS_DMA_NOWAIT : BUS_DMA_WAITOK)
+ if (mfi_create_sgl(ccb, (xs->flags & SCSI_NOSLEEP) ?
+ BUS_DMA_NOWAIT : BUS_DMA_WAITOK))
return (1);
}