Received: by 2002:a05:6602:18e:0:0:0:0 with SMTP id m14csp4392149ioo; Tue, 31 May 2022 03:29:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz64L0x9LiFAqxIqiMOvhtIJtxlVnBJs0e86+iBwfgi5CNvznD26Hdl31C6k6dCnIk22ffE X-Received: by 2002:a17:90a:1c02:b0:1e0:df7:31f2 with SMTP id s2-20020a17090a1c0200b001e00df731f2mr28475039pjs.222.1653992985195; Tue, 31 May 2022 03:29:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1653992985; cv=none; d=google.com; s=arc-20160816; b=EnDOP0E0PE4dhvPEkRwwjrmXzievZstqRw6Hl7OBEhCyWTA5JA8KlqKyH+Ey5tKUcb m0IVaL0NBXtKnHBUJFviyCyR5trjRSH/JXLLoEUqJq971xRsasa2M2gSM322/3UtCmBz xbdvbF3gjX4huGAI59XPtdFNUe+UREGHPwmAjWuu6bKlhR+ZrWaa+phOpDZ9fxFeoKb7 tfGnlxqo0z+Knd3CfZozTgLEthkdVkjQeGbOwTCemnh73foAIAxB9xcqxjIPT4RtRBsm u259qRZxLqNsEPJFrLZJXq2Wi43MH7HCNhDEYXcrKLyxbnG9VV6eRx5063aPjuM4Bk0R ictw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent:references:in-reply-to :subject:cc:to:from:message-id:date:dkim-signature:dkim-signature; bh=v+FA2ubRvi/QvayaIAXldHKc3DSqQn1Flnho54j7V/c=; b=Q/MIgtssPPKHyc2ERCypMWNLnI3eh681tLQ/Ka71JxL33ao31z16KVhaa4NFWEVM3O qjHvGzWoxptBzpvwk0G1WoD5A9xuOzYku29VYhYbC2D2xvZkHT2eHmnIeIz1aUB/Nfi5 iFAYravSONYHZq3v6XcNNS2zu9Z7SO0z31Jpt4zsnI4A6Xu4VrXcB4iC0i6Pq2OTMWQf B3oVIBj67vf9vFcU8Igp6zNqBY3v1y39aq4eVB43TGKmf3etCOGrz1Ylvxw1fnzS00P2 Gdsz6HOsfHpkHnNU4OGOBT3S6jj33LftvycRPTYcZK/RLNIjdTruYWPt0W7FxOHGe7Nb O0+w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=QNbqLpLa; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y31-20020a634b1f000000b00383f92e1f96si19505654pga.79.2022.05.31.03.29.33; Tue, 31 May 2022 03:29:45 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=QNbqLpLa; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234092AbiE3KOg (ORCPT + 99 others); Mon, 30 May 2022 06:14:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47454 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235157AbiE3KOa (ORCPT ); Mon, 30 May 2022 06:14:30 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B9FDD73792 for ; Mon, 30 May 2022 03:14:28 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 775AD1FA1A; Mon, 30 May 2022 10:14:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1653905667; 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=v+FA2ubRvi/QvayaIAXldHKc3DSqQn1Flnho54j7V/c=; b=QNbqLpLaXA2W9HHeRWSvOjYr8HDS4j+CpCjHWHt707OBt1yiqDVzypx2gAjdE8u66cvyJ3 mwF9g1Q0fB+JYTA8DZvr2f5U1kIXrTEfaqXj+juaVpGYCRn2uKQHUxqkO6wQq/yq81hzJx WKs+TOExp8vcbr/8QwDBCLacTKXtuaM= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1653905667; 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=v+FA2ubRvi/QvayaIAXldHKc3DSqQn1Flnho54j7V/c=; b=Ijy+1zj7zziK86qBUY6YTrMp1RkiokIsDp1S6oRQZb9agJKlBAVy0UGUEWWUxEdL0fyOwy Q6KSyEaBys1+vlAg== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 4CFE913AFD; Mon, 30 May 2022 10:14:27 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id hLPtEQOZlGKBSQAAMHmgww (envelope-from ); Mon, 30 May 2022 10:14:27 +0000 Date: Mon, 30 May 2022 12:14:26 +0200 Message-ID: <87a6azxr7h.wl-tiwai@suse.de> From: Takashi Iwai To: Charles Keepax Cc: Vitaly Rodionov , Jaroslav Kysela , Takashi Iwai , Mark Brown , , , Subject: Re: [PATCH v4 00/17] ALSA: hda: cirrus: Add initial DSP support and firmware loading In-Reply-To: <20220530093639.GT38351@ediswmail.ad.cirrus.com> References: <20220525131638.5512-1-vitalyr@opensource.cirrus.com> <871qwf0x8t.wl-tiwai@suse.de> <20220530090846.GS38351@ediswmail.ad.cirrus.com> <87czfvxtsc.wl-tiwai@suse.de> <20220530093639.GT38351@ediswmail.ad.cirrus.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) Emacs/27.2 Mule/6.0 MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 30 May 2022 11:36:39 +0200, Charles Keepax wrote: > > On Mon, May 30, 2022 at 11:18:43AM +0200, Takashi Iwai wrote: > > On Mon, 30 May 2022 11:08:46 +0200, > > Charles Keepax wrote: > > > > > > On Fri, May 27, 2022 at 06:13:38PM +0200, Takashi Iwai wrote: > > > > On Wed, 25 May 2022 15:16:21 +0200, > > > > Vitaly Rodionov wrote: > > > > The idea to add / delete controls by the control element change > > > > doesn't sound good; as already mentioned in my reply to the previous > > > > patch set, the change of the control elements can be triggered too > > > > easily by any normal users who have the access to the sound devices. > > > > It means thousands of additions and removals per second could be > > > > attacked by any user. > > > > > > > > > > This I am a little less sure how we handle. I mean arn't there > > > already a few ways to do this? Both the existing ASoC wm_adsp > > > stuff, and the topology stuff (used on all new Intel platforms, > > > so very widely deployed) let you create controls by loading a > > > firmware file. Also within ALSA itself can't user-space create > > > user ALSA controls? Is there some rate limiting on that? How is > > > this issue tackled there? > > > > The creation of kctls via firmware loading would be OK, as the code > > path can't be triggered so frequently. Is it the case for this patch > > set? There was too little information about the implementation (and > > more importantly, how to use the controls), so it's hard to judge... > > > > Yeah that should be what is happening here. Although it looks > like this code might be removing all the controls if the firmware > is unloaded. I will discuss that with the guys, we normal just > disable the controls on the wm_adsp stuff. OK, that sounds good. Basically my concern came up from the code snippet doing asynchronous addition/removal via work. This showed some yellow signal, as such a pattern doesn't appear in the normal implementation. If this is (still) really necessary, it has to be clarified as an exception. thanks, Takashi