From 0c1e3fbb4f3ba713898144630ff1feba04521a7f Mon Sep 17 00:00:00 2001 From: mglocker Date: Sat, 2 Aug 2008 16:34:45 +0000 Subject: [PATCH] Don't print error message if GET_DEF request fails, since this is common for some devices and we will fail back to GET_CUR then. --- sys/dev/usb/uvideo.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/sys/dev/usb/uvideo.c b/sys/dev/usb/uvideo.c index b9ce5afaea7..9b82fb0bae5 100644 --- a/sys/dev/usb/uvideo.c +++ b/sys/dev/usb/uvideo.c @@ -1,4 +1,4 @@ -/* $OpenBSD: uvideo.c,v 1.70 2008/08/02 12:32:23 mglocker Exp $ */ +/* $OpenBSD: uvideo.c,v 1.71 2008/08/02 16:34:45 mglocker Exp $ */ /* * Copyright (c) 2008 Robert Nagy @@ -47,6 +47,7 @@ #include +#undef UVIDEO_DEBUG #ifdef UVIDEO_DEBUG int uvideo_debug = 1; #define DPRINTF(l, x...) do { if ((l) <= uvideo_debug) printf(x); } while (0) @@ -1142,8 +1143,10 @@ uvideo_vs_get_probe(struct uvideo_softc *sc, uint8_t *probe_data, err = usbd_do_request(sc->sc_udev, &req, probe_data); if (err) { - printf("%s: could not GET probe request: %s\n", - DEVNAME(sc), usbd_errstr(err)); + if (request != GET_DEF) { + printf("%s: could not GET probe request: %s\n", + DEVNAME(sc), usbd_errstr(err)); + } return (USBD_INVAL); } DPRINTF(1, "%s: GET probe request successfully\n", DEVNAME(sc)); -- 2.20.1