Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp463264ybl; Tue, 28 Jan 2020 06:21:57 -0800 (PST) X-Google-Smtp-Source: APXvYqzP2CK2ZodLDlyuRxDICEjr4PWELI8L6yIGtHCGFlWnR8KMdLULBIt4fBmI5HofpHXKaMeo X-Received: by 2002:a9d:5d12:: with SMTP id b18mr10638632oti.305.1580221317423; Tue, 28 Jan 2020 06:21:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1580221317; cv=none; d=google.com; s=arc-20160816; b=ydaj3j3B/kvzkbEXRg+gO0rSiT0PyyCNoHhN4G1e1g/ga0Vqipu/F5lwUvLgQtpwv/ GHVIxatNsv3EdfFGzXyvW+Y/3Q5BEp1iCxdf7oVElpIc3zV7unMYSvGvxb/zBDWAE14L BjzJ7xXhem9qncQDLZ4kHzWeAyBUBFeFxDRhavw57Q5HsURUaJlpkysdkTp7lh6iUfIN GeaWpMUjLIQ8n9KPJwVYX6B5gDK/VpEfm+TgtNyy2FiKjaiE00t34UbT51UNu2fXs/ZK udV9/zx2/r9d+0KmvgwBjc4jVa9NG4f28Da0HVucn8cmfJLD3xcr5Zt+SWahz4HaCJuy +1yQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=csEeTv90PcdZ/Ep+o6OhWWj/OdGLYtYsutFkkT5X6pM=; b=M4uZ4AWC5cW3TTXCWGL8R12V2MkUQIB5N61do2bSPtm0P822Nq8ADbhrxp1CApC/bW 9m1lIol+hSGmLtzPJm+YkSS9kvZBcpXUWh9Ciz6hbjD24x43oE3+p7ECAfDoUCKsP8eg zDxPmPrnGEb0aXZ9AxlujKy+dhhfkoakNHyRUrmwxM+dkr9FBDRqgUa7NlpGg4nDjmP4 SBFbFBrbNLc1dEClS9r3JJ8QsO1G2Qc35hVp2qycoSxTue7l8hMb9BXGpM4sQIkPxeDq 7BQBodCECtUUZerePme0WKo1H9a4l67ld4mleVIVKdq0hdK3JVRDjwUneS9pNHm2VDJ8 8leg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=nMiEvL3y; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d83si2967493oib.166.2020.01.28.06.21.45; Tue, 28 Jan 2020 06:21:57 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=nMiEvL3y; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728299AbgA1OTr (ORCPT + 99 others); Tue, 28 Jan 2020 09:19:47 -0500 Received: from mail.kernel.org ([198.145.29.99]:44242 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730929AbgA1OTo (ORCPT ); Tue, 28 Jan 2020 09:19:44 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 370E32071E; Tue, 28 Jan 2020 14:19:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1580221183; bh=bDKKJwqaY1HS0eLa+nR0eXOmJiILJrJmQGOdxTWxIOk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=nMiEvL3yTovpwfNc8+kgvjtsJC/GyWyLdD8zGdWoo3LRhfI2t7Z3HlpBQxElZam3P BlXTb3MVGQjHAn28nwU2l95zGgoA0Mmta8VGgEYFuBhuyf1kH1d2ou0UXGzD0L30Q9 Ojn4xKZXk5c2YhezFVyTRVXUaIC2F/+1w07UXQb0= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Takashi Iwai , Sasha Levin Subject: [PATCH 4.9 123/271] ALSA: usb-audio: Handle the error from snd_usb_mixer_apply_create_quirk() Date: Tue, 28 Jan 2020 15:04:32 +0100 Message-Id: <20200128135901.746566204@linuxfoundation.org> X-Mailer: git-send-email 2.25.0 In-Reply-To: <20200128135852.449088278@linuxfoundation.org> References: <20200128135852.449088278@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Takashi Iwai [ Upstream commit 328e9f6973be2ee67862cb17bf6c0c5c5918cd72 ] The error from snd_usb_mixer_apply_create_quirk() is ignored in the current usb-audio driver code, which will continue the probing even after the error. Let's take it more serious. Fixes: 7b1eda223deb ("ALSA: usb-mixer: factor out quirks") Signed-off-by: Takashi Iwai Signed-off-by: Sasha Levin --- sound/usb/mixer.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c index 64fa1bbf0acb3..54011f8543a72 100644 --- a/sound/usb/mixer.c +++ b/sound/usb/mixer.c @@ -2626,7 +2626,9 @@ int snd_usb_create_mixer(struct snd_usb_audio *chip, int ctrlif, (err = snd_usb_mixer_status_create(mixer)) < 0) goto _error; - snd_usb_mixer_apply_create_quirk(mixer); + err = snd_usb_mixer_apply_create_quirk(mixer); + if (err < 0) + goto _error; err = snd_device_new(chip->card, SNDRV_DEV_CODEC, mixer, &dev_ops); if (err < 0) -- 2.20.1