Received: by 2002:a05:7412:37c9:b0:e2:908c:2ebd with SMTP id jz9csp1355515rdb; Wed, 20 Sep 2023 07:05:46 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHlBQf0MU4JJR5HxjAF7kHl3Th+iM6IpLUTq6UjUx9wccjrigkoMUA/Rr5izXn9OcY+86aJ X-Received: by 2002:a05:6a20:c1aa:b0:15c:b907:9d6e with SMTP id bg42-20020a056a20c1aa00b0015cb9079d6emr2933468pzb.6.1695218746684; Wed, 20 Sep 2023 07:05:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695218746; cv=none; d=google.com; s=arc-20160816; b=PLj9/oMx61QotC4f7cdjWDjURPO5VAyh40wxzgevHAc36PzLlO6DZZEvqQRJzCYz5r H6nDQHwHHOXwcje1c8dYNSKZqWDb9MSwQv5SW5gT049+1nH20DqecfgE2T0J9Q8b5Oq3 SLh0F3r1kiFSUNjsyzHwSZcy+y+4OBs6gCjUpBou8YsWz8iKWBvBDDp0LjRDgwXJO/B5 0NP7zp6pjPzO7A+Rxeh2f1jydvPt+H1RQ7UWYqkk7DB6AYJe2ExnmI172pyl9OSm1c9I g6wmmzBc6hqIx34hJW1FvAfn8Ww+By77OAWYNcjVotFWhn8zs6QbgxeGUhzPMn3PVGqU 3Tyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=fsphzIYHG+ySJbgvkytz7d+News0nZnApC4WnZDMwDQ=; fh=Y4HRKRnNGJ76aRanlDXKo/rzWY0tq/hbpqdKMhT2pLw=; b=PyvFiF4MB35C4LeWHNGuqmj2EubdBiAMlYbSi4eLRoDLbtjLUdR6RAdJ61qMsJtUUQ f98J2tXNZdRbcyClcFBy9lIAkSZUDbO7+eaK2bYWywuzCbtkar/ugIBga97zGC7AM5ye om440eRw4bOaUl7xovP6nKNg/pIktkxuAygNxe83KNDOEdWxUZpk5LXK7i3EM5OLV3yk sKTTaRxmNG3VxsK0Zgr3RNbrAHgK+/EcnRfHa3mLW1esKaCCugplafLhT1BW+ul8JaR/ GHB7BpTNhBqH9cgtRxcM5u+8+B/aAnf8Wj4LJh7zQHi+7O/Bwqb3H06vxnkFXqQIEGt1 px4Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=YMiYqqgp; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from howler.vger.email (howler.vger.email. [23.128.96.34]) by mx.google.com with ESMTPS id e3-20020a636903000000b0056357813fc2si11516125pgc.183.2023.09.20.07.05.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Sep 2023 07:05:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) client-ip=23.128.96.34; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=YMiYqqgp; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id 8CF0C80B8DFD; Wed, 20 Sep 2023 06:50:17 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236392AbjITNuN (ORCPT + 99 others); Wed, 20 Sep 2023 09:50:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54228 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234936AbjITNuL (ORCPT ); Wed, 20 Sep 2023 09:50:11 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C34E6D6 for ; Wed, 20 Sep 2023 06:50:04 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 05B44C433C8; Wed, 20 Sep 2023 13:50:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1695217804; bh=6LBg8rWGE6wunIHc9/YosolnqJC3Zt1oTMggO9I04Dk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=YMiYqqgpYqYGc1Jjs6rEQMdzmL7iB+V+aupac4b8lBBC4V0gMI4RuAtXJd0gyChfn X+8XLj+ZK0aDfrB80REhuwgjbCfQqezAm9BK2G+zNMdsQSVS0JZpGcyeOhaAk9W5zW Djy507/y969w7S76BcPubuwqCcK06//Amj/7wsKrNdK2wFIqu4dE/vUdwzQS4xtlUO Ea6EPNPyDkFRISXHgTdhoizH2SLeJKIdi7L4QEBW6kWvkv7zgT9h4LByjcaL0FYH15 KqgwHPA2DcF5t4SI5sOmKyEfluZkr1/ialnre7ozIwdsdmSY+CXl7ftpE+AEPPFf/W 5qJHjRSwBFW2w== Date: Wed, 20 Sep 2023 15:50:01 +0200 From: Vinod Koul To: Charles Keepax Cc: yung-chuan.liao@linux.intel.com, pierre-louis.bossart@linux.intel.com, sanyog.r.kale@intel.com, linux-kernel@vger.kernel.org, patches@opensource.cirrus.com, rdunlap@infradead.org Subject: Re: [PATCH] soundwire: bus: Make IRQ handling conditionally built Message-ID: References: <20230918161026.472405-1-ckeepax@opensource.cirrus.com> <20230920085133.GE103419@ediswmail.ad.cirrus.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230920085133.GE103419@ediswmail.ad.cirrus.com> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS 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 X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Wed, 20 Sep 2023 06:50:18 -0700 (PDT) On 20-09-23, 08:51, Charles Keepax wrote: > On Wed, Sep 20, 2023 at 09:05:13AM +0200, Vinod Koul wrote: > > On 18-09-23, 17:10, Charles Keepax wrote: > > > SoundWire has provisions for a simple callback for the IRQ handling so > > > has no hard dependency on IRQ_DOMAIN, but the recent addition of IRQ > > > handling was causing builds without IRQ_DOMAIN to fail. Resolve this by > > > moving the IRQ handling into its own file and only add it to the build > > > when IRQ_DOMAIN is included in the kernel. > > > > > > Fixes: 12a95123bfe1 ("soundwire: bus: Allow SoundWire peripherals to register IRQ handlers") > > > Reported-by: kernel test robot > > > Closes: https://lore.kernel.org/oe-kbuild-all/202309150522.MoKeF4jx-lkp@intel.com/ > > > Signed-off-by: Charles Keepax > > > --- > > > drivers/soundwire/Makefile | 4 +++ > > > drivers/soundwire/bus.c | 31 +++---------------- > > > drivers/soundwire/bus_type.c | 11 +++---- > > > drivers/soundwire/irq.c | 59 ++++++++++++++++++++++++++++++++++++ > > > drivers/soundwire/irq.h | 43 ++++++++++++++++++++++++++ > > > 5 files changed, 115 insertions(+), 33 deletions(-) > > > create mode 100644 drivers/soundwire/irq.c > > > create mode 100644 drivers/soundwire/irq.h > > > > > > diff --git a/drivers/soundwire/Makefile b/drivers/soundwire/Makefile > > > index c3d3ab3262d3a..657f5888a77b0 100644 > > > --- a/drivers/soundwire/Makefile > > > +++ b/drivers/soundwire/Makefile > > > @@ -15,6 +15,10 @@ ifdef CONFIG_DEBUG_FS > > > soundwire-bus-y += debugfs.o > > > endif > > > > > > +ifdef CONFIG_IRQ_DOMAIN > > > +soundwire-bus-y += irq.o > > > +endif > > > > Any reason why we cant use depends for this? > > > > No reason we can't, but my thinking was really that SoundWire doesn't > really have a dependency on IRQ_DOMAIN, as you can use the original > callback mechanism. It seemed a shame to force it as a dependency, > when the whole subsystem can function happily without it. > > That said, I am happy to switch to a simple dependency if you prefer? > It would certainly be a much simpler change. That is very valid point, not every user needs it... I guess lets go with this change now, can you fix the comment style and we can merge this -- ~Vinod