From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 67335C433EF for ; Fri, 20 May 2022 08:09:17 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 639F41710; Fri, 20 May 2022 10:08:25 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 639F41710 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1653034155; bh=KHW/1Xy7i8E2K18cGIjwRSGFyYnQ+RvbROc42BKZJAk=; h=Date:From:To:Subject:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=UzL9iPESSmTe0Qrd8tqsx0C1CeiG+4ild7tQVBI67HW7llrhvWbMD/AYWycl2f9rH oq3n95cJc+NfJQff/D+s1m3OPFzkczQV1ODs6rt/2Zphjp1Xe9L1JUIrAVPZCuzPA/ Qx4i9M7C9Ik2f6M+hWqBTjTai8pY1TPxudBJdGrM= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id E78D0F80153; Fri, 20 May 2022 10:08:24 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id DD229F8019D; Fri, 20 May 2022 10:08:23 +0200 (CEST) Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id CA50FF80109 for ; Fri, 20 May 2022 10:08:17 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz CA50FF80109 Authentication-Results: alsa1.perex.cz; dkim=pass (1024-bit key) header.d=suse.de header.i=@suse.de header.b="xCkBp2WG"; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b="RFDTc3FC" Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out1.suse.de (Postfix) with ESMTP id 57DAB21B90; Fri, 20 May 2022 08:08:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1653034097; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=6aisJkQZmyWcJEYqaOIOicZJw3B1l30ihxIGmoJY4Yo=; b=xCkBp2WGW0DK9jDiTCoKo35Z1JeC3ANr8QlKto6Ea/VQl3T5Kcf+1jJeCY0906JTOqu2Mr QsxcCyBr/UvVxim1OwnhezDwOmt4KcX3JN/mwUbVbMxl5wT3TwJyAfduuxBDDe8Ikeo1Nt F3D10d1Til30mUop0ZF5Oc8/I+BtiTg= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1653034097; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=6aisJkQZmyWcJEYqaOIOicZJw3B1l30ihxIGmoJY4Yo=; b=RFDTc3FCID6ziAt/dntQrqJxWNTG5n29QEzx98MGavv6doCwmZm6VSmToVJyGz4WvJQTr8 7pcGfL0zdihXuHBA== Received: from valkyrie.site.suse.de (unknown [10.163.18.242]) by relay2.suse.de (Postfix) with ESMTP id 49F972C141; Fri, 20 May 2022 08:08:16 +0000 (UTC) Date: Fri, 20 May 2022 10:08:16 +0200 Message-ID: <87k0agr5hr.wl-tiwai@suse.de> From: Takashi Iwai To: Vitaly Rodionov Subject: Re: [PATCH v3 16/17] ALSA: hda: cs35l41: Support Firmware switching and reloading In-Reply-To: <20220519174749.15459-17-vitalyr@opensource.cirrus.com> References: <20220519174749.15459-1-vitalyr@opensource.cirrus.com> <20220519174749.15459-17-vitalyr@opensource.cirrus.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?ISO-2022-JP-2?B?R29qGyQoRCtXGyhC?=) APEL/10.8 Emacs/27 (x86_64-suse-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Cc: alsa-devel@alsa-project.org, patches@opensource.cirrus.com, Takashi Iwai , linux-kernel@vger.kernel.org, Stefan Binding , Mark Brown X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" On Thu, 19 May 2022 19:47:48 +0200, Vitaly Rodionov wrote: > > From: Stefan Binding > > This is required to support CS35L41 calibration. > > By default, speaker protection firmware will be loaded, if > available. However, different firmware is required to run > the calibration sequence, so it is necessary to add support > to be able to unload, switch and reload firmware. > > This patch adds 2 ALSA Controls for each amp: > "DSP1 Firmware Load" > "DSP1 Firmware Type" > > "DSP1 Firmware Load" can be used to unload and > load the firmware. > "DSP1 Firmware Type" can be used to switch the > target firmware to be loaded by "DSP1 Firmware Load" Hmm. This essentially means that you can execute the firmware load and the whole DSP init / removal just by changing this control element value, right? The end-effect is too strong, IMO. The control element is available to all users who can access the sound device, and any malicious program may change it randomly thousands times per second. That is, it can easily lead to some weird issue, I'm afraid. thanks, Takashi