From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796389138; b=B0qamOtrO8MOD2H+2rqpyYOxzdxmtdJvZChR7V2wFPzUnUagidA0A5U7vGrTAIdAj+Z8 Ynxk1ZvT6nadrt913FXlj8HE2yISB70dQTNlfj8Q8cDy+5BWnXCKPCi4Mcr4ngCHM7KR2 s8DTlqdbTBO988DyPIQ9iufPzZU79Xl3rK/PFcoOBxTQ8wImJ5pvG9GMeYDeoqzXkk1Ay gneA3zpZQc7kHbL8TvywXTYCWenaHRAmK/WmH8IophC/1B6WyyrDfzBYgIv/t4UgrBVLb HYwFpbaewGNyP8U1Y9OUtSntDFAEsJY5RDKZiCSZvY0yK4qjn2PtF0nreH+A2chK+Sw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796389138; h=Received:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID:X-Mailer: In-Reply-To:References:User-Agent:X-stable:X-Patchwork-Hint: MIME-Version:Content-Transfer-Encoding; bh=DqIfaREdj0GUZrTYNGnwGRjl/rKXzq7njhYPDrDTIdg=; b=faACa1asqIXfFTcyyGx6MAX+gVOSZAIGZGau+7+bAtHp5sPG8KSv5H+RpzzOgjHGo9AD /PE0/achHUxd8EG+Q5KfJvnpbXalz+XmeisdCHKnucVysPfbFTvL3AOFCJsAehLfa0/Ez jNWWMeNVszxE2ml8K/9CgzdNHGnzkPVtmCRlY2Td4Gr18Guml3tO7BJV709XPFbOpAgOX h3qxeRcSfz3tEuiEBy5pttGo/VYiQxMEbd3f5sMd7JQ09I/LLoa7pplx4Ono9I2aB9mw0 UKNXZolREpmyQOEtxEeANu/ntYVY83xvS3G+I+zJRJ1jnn2gTx+YosJMKwtysQcZEZQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=vlHhaJFh; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DF958606A33D; Fri, 4 Dec 2026 12:58:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=vlHhaJFh Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4E0371F0093A; Fri, 4 Dec 2026 12:58:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1796389138; bh=DqIfaREdj0GUZrTYNGnwGRjl/rKXzq7njhYPDrDTIdg=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=vlHhaJFhQopzxuQGmJshG5BkfpQNpejhKKIbNllKJvHaxoncOvql52ushg15/WeIr KrM5QYDFhhgD6P/geBLu1rkqPMRndIQm+pZGbXYVPiPmMfsqDlJBTlcbGQ9HQJhKtc oXMK9+uViOVlhH9tiib6mKIPaII3fzjTInmQG9rU= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Florian Fainelli , Nicolai Buchwitz , Willem de Bruijn , Sasha Levin Subject: [PATCH 6.1 0878/1059] net: systemport: accumulate the DIM packet and byte counters Date: Fri, 4 Dec 2026 19:06:49 +0900 Message-ID: <20261204100706.756588215@linuxfoundation.org> X-Mailer: git-send-email 2.56.1 In-Reply-To: <20261204100643.980430235@linuxfoundation.org> References: <20261204100643.980430235@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore X-Mailing-List: stable@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.1-stable review patch. If anyone has any objections, please let me know. ------------------ From: Nicolai Buchwitz [ Upstream commit 3e7e20beef4ec04f7601e92e78608333f2ab3904 ] net_dim() computes rates from the difference between two samples and needs running totals, but bcm_sysport_desc_rx() passes the counts of the last poll. Adaptive coalescing then picks profiles from wrong rates. Accumulate the counters instead. Fixes: b6e0e875421e ("net: systemport: Implement adaptive interrupt coalescing") Reviewed-by: Florian Fainelli Signed-off-by: Nicolai Buchwitz Signed-off-by: Willem de Bruijn Signed-off-by: Sasha Levin --- drivers/net/ethernet/broadcom/bcmsysport.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bcmsysport.c b/drivers/net/ethernet/broadcom/bcmsysport.c index 790050a93662e..20f31893ae4b2 100644 --- a/drivers/net/ethernet/broadcom/bcmsysport.c +++ b/drivers/net/ethernet/broadcom/bcmsysport.c @@ -867,8 +867,8 @@ static unsigned int bcm_sysport_desc_rx(struct bcm_sysport_priv *priv, priv->rx_read_ptr = 0; } - priv->dim.packets = processed; - priv->dim.bytes = processed_bytes; + priv->dim.packets += processed; + priv->dim.bytes += processed_bytes; return processed; } -- 2.53.0