From f3ed5ebbcfb21ee4b0f008250a3301522317f26a Mon Sep 17 00:00:00 2001 From: Alexander Leidinger Date: Sat, 9 Sep 2006 14:43:03 +0000 Subject: [PATCH] Fix the check where we want to use the end of the supported range if the value is out of the supported range. Noticed by: Ed Schouten Reviewed by: Kazuhito HONDA --- sys/dev/sound/usb/uaudio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/sound/usb/uaudio.c b/sys/dev/sound/usb/uaudio.c index 9661da44ba9c..9e4b7f17a9df 100644 --- a/sys/dev/sound/usb/uaudio.c +++ b/sys/dev/sound/usb/uaudio.c @@ -4114,7 +4114,7 @@ uaudio_chan_set_param_speed(device_t dev, u_int32_t speed, int reqdir) bestspeed = UA_SAMP_LO(asf1d); hiscore = score; } - } else if (speed < UA_SAMP_HI(asf1d)) { + } else if (speed > UA_SAMP_HI(asf1d)) { score = 0xfff * UA_SAMP_HI(asf1d) / speed; if (score > hiscore) { bestspeed = UA_SAMP_HI(asf1d);