Received: by 2002:a05:6358:7058:b0:131:369:b2a3 with SMTP id 24csp9639318rwp; Thu, 20 Jul 2023 07:45:47 -0700 (PDT) X-Google-Smtp-Source: APBJJlERDClRjtfB95WHYU3ZZ+KA/77Lo/WdNS2m+WMGEJaiOm6FrmRTe93tW3Xh0OrXF0oGUX2z X-Received: by 2002:a54:4e86:0:b0:3a3:9337:4099 with SMTP id c6-20020a544e86000000b003a393374099mr1907161oiy.56.1689864346562; Thu, 20 Jul 2023 07:45:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689864346; cv=none; d=google.com; s=arc-20160816; b=cgjs/yRpgMjbCw7xkQUh19Ld/DDnl9NIMEDemLSf52AErhRaqsdQcv+GBRjJWJk8UG urW10OKNwz3SoUtJEUW4KfgTn0TB5Qu1hmfYzHSEiGCdjsNNOlI+6Y1HldbeAWykI6cF 1hhH7t4ZBG16ed740cBrxJXR2HeNjKVUsQ70hYVS43OcVRzy6S7f1nTG2GhDPruvhBYu duh97rGTNM5Y0wk29URqqRZsYbw2QoXGR51pk9GczFHUHI3cvOe6IW778NbDYF3lPhRu ILAwKeORrbFDIjIQlLOcyjx/AsVadQfxVp3iPYqgJfXEtnVphzzUPSKKBEfLIhcQ3wQ6 a8Ig== 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=2amP83fa5zZSlbjt8pOmiwJucj8YYw68bEe3RLres6c=; fh=oLVGgqMWBIR48UpzoIxqcOE5MB310kfFJfZQjVAwolo=; b=UW0H1LB6+jXrugc37RFN0fN73MKJuAuN0uxo/VyqRorCZUkTCKauoiKJAE3SZcZnWh n6O8Ov0qPwZGOEiLvkE6qpQXgSY1f1Vif6xQ3rskgnMuaM66oEa4g18baZ05YjM04njY UEFEmG7Z2Ez7hNqGyPcSZvvsByWbB/lMWb1/PfFmtwtzcBwrJNGhTAXHPqrBLYqHt6dA Is/2Ht7dAWmYbld9e1YxXcXTOXcele+8ErI63FPPMZItkPKoDjZ1+i4eueJ9hz/6/0JD VA+T75EvGWYUnJnIZG1L/66FonO4Zf2IG8qTgECdoZcyfYYFHaaWl3SygXfL4qNtL8pS gF8w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=b8+L1zWc; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b=FgYNfpzg; 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 z8-20020a17090a398800b0026306246efdsi3787101pjb.84.2023.07.20.07.45.33; Thu, 20 Jul 2023 07:45:46 -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=b8+L1zWc; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519 header.b=FgYNfpzg; 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 S231588AbjGTOSP (ORCPT + 99 others); Thu, 20 Jul 2023 10:18:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50060 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229488AbjGTOSO (ORCPT ); Thu, 20 Jul 2023 10:18:14 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [IPv6:2001:67c:2178:6::1c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F2D5E211D for ; Thu, 20 Jul 2023 07:18:12 -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-out1.suse.de (Postfix) with ESMTPS id B4A0222C6C; Thu, 20 Jul 2023 14:18:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1689862691; 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=2amP83fa5zZSlbjt8pOmiwJucj8YYw68bEe3RLres6c=; b=b8+L1zWcTxcG2gOrb48R+FjSCZVzvDweD26ePr6mTRjiRcHirgf2ZFpxDFTRi3S94vccRf jhTIQWknqIRc0ldojk0uVvy+pO3/7v9hgXPdnmZYdiwAuioeFK4C49P58brJ27/dgcJAC+ Pg3+Rzm8sWiPsrlQ4nZHB0ezTY07aY0= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1689862691; 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=2amP83fa5zZSlbjt8pOmiwJucj8YYw68bEe3RLres6c=; b=FgYNfpzgrzLwBtwMhwJla/WpOxUF0YVGwq0iZlaV2toZEjXkHfLzJKC2gy1WW2K+6lqkiJ 5K0UZSwCxutOEVBQ== 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 81F8C138EC; Thu, 20 Jul 2023 14:18:11 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id YvX4HiNCuWT2bQAAMHmgww (envelope-from ); Thu, 20 Jul 2023 14:18:11 +0000 Date: Thu, 20 Jul 2023 16:18:11 +0200 Message-ID: <87wmyuis4c.wl-tiwai@suse.de> From: Takashi Iwai To: Stefan Binding Cc: Mark Brown , Jaroslav Kysela , Takashi Iwai , , , Subject: Re: [PATCH v1 06/11] ALSA: hda: hda_component: Add pre and post playback hooks to hda_component In-Reply-To: <20230720133147.1294337-7-sbinding@opensource.cirrus.com> References: <20230720133147.1294337-1-sbinding@opensource.cirrus.com> <20230720133147.1294337-7-sbinding@opensource.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=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, 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 Thu, 20 Jul 2023 15:31:42 +0200, Stefan Binding wrote: > > These hooks can be used to add callbacks that would be run before and after > the main playback hooks. These hooks would be called for all amps, before > moving on to the next hook, i.e. pre_playback_hook would be called for > all amps, before the playback_hook is called for all amps, then finally > the post_playback_hook is called for all amps. > > Signed-off-by: Stefan Binding It's better to combine this and patch 9 for the actual calls, so that we know the full effect of the changes. thanks, Takashi > --- > sound/pci/hda/hda_component.h | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/sound/pci/hda/hda_component.h b/sound/pci/hda/hda_component.h > index 534e845b9cd1d..f170aec967c18 100644 > --- a/sound/pci/hda/hda_component.h > +++ b/sound/pci/hda/hda_component.h > @@ -15,5 +15,7 @@ struct hda_component { > struct device *dev; > char name[HDA_MAX_NAME_SIZE]; > struct hda_codec *codec; > + void (*pre_playback_hook)(struct device *dev, int action); > void (*playback_hook)(struct device *dev, int action); > + void (*post_playback_hook)(struct device *dev, int action); > }; > -- > 2.34.1 >