Skip to content

Commit d32d552

Browse files
cladischtiwai
authored andcommitted
ALSA: usb-audio: silence a superfluous warning
It is not advisable to print a warning when a device does not support setting the sample rate because this is perfectly valid for devices with a single rate or where rates are implicitly changed by selecting another alternate setting. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
1 parent 54a3b8d commit d32d552

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

‎sound/usb/clock.c‎

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -204,11 +204,8 @@ static int set_sample_rate_v1(struct snd_usb_audio *chip, int iface,
204204
ep = get_endpoint(alts, 0)->bEndpointAddress;
205205

206206
/* if endpoint doesn't have sampling rate control, bail out */
207-
if (!(fmt->attributes & UAC_EP_CS_ATTR_SAMPLE_RATE)) {
208-
snd_printk(KERN_WARNING "%d:%d:%d: endpoint lacks sample rate attribute bit, cannot set.\n",
209-
dev->devnum, iface, fmt->altsetting);
207+
if (!(fmt->attributes & UAC_EP_CS_ATTR_SAMPLE_RATE))
210208
return 0;
211-
}
212209

213210
data[0] = rate;
214211
data[1] = rate >> 8;

0 commit comments

Comments
 (0)