diff options
author | David Gwynne <dlg@cvs.openbsd.org> | 2004-11-22 22:52:45 +0000 |
---|---|---|
committer | David Gwynne <dlg@cvs.openbsd.org> | 2004-11-22 22:52:45 +0000 |
commit | 0cb3281b58f5953e2034a92af84a137de14378f5 (patch) | |
tree | 9f5216018b05868491b5e360ca8184b3122cbbc2 /sys/dev | |
parent | ecf3616e4066bb2fd21d86a2a2fad2bc727db3db (diff) |
better fix for the internal fw loader that doesnt break 64bit archs
Diffstat (limited to 'sys/dev')
-rw-r--r-- | sys/dev/usb/if_atu.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/usb/if_atu.c b/sys/dev/usb/if_atu.c index 74d867def85..7a4e9374d29 100644 --- a/sys/dev/usb/if_atu.c +++ b/sys/dev/usb/if_atu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_atu.c,v 1.24 2004/11/22 22:28:16 deraadt Exp $ */ +/* $OpenBSD: if_atu.c,v 1.25 2004/11/22 22:52:44 dlg Exp $ */ /* * Copyright (c) 2003, 2004 * Daan Vreeken <Danovitsch@Vitsch.net>. All rights reserved. @@ -1014,7 +1014,7 @@ atu_upload_internal_firmware(struct atu_softc *sc) ptr = firm; state = atu_get_dfu_state(sc); - while (bytes_left >= 0 && state > 0) { + while (block >= 0 && state > 0) { switch (state) { case DFUState_DnLoadSync: /* get DFU status */ @@ -1052,7 +1052,7 @@ atu_upload_internal_firmware(struct atu_softc *sc) ptr += block_size; bytes_left -= block_size; if (block_size == 0) - bytes_left = -1; + block = -1; break; default: |