Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp1459177pxb; Thu, 14 Apr 2022 06:45:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzVExXvjilCERSW+9wiO6MniPr99u0T5kZMnLjchhoFyq0lMyzbK0cYuLBE36PJ6c2ww0Le X-Received: by 2002:a17:90a:ff17:b0:1cb:a182:9b05 with SMTP id ce23-20020a17090aff1700b001cba1829b05mr3828886pjb.1.1649943918606; Thu, 14 Apr 2022 06:45:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649943918; cv=none; d=google.com; s=arc-20160816; b=fNCgzU5z9e2mG0Jrw6tDDCaxn1ehujcadKDyuqmSQi2gMO5Ql2JdIYNFqWGqBGsr40 bVZutg86FCV8+EgPg5Ico/6Qyt58aUuCE6aJjQ8/3frUHL4dPkVEHlH+Uxt/usrBaRKw GSKfpzgIusdPlfw0XvPzc58JEgW9vWLy66EEFbzFjDeTLdcPkv9Ujc6MhXBPCtRCtKCg LVmdEb6anDIoC+iieJJX/Q3BWu893blj19FxVVeEyODHvT66KI3wmN5kU17S44EBS8nL wpreX9UDsJBxyfuoKMHNcnayiP80oWX7ynf0XhVjrcDT0LA1kh6zwXo1JJlbGtnKDOfN Oy2Q== 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=Kf3xjl8BrBTKoBEu0VHViWW2bRtYjZmKOwW94FdVGl4=; b=lSDPELwaOYcv6QKKHcg7qwZTdfikefc4S/KKT9x2Gtsrqj+4eWhxQaUz2a4H2gC/H+ dm2qmTjsTfVCFIiLWoAdQ0Q7XnC2wQom6EHi0cQZ2BZMfZMT6pJwzhLNz7dPDOpzJ34l Jozjk1+1dnX2ay4HvhoKsACLeF13b33kr/NmYT0DsxSElCRWkQVrZyOxHazqTuzuqZBd Vk5UYvZYbeAEojdXehGUeeiGWqI+wCGAJiECx/oLeparo1NGRbYROpSRueEeHwwgu4LB K+LZogjZEuGJZoyWy8h8JCZ10ochEQqQ8YrYBRnuaSep09+bOhv8ivrigT58nCow+qnw hPIg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=YG04xhPZ; 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 g2-20020a056a0023c200b004fa3a8e002asi18688173pfc.225.2022.04.14.06.45.00; Thu, 14 Apr 2022 06:45:18 -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=YG04xhPZ; 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 S240795AbiDNIZQ (ORCPT + 99 others); Thu, 14 Apr 2022 04:25:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33564 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232646AbiDNIZL (ORCPT ); Thu, 14 Apr 2022 04:25:11 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8C9B85F250 for ; Thu, 14 Apr 2022 01:22:47 -0700 (PDT) Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out1.suse.de (Postfix) with ESMTP id 2B04D21618; Thu, 14 Apr 2022 08:22:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1649924566; 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=Kf3xjl8BrBTKoBEu0VHViWW2bRtYjZmKOwW94FdVGl4=; b=YG04xhPZFFb6cki2AIm2z59dtlpDfhUKNVmJZtW3TMVbAurFZlh7k/LujsHpphCNYOR+d0 j+9hNXH1GiyjpKs8t3BsCMRdhECCsr59rrOEz4wIXxj/a2Qpx/pDaOybpm3f3pUbFr64SI qJSBcbuH59IlmhRXdkONArlcBtG1kLk= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1649924566; 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=Kf3xjl8BrBTKoBEu0VHViWW2bRtYjZmKOwW94FdVGl4=; b=hQ+/dbdyVTyV5bsMi5SqXnDGhNLfy8rUlq/T63z59AN+DRZnTAn5jIziZf77zHq+Y6l+ey RG/kw661SaWR5uCg== Received: from alsa1.suse.de (alsa1.suse.de [10.160.4.42]) by relay2.suse.de (Postfix) with ESMTP id 163CDA3B87; Thu, 14 Apr 2022 08:22:46 +0000 (UTC) Date: Thu, 14 Apr 2022 10:22:46 +0200 Message-ID: From: Takashi Iwai To: Miles Chen Cc: Jaroslav Kysela , Takashi Iwai , Matthias Brugger , , , , , Randy Dunlap Subject: Re: [PATCH -next] sound/oss/dmasound: fix 'dmasound_setup' defined but not used In-Reply-To: <20220414081119.30851-1-miles.chen@mediatek.com> References: <20220414081119.30851-1-miles.chen@mediatek.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 Emacs/25.3 (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 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 Thu, 14 Apr 2022 10:11:18 +0200, Miles Chen wrote: > > We observed: 'dmasound_setup' defined but not used error with > COMPILER=gcc ARCH=m68k DEFCONFIG=allmodconfig build. > > __setup() does not work if MODULE is defined. > Fix it by warpping dmasound_setup with #ifndef MODULES. > > Error(s): > sound/oss/dmasound/dmasound_core.c:1431:12: error: 'dmasound_setup' defined but not used [-Werror=unused-function] > > Signed-off-by: Miles Chen This must be a side-effect of the recent fix 9dd7c46346ca ("sound/oss/dmasound: fix build when drivers are mixed =y/=m"). Adding Randy to Cc. IMO, a less uglier way would be to add __maybe_unused to that function. But it's a matter of taste. thanks, Takashi > --- > sound/oss/dmasound/dmasound_core.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/sound/oss/dmasound/dmasound_core.c b/sound/oss/dmasound/dmasound_core.c > index 9c48f3a9e3d1..a1b3e71beadf 100644 > --- a/sound/oss/dmasound/dmasound_core.c > +++ b/sound/oss/dmasound/dmasound_core.c > @@ -1428,6 +1428,7 @@ void dmasound_deinit(void) > unregister_sound_dsp(sq_unit); > } > > +#ifndef MODULE > static int dmasound_setup(char *str) > { > int ints[6], size; > @@ -1470,6 +1471,7 @@ static int dmasound_setup(char *str) > } > > __setup("dmasound=", dmasound_setup); > +#endif > > /* > * Conversion tables > -- > 2.18.0 >