From patchwork Fri Feb 10 20:21:26 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cristian Ciocaltea X-Patchwork-Id: 55572 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp1166091wrn; Fri, 10 Feb 2023 12:42:16 -0800 (PST) X-Google-Smtp-Source: AK7set/fenAUmFi1R5xf4BDCMumTfCDot0Ica3AxrGbKI6XxTKNy+gq675bFGFZQbz8wHzTMMepi X-Received: by 2002:a05:6a20:8408:b0:bc:c663:41bd with SMTP id c8-20020a056a20840800b000bcc66341bdmr20937691pzd.4.1676061736318; Fri, 10 Feb 2023 12:42:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1676061736; cv=none; d=google.com; s=arc-20160816; b=lhyjc4HtgTXaQEL99RdIj/+uGm9B58pYuVhnYG7Kuddb1EXlmRz1L4q6wPSoe6XkqQ MwlhR2X+DTVUuG5vwE5UkVe09D1JF5OHKj58UxJrnMUwX4AyIi3J6KL085nDZ01XLyfV 5eZHPS6aXJcKP3Yjt9PYwLkE5y7BT7DsRivntV1jlQnLppAifB90tINKIk8tB8dzsqu5 J84o2UrW5Htk+MY0r4wRWRW02S/oI2t4PnHYmHaXeUIBW7U3IiV/oYKA2+9K0nCOzJkx 4J/QsZWR5XT9IjbLGm+Nfc/JLT6AanPiDF9PgColy3KOUO/kS2QfdzjP7QjDbShd4wpb PsCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=umfEhRDbyNIO8HMz042Tor8o+vnw2WJJugyV+yLPpIY=; b=DYLmJgqo7RWStLCkhqBBPTfFD372uav5ZBgS/WtZ3GLGkU6qxDAiJQdNm1erHd5lZ4 nZq6nFFpV/a8MaOx2SSvLluBpUt5/J1PT+7gNZUEw8GSYrgL5GJEFvGoHo12vlok87Qo Em8ekuaBEIrrrvW+6mzUKVKTIWtxgV8kJJrodrzKA98hxfLdfnuEafqMO07XFB9H5rPZ Kg0fir55fUwpU8uUzVhS6O7sTRemqHjWCQkeGESwsi8RG0O7JlST2X7saK8v4Zu65+2h vq4TJC/srL6y6CmL8SBr5NnsRDZfM/6VLOTWOSDOKKSkvVtJ8Izc6rsH7PlZJDE3JcjF NtXg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b="E4Yjr/Xd"; 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=REJECT sp=REJECT dis=NONE) header.from=collabora.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r6-20020aa79ec6000000b0058e061e0fe7si5014023pfq.42.2023.02.10.12.42.02; Fri, 10 Feb 2023 12:42:16 -0800 (PST) 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=@collabora.com header.s=mail header.b="E4Yjr/Xd"; 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=REJECT sp=REJECT dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233790AbjBJUX7 (ORCPT + 99 others); Fri, 10 Feb 2023 15:23:59 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54538 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233676AbjBJUXn (ORCPT ); Fri, 10 Feb 2023 15:23:43 -0500 Received: from madras.collabora.co.uk (madras.collabora.co.uk [46.235.227.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 65B9DEB5A; Fri, 10 Feb 2023 12:22:58 -0800 (PST) Received: from localhost (unknown [86.120.32.152]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: cristicc) by madras.collabora.co.uk (Postfix) with ESMTPSA id 3CBC566020FD; Fri, 10 Feb 2023 20:21:33 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1676060493; bh=QMD6SyDBSnSkcWGWoE4/TS/EXFaXWOSsbB22Xw00BtU=; h=From:To:Cc:Subject:Date:From; b=E4Yjr/XdixH6Dt2xDzjvwVlTaV+Gj6wJyp7bvLWi/a4G3d56EJ3rYoLiWC1DhAwaX xLjFmYqUvI6JPm3wKSc298H8u9iryJIGXcKHMjjn7L+zSfGNsE5p0SWl06DPRxzVDp 5FRCxDplro4MG8ScpWdvAshJ48P8oi1JpuY/0XhExnokzgQYdire83Y0tt2lODmKvp WI/Wtri/KdPd2V0JnAHmDh46mT49C5XoAJiyqORbGwPIlt/novcbIkLsYtAJt1KZMO 5BRmZEI3gVn+kgixQo5TNhk4R77+XqVUrGnx4wso9u9frRcjzPzOjyYvNC555XYnaB DiKIdJ7Hade+w== From: Cristian Ciocaltea To: Giuseppe Cavallaro , Alexandre Torgue , Jose Abreu , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Maxime Coquelin , Sonic Zhang Cc: netdev@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, kernel@collabora.com Subject: [PATCH 1/1] net: stmmac: Restrict warning on disabling DMA store and fwd mode Date: Fri, 10 Feb 2023 22:21:26 +0200 Message-Id: <20230210202126.877548-1-cristian.ciocaltea@collabora.com> X-Mailer: git-send-email 2.39.1 MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,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-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1757478111223056258?= X-GMAIL-MSGID: =?utf-8?q?1757478111223056258?= When setting 'snps,force_thresh_dma_mode' DT property, the following warning is always emitted, regardless the status of force_sf_dma_mode: dwmac-starfive 10020000.ethernet: force_sf_dma_mode is ignored if force_thresh_dma_mode is set. Do not print the rather misleading message when DMA store and forward mode is already disabled. Fixes: e2a240c7d3bc ("driver:net:stmmac: Disable DMA store and forward mode if platform data force_thresh_dma_mode is set.") Signed-off-by: Cristian Ciocaltea --- drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c index eb6d9cd8e93f..0046a4ee6e64 100644 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c @@ -559,7 +559,7 @@ stmmac_probe_config_dt(struct platform_device *pdev, u8 *mac) dma_cfg->mixed_burst = of_property_read_bool(np, "snps,mixed-burst"); plat->force_thresh_dma_mode = of_property_read_bool(np, "snps,force_thresh_dma_mode"); - if (plat->force_thresh_dma_mode) { + if (plat->force_thresh_dma_mode && plat->force_sf_dma_mode) { plat->force_sf_dma_mode = 0; dev_warn(&pdev->dev, "force_sf_dma_mode is ignored if force_thresh_dma_mode is set.\n");