From nobody Sat Feb 7 19:45:23 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 74B5DC71153 for ; Tue, 29 Aug 2023 03:37:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235598AbjH2DhU convert rfc822-to-8bit (ORCPT ); Mon, 28 Aug 2023 23:37:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46560 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235597AbjH2DhH (ORCPT ); Mon, 28 Aug 2023 23:37:07 -0400 Received: from fd01.gateway.ufhost.com (fd01.gateway.ufhost.com [61.152.239.71]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 59918110 for ; Mon, 28 Aug 2023 20:37:02 -0700 (PDT) Received: from EXMBX165.cuchost.com (unknown [175.102.18.54]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "EXMBX165", Issuer "EXMBX165" (not verified)) by fd01.gateway.ufhost.com (Postfix) with ESMTP id AC0AC809C; Tue, 29 Aug 2023 11:36:59 +0800 (CST) Received: from EXMBX061.cuchost.com (172.16.6.61) by EXMBX165.cuchost.com (172.16.6.75) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Tue, 29 Aug 2023 11:36:59 +0800 Received: from localhost.localdomain (113.72.145.245) by EXMBX061.cuchost.com (172.16.6.61) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Tue, 29 Aug 2023 11:36:58 +0800 From: Xingyu Wu To: Liam Girdwood , Mark Brown CC: Claudiu Beznea , Jaroslav Kysela , Takashi Iwai , Maxim Kochetkov , Kuninori Morimoto , Walker Chen , Xingyu Wu , , Subject: [PATCH v1] ASoC: dwc: Fix the warnnings about JH7110 ops Date: Tue, 29 Aug 2023 11:36:58 +0800 Message-ID: <20230829033658.225713-1-xingyu.wu@starfivetech.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-Originating-IP: [113.72.145.245] X-ClientProxiedBy: EXCAS062.cuchost.com (172.16.6.22) To EXMBX061.cuchost.com (172.16.6.61) X-YovoleRuleAgent: yovoleflag Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Add a check of CONFIG_OF before the JH7110 ops to fix the warnings that the JH7110 ops are defined but not used when CONFIG_OF is disabled. Fixes: 1a512d13837a ("Add I2S support for the StarFive JH7110 SoC") Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202308250433.nhzrhYEo-lkp@int= el.com/ Signed-off-by: Xingyu Wu --- Hi Mark, This patch fixes the issue about the warning of JH7110 ops when CONFIG_OF is disabled. So add a check of CONFIG_OF before defining JH7110 ops. Thanks, Xingyu Wu --- sound/soc/dwc/dwc-i2s.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sound/soc/dwc/dwc-i2s.c b/sound/soc/dwc/dwc-i2s.c index 5ab1b3eb2d28..329015ef1d1e 100644 --- a/sound/soc/dwc/dwc-i2s.c +++ b/sound/soc/dwc/dwc-i2s.c @@ -729,6 +729,7 @@ static int dw_configure_dai_by_dt(struct dw_i2s_dev *de= v, =20 } =20 +#ifdef CONFIG_OF /* clocks initialization with master mode on JH7110 SoC */ static int jh7110_i2s_crg_master_init(struct dw_i2s_dev *dev) { @@ -912,6 +913,7 @@ static int jh7110_i2stx0_clk_cfg(struct i2s_clk_config_= data *config) =20 return clk_set_rate(dev->clk, bclk_rate); } +#endif =20 static int dw_i2s_probe(struct platform_device *pdev) { --=20 2.25.1