Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp1109036ybl; Fri, 16 Aug 2019 09:03:26 -0700 (PDT) X-Google-Smtp-Source: APXvYqx1xHAOtUrxDeiwUS7C7O+Oq3HzLwnL06g4ZAfPh8/tg0rrKV96QXQ2j3KVu4KSRlA/uBBI X-Received: by 2002:aa7:9552:: with SMTP id w18mr11269390pfq.107.1565971406774; Fri, 16 Aug 2019 09:03:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565971406; cv=none; d=google.com; s=arc-20160816; b=oUpyGIx8FjgTRMtliZbfnk8xCLNfbbr2Xe1sEOcQZWlBcgLKKCQ3bdi5+cTomC2bSW IzHiJzV3FOQISaxUZznCV5h+71YbiFMk/5EIgFJigOn6ASxzW1PJXCy/lyL6cbtFsgkZ +pw/nL1GiVrUvqyoy64Pq9PesD1mxJajR6sUWEmiblF+8uGWDrKYXPIbW2+QmNrj8pJK gGMN5S5HbpEsFxqoziwBWIJ9btFqqXpfOzWY8aH/W+Rjzij3AD3HGoyJp+i1sKydVi+/ 86LFGc9RD7fgsS4jlQWE7n6Oh/lsG2cYdqaabrBcljmEm/FIt9DfB4PokFZEP8WUAsAj xY2A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=7Mv7/oMfZpp36BuvXTqM0r/IN8Nw4vrfpvTk+wqORtU=; b=d4s9qZVBDgWyguBkehHE80irPvUcRVG5tRA0+JV7fIYKbc9Gz5YjhjMqGWn/pQf2tn lZ0IVlNVyh3bYjkhkgypcVWKRg8zOcn9dg6goGJw90HzzCE1Wkcl/grUh1BBPwqjLP1G clPQXPukYW7wYiqjXx1sLUPxB9niiigt2x3DP4aMQZXjYYB8yz2tzH/57uKOoaBucpXe PESkhPveHRRqGmpsplKGkZH/IM6SZUN55xc05bIWiIW4PLE1FOc0OwiETMxUQzJk5kLx 10OHEYntFi3Xvk7ak1peJ6/p76T7fHJb6MHamKP8YX+EV+6QdFBck4qQXsWNLpqhHaX2 C/HA== ARC-Authentication-Results: i=1; mx.google.com; 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 v41si4126521pgn.481.2019.08.16.09.03.11; Fri, 16 Aug 2019 09:03:26 -0700 (PDT) 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; 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 S1727660AbfHPQCV (ORCPT + 99 others); Fri, 16 Aug 2019 12:02:21 -0400 Received: from eddie.linux-mips.org ([148.251.95.138]:36434 "EHLO cvs.linux-mips.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727644AbfHPQCT (ORCPT ); Fri, 16 Aug 2019 12:02:19 -0400 Received: (from localhost user: 'ladis' uid#1021 fake: STDIN (ladis@eddie.linux-mips.org)) by eddie.linux-mips.org id S23992741AbfHPQCQmL3Md (ORCPT ); Fri, 16 Aug 2019 18:02:16 +0200 Date: Fri, 16 Aug 2019 18:02:15 +0200 From: Ladislav Michl To: YueHaibing Cc: vkoul@kernel.org, sanyog.r.kale@intel.com, pierre-louis.bossart@linux.intel.com, alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org Subject: Re: [alsa-devel] [PATCH -next] soundwire: Fix -Wunused-function warning Message-ID: <20190816160215.GA6048@lenoch> References: <20190816141409.49940-1-yuehaibing@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190816141409.49940-1-yuehaibing@huawei.com> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Aug 16, 2019 at 10:14:09PM +0800, YueHaibing wrote: > If CONFIG_ACPI is not set, gcc warning this: > > drivers/soundwire/slave.c:16:12: warning: > 'sdw_slave_add' defined but not used [-Wunused-function] > > move them to #ifdef CONFIG_ACPI block. ...and that makes slave.c empty, right? So it boils down to obj-$(CONFIG_ACPI) += slave.o > Reported-by: Hulk Robot > Signed-off-by: YueHaibing > --- > drivers/soundwire/slave.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/soundwire/slave.c b/drivers/soundwire/slave.c > index f39a581..34c7e65 100644 > --- a/drivers/soundwire/slave.c > +++ b/drivers/soundwire/slave.c > @@ -6,6 +6,7 @@ > #include > #include "bus.h" > > +#if IS_ENABLED(CONFIG_ACPI) > static void sdw_slave_release(struct device *dev) > { > struct sdw_slave *slave = dev_to_sdw_dev(dev); > @@ -60,7 +61,6 @@ static int sdw_slave_add(struct sdw_bus *bus, > return ret; > } > > -#if IS_ENABLED(CONFIG_ACPI) > /* > * sdw_acpi_find_slaves() - Find Slave devices in Master ACPI node > * @bus: SDW bus instance > -- > 2.7.4 > > > _______________________________________________ > Alsa-devel mailing list > Alsa-devel@alsa-project.org > https://mailman.alsa-project.org/mailman/listinfo/alsa-devel