diff options
author | imp <imp@FreeBSD.org> | 2007-06-12 15:37:19 +0000 |
---|---|---|
committer | imp <imp@FreeBSD.org> | 2007-06-12 15:37:19 +0000 |
commit | d4a700c2dc6c55dae07b6ed7fe4d47508632b9f4 (patch) | |
tree | 0ae8c91399f156d2d3de7df83e1fc292de48873b /sys/dev/sound | |
parent | d6014e5948f9129258e24ea5eed97306faafe1cb (diff) | |
download | FreeBSD-src-d4a700c2dc6c55dae07b6ed7fe4d47508632b9f4.zip FreeBSD-src-d4a700c2dc6c55dae07b6ed7fe4d47508632b9f4.tar.gz |
Expand USB_ATTACH_{ERROR,SUCCESS}_RETURN inline and eliminate from
usb_port.h. They aren't needed, and are a legacy of this code's past.
Diffstat (limited to 'sys/dev/sound')
-rw-r--r-- | sys/dev/sound/usb/uaudio.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/sys/dev/sound/usb/uaudio.c b/sys/dev/sound/usb/uaudio.c index 7b40328..504cc17 100644 --- a/sys/dev/sound/usb/uaudio.c +++ b/sys/dev/sound/usb/uaudio.c @@ -552,14 +552,14 @@ USB_ATTACH(uaudio) if (cdesc == NULL) { printf("%s: failed to get configuration descriptor\n", device_get_nameunit(sc->sc_dev)); - USB_ATTACH_ERROR_RETURN; + return ENXIO; } err = uaudio_identify(sc, cdesc); if (err) { printf("%s: audio descriptors make no sense, error=%d\n", device_get_nameunit(sc->sc_dev), err); - USB_ATTACH_ERROR_RETURN; + return ENXIO; } sc->sc_ac_ifaceh = uaa->iface; @@ -586,7 +586,7 @@ USB_ATTACH(uaudio) if (sc->sc_alts[j].ifaceh == NULL) { printf("%s: alt %d missing AS interface(s)\n", device_get_nameunit(sc->sc_dev), j); - USB_ATTACH_ERROR_RETURN; + return ENXIO; } } @@ -620,7 +620,7 @@ USB_ATTACH(uaudio) sc->sc_dying = 0; if (audio_attach_mi(sc->sc_dev)) { printf("audio_attach_mi failed\n"); - USB_ATTACH_ERROR_RETURN; + return ENXIO; } #endif @@ -630,8 +630,7 @@ USB_ATTACH(uaudio) OID_AUTO, "async", CTLFLAG_RW, &sc->async, 0, "Asynchronous USB request"); #endif - - USB_ATTACH_SUCCESS_RETURN; + return 0; } #if defined(__NetBSD__) || defined(__OpenBSD__) |