diff options
author | Damien Bergamini <damien@cvs.openbsd.org> | 2006-09-18 18:08:33 +0000 |
---|---|---|
committer | Damien Bergamini <damien@cvs.openbsd.org> | 2006-09-18 18:08:33 +0000 |
commit | c772f56f18e7a2baf4815de1736cc30e56e17687 (patch) | |
tree | 67dcdfce6636bb50a4140dde31360ba5fef5bc93 /sys/dev/usb | |
parent | ef38c229705c5d12bd53794b729a4b64a03ffcf0 (diff) |
fix my 1.7 commit.
in uath_reset(), return on error if tsleep() fails.
Diffstat (limited to 'sys/dev/usb')
-rw-r--r-- | sys/dev/usb/if_uath.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/dev/usb/if_uath.c b/sys/dev/usb/if_uath.c index 7745f6148c5..7e5d9d30b75 100644 --- a/sys/dev/usb/if_uath.c +++ b/sys/dev/usb/if_uath.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_uath.c,v 1.8 2006/09/18 16:34:23 damien Exp $ */ +/* $OpenBSD: if_uath.c,v 1.9 2006/09/18 18:08:32 damien Exp $ */ /*- * Copyright (c) 2006 @@ -95,7 +95,8 @@ int uath_debug = 1; */ #define UATH_DEV(v, p, f) \ { { USB_VENDOR_##v, USB_PRODUCT_##v##_##p }, (f) }, \ - { { USB_VENDOR_##v, USB_PRODUCT_##v##_##p##_NF }, (f) | UATH_FLAG_ABG } + { { USB_VENDOR_##v, USB_PRODUCT_##v##_##p##_NF }, \ + (f) | UATH_FLAG_PRE_FIRMWARE } #define UATH_DEV_UG(v, p) UATH_DEV(v, p, 0) #define UATH_DEV_UX(v, p) UATH_DEV(v, p, UATH_FLAG_ABG) static const struct uath_type { @@ -1642,6 +1643,8 @@ uath_reset(struct uath_softc *sc) if (error == 0) error = tsleep(UATH_COND_INIT(sc), PCATCH, "uathinit", 5 * hz); splx(s); + if (error != 0) + return error; /* read PHY registers */ for (reg = 0x09; reg <= 0x24; reg++) { |