From patchwork Wed Feb 28 14:03:10 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 207876 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:a81b:b0:108:e6aa:91d0 with SMTP id bq27csp3365228dyb; Wed, 28 Feb 2024 06:04:37 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCXxfuxl4qBgf3/Jw7zDLGa1cDf0FITY0nz1dr40YFQYjKgWyML4sZQlFEqHmTbLrw54M2fxlmP+9SLbGFGQT/SYbnmH8w== X-Google-Smtp-Source: AGHT+IES29/hFDq30tTiHwl1AOmPZTnIjvYcdQSmPdToNz1gRCXw2vQmQJQ/pFvbItnHDoh7hPBk X-Received: by 2002:a17:906:260d:b0:a3e:5cb9:8a4f with SMTP id h13-20020a170906260d00b00a3e5cb98a4fmr10042850ejc.58.1709129076929; Wed, 28 Feb 2024 06:04:36 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709129076; cv=pass; d=google.com; s=arc-20160816; b=kkFA4SoLkwQB0UlvoDFXgfhYQTc0RmVNEB1dGmS7wd9r4tuxnwSzwBLtYI/iiEanEe PPoT10sl5B811ELPsKIhb/lIMpv9ERJjDb1YXLX3P+PYrmbMvLHwRGfbKDXCpsBfe2am gEL4MzitHaAEzVtETEgzS8aAx3jE0cSiY8A7Kv2LziRbcElDe6w4b54+ZJ6y2mIbnu2L KTZJsbI58ipQ7hTfjENplXnXFwZl9qnTCQbZIosVILcN9fr0fMjpJHKgeei9tArYHvxN VY8RH1Mvago+OiIS0wSNWTKYhcuvFQdnvjHgNHYuVjZjSkZ7iQC4+53RQR3FgdRfwAHW SMaQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=ItJ/3+G/r2T0Bov+Ij90PkYOw7BLy5VkHUT/9UlPYsg=; fh=a8QzMriWbEtO35lyeGR2B6NU2+WX4D/+TrWBheZwsaE=; b=c18ZvNX+WqIQBibPT+9CCb0XC7BqZwdshTk7G8+WOO+ShJ9FAC35xAvpUnn3agzX1Z X7M+/cCaogJIE/xRe4BImfVywTQoW4hSSDdKVMyYT/pzZR1TubOWRrJfyPACk9TsmHeC m1olAu2uWKJJ7m4WDjCya8MFExjPnfrAookasLxUXcGuMWwdUcIqW0ehdMjlhYCma9af Bv7TXxOX8SWMkziCchPdzPqXewukDUoGAHw4Sa9skvm2fkdpCcSnj6DlMfPnz22x//m1 aPIRDnkIvJ9e6THYR75ASF1YMiJL/1BjMQfkWxz1zUysrWEMjwt8ytQ8pevdNb+C2gJX nYZw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=YCFN+cZr; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-85153-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-85153-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id u11-20020a17090617cb00b00a42f801a5b5si1788317eje.920.2024.02.28.06.04.36 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Feb 2024 06:04:36 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-85153-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=YCFN+cZr; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-85153-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-85153-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 8AAD51F23E52 for ; Wed, 28 Feb 2024 14:04:36 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8418E156961; Wed, 28 Feb 2024 14:04:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="YCFN+cZr" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DC6FF73519; Wed, 28 Feb 2024 14:04:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709129060; cv=none; b=CtTsr8k9bYdacoitHZpeSiBbHlfY4l1HqY39LB/SHJPYiElTeFNiBGc9qjjEFUfYIKEIwx/ctyl2bZNX1zRmCbgeVYZiazHqz23WHNH+wPLa6xB5pxFpyUfIodlarAMoeG8Ptp+JWmAoiVt51mr3mre6V5RPj9XPCZ3u9QLTLds= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709129060; c=relaxed/simple; bh=5ZN5lb9qZh+wr9R+euAaAWQtDY1Ld9pqoFz7FSR7nU4=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=bSSYhR0715qTp3tD/JM4m4cnSw8vK6dkDlXBd0I9hcoukkfLEFbMQzD4/Gxu0k3HAn9hQX4EfYnaK9b2I3C+/k8fSFIRCFlfWApxi4uO0cRmMRWELq0Y2nnDcGTD2BSU+oMPkCu0kKKHEsTi/DHmpoqEOdnPT5t5Dj608uxz9Os= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=YCFN+cZr; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id C2803C433F1; Wed, 28 Feb 2024 14:04:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1709129059; bh=5ZN5lb9qZh+wr9R+euAaAWQtDY1Ld9pqoFz7FSR7nU4=; h=From:To:Cc:Subject:Date:From; b=YCFN+cZrz77OSYi3x49AK08LMrEZTz1xtiWB12Kz3FE7haRPxCTQL5LArbfAgRCwq pkc38JPw97vWJ/Ss5MDO7rynTPqLcae8421fO+1apsLr4p3jJzOZ9h8n2eauIAGgmL kDDvEcuDe9+WU8kDT0orjDmylaAwLEXOxNsw8iXsXna3/ttxD2yY2TywkWg/jb0qSt nalk09LUf/Q1Y5+ZBreRv07wkrxo8y5ypvOMiwQFbNFGuQ514/+rLwF4MRuz5owzFe Cv1VLVu1+EL2w8DQnylxiG3Do8GLHp5QLN8Ks3BWS6aiE1yr4QmPWK3al8KxhNsgRp BML2iZ2MeCidA== From: Arnd Bergmann To: "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Breno Leitao Cc: Arnd Bergmann , Roger Quadros , Siddharth Vadapalli , Grygorii Strashko , Dan Carpenter , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] net: ethernet: ti: am65-cpsw-qos: fix non-bql configs Date: Wed, 28 Feb 2024 15:03:10 +0100 Message-Id: <20240228140413.1862310-1-arnd@kernel.org> X-Mailer: git-send-email 2.39.2 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1792151730953850899 X-GMAIL-MSGID: 1792151730953850899 From: Arnd Bergmann It is now possible to disable BQL, but that causes cpsw to break: drivers/net/ethernet/ti/am65-cpsw-nuss.c:297:28: error: no member named 'dql' in 'struct netdev_queue' 297 | dql_avail(&netif_txq->dql), Add an #ifdef check for CONFIG_BQL around this usage. Fixes: ea7f3cfaa588 ("net: bql: allow the config to be disabled") Signed-off-by: Arnd Bergmann --- drivers/net/ethernet/ti/am65-cpsw-nuss.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/net/ethernet/ti/am65-cpsw-nuss.c b/drivers/net/ethernet/ti/am65-cpsw-nuss.c index 9d2f4ac783e4..3a3ec9959ee2 100644 --- a/drivers/net/ethernet/ti/am65-cpsw-nuss.c +++ b/drivers/net/ethernet/ti/am65-cpsw-nuss.c @@ -294,7 +294,11 @@ static void am65_cpsw_nuss_ndo_host_tx_timeout(struct net_device *ndev, txqueue, netif_tx_queue_stopped(netif_txq), jiffies_to_msecs(jiffies - trans_start), +#ifdef CONFIG_BQL dql_avail(&netif_txq->dql), +#else + 0, +#endif k3_cppi_desc_pool_avail(tx_chn->desc_pool)); if (netif_tx_queue_stopped(netif_txq)) {