Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3677547pxv; Mon, 26 Jul 2021 09:13:01 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzBKr3Z9T/TKxKTsDDCMJcgKHHuUxpG+SeSc03PqOSKyIz4wuBVQ7J16j6in0Byh7y/5Lbk X-Received: by 2002:a05:6402:1057:: with SMTP id e23mr22835173edu.352.1627315981249; Mon, 26 Jul 2021 09:13:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1627315981; cv=none; d=google.com; s=arc-20160816; b=xGNfo8bYfNWVH3DemUl1/tJNtj7ey9aSDL4YspdrlohbAm/1WQJDklgKMPK7kbzgL4 YufwqpIVt9qEcj1ZVA27w1QcAjD6cvS2r54FAJ1j5Wm3U7fTIRWPpbwcVm12Be3l4hyl jo8yNsJ8vjF0XWbIGhBWzA78x6QTlSR+UMoPQhqgstncy2Emga9sWSuiDERJ62GIxSxw XfM4OetLg/Vlvi0GOX6jCiLt1Lad913Jg0VC/ITzkCVZv7vKIwwuDsm2Sp4bCqvvppVV y95FT47DPh9l7qyl7hC2pMbPJkvgSXHXQsd73x0KHwfaJZoRzFqUSB4rQz/DSZmvsubQ xwgA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=IbKDrNtu+lqRu7zh1F2uZdU3fJPC1/K5PGC0ta+VqSw=; b=zZfmQYgKGb4XSpyB9h5/vXj7Qno73dXDdc9FVJlODw4vPiIIGssUiUjNdJIXfULmdz cdaoalqGhH8e94asLoopx+qtdlbPxiu4Uhr2Kt8+kG/6VV3mK87Za2fKMSyQEVViRpsf ny8yhlHydQxv3Azs4sRtw3JN6R8VplcLKjUxTEE022xg6luJXouMQCC3GsDpUrgLrwT3 dKg/VSecXJPZP507z1OabqMCUsWItCuEVNRh8MqJEU2YpTXcUkXLLjOTWzsv9bGT9KV/ cR4YAXjQfoROQ0N6wyMsUxlcqbdcA3q05/aTk1q0tI1Z6gl7uE0HptmGj3xhYTvNULdV 3Lew== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=kLpCdctg; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id z4si345611edd.580.2021.07.26.09.12.36; Mon, 26 Jul 2021 09:13:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=kLpCdctg; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232248AbhGZPab (ORCPT + 99 others); Mon, 26 Jul 2021 11:30:31 -0400 Received: from mail.kernel.org ([198.145.29.99]:57100 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236651AbhGZPR1 (ORCPT ); Mon, 26 Jul 2021 11:17:27 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 2870A6104F; Mon, 26 Jul 2021 15:57:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1627315075; bh=uJZom4b49pGK8LOD8RhUE7UQRLP/YSZR81RjT2TP/Hk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kLpCdctgHGYUkJVNm43SurrCF0QiIQl7dcZmjQ3p3rjfhYfu3vWKEU4MuZc+xbFlS v+MsZCqiOTlzR4dWMOpioIpNxriQl78/mWmneJlX/PSuBdFOlhb2QK2lJSJN13KK9m Q1QnOZm1OwJFQZIol3AgqVbfjejlcP94Y04p2Hso= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Pavel Machek , Takashi Iwai Subject: [PATCH 5.4 072/108] ALSA: usb-audio: Add missing proc text entry for BESPOKEN type Date: Mon, 26 Jul 2021 17:39:13 +0200 Message-Id: <20210726153833.994609993@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210726153831.696295003@linuxfoundation.org> References: <20210726153831.696295003@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Takashi Iwai commit 64752a95b702817602d72f109ceaf5ec0780e283 upstream. Recently we've added a new usb_mixer element type, USB_MIXER_BESPOKEN, but it wasn't added in the table in snd_usb_mixer_dump_cval(). This is no big problem since each bespoken type should have its own dump method, but it still isn't disallowed to use the standard one, so we should cover it as well. Along with it, define the table with the explicit array initializer for avoiding other pitfalls. Fixes: 785b6f29a795 ("ALSA: usb-audio: scarlett2: Fix wrong resume call") Reported-by: Pavel Machek Cc: Link: https://lore.kernel.org/r/20210714084836.1977-1-tiwai@suse.de Signed-off-by: Takashi Iwai Signed-off-by: Greg Kroah-Hartman --- sound/usb/mixer.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) --- a/sound/usb/mixer.c +++ b/sound/usb/mixer.c @@ -3242,7 +3242,15 @@ static void snd_usb_mixer_dump_cval(stru { struct usb_mixer_elem_info *cval = mixer_elem_list_to_info(list); static const char * const val_types[] = { - "BOOLEAN", "INV_BOOLEAN", "S8", "U8", "S16", "U16", "S32", "U32", + [USB_MIXER_BOOLEAN] = "BOOLEAN", + [USB_MIXER_INV_BOOLEAN] = "INV_BOOLEAN", + [USB_MIXER_S8] = "S8", + [USB_MIXER_U8] = "U8", + [USB_MIXER_S16] = "S16", + [USB_MIXER_U16] = "U16", + [USB_MIXER_S32] = "S32", + [USB_MIXER_U32] = "U32", + [USB_MIXER_BESPOKEN] = "BESPOKEN", }; snd_iprintf(buffer, " Info: id=%i, control=%i, cmask=0x%x, " "channels=%i, type=\"%s\"\n", cval->head.id,