diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2008-07-17 23:08:09 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2008-07-17 23:08:09 +0000 |
commit | 779d2e2cc3b9d82b7f18400b226c05dde7934a73 (patch) | |
tree | d680171240f40e42cd07454412e18928be20fc14 /sys/dev/ic | |
parent | 2698a6b3388cff6403d8bb8c040b715c1177e56c (diff) |
Zero mbreg_t structure *before* initializing any members, not when we're
halfway through. Makes the ISP12160 correctly load its firmware again on
sparc64.
ok krw@
Diffstat (limited to 'sys/dev/ic')
-rw-r--r-- | sys/dev/ic/isp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/ic/isp.c b/sys/dev/ic/isp.c index e54e65fb1a0..74a4e3f69e0 100644 --- a/sys/dev/ic/isp.c +++ b/sys/dev/ic/isp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: isp.c,v 1.43 2008/06/11 22:53:46 krw Exp $ */ +/* $OpenBSD: isp.c,v 1.44 2008/07/17 23:08:08 kettenis Exp $ */ /* * Machine and OS Independent (well, as best as possible) * code for the QLogic ISP SCSI adapters. @@ -4788,6 +4788,7 @@ isp_mbox_continue(struct ispsoftc *isp) /* * Continue with next word. */ + MEMZERO(&mbs, sizeof (mbs)); ptr = isp->isp_mbxworkp; switch (isp->isp_lastmbxcmd) { case MBOX_WRITE_RAM_WORD: @@ -4801,7 +4802,6 @@ isp_mbox_continue(struct ispsoftc *isp) break; } isp->isp_mbxworkp = ptr; - MEMZERO(&mbs, sizeof (mbs)); mbs.param[0] = isp->isp_lastmbxcmd; isp->isp_mbxwrk0 -= 1; isp_mboxcmd_qnw(isp, &mbs, 0); |