From patchwork Mon Aug 12 20:04:34 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sean Anderson X-Patchwork-Id: 13760996 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D6FE4C52D7C for ; Mon, 12 Aug 2024 20:08:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From: Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=2aEOu7t9R2rrRYQa/tCBbrIef976QFuVjDof5KuWorE=; b=PQ0OTQBncL2uQ6nby7ZWah4a1f XFdDJ8laCPvGQY619aEIgU9Hgj+YbHyfZBDlrlprtQaAbBHsxGrTRqVmEBvT4nOXi3GwJ2/QbOWw+ kKd+qfIXGXK1rBKkF/0iddlSZulC8UwYPFzLH31KnqzIBvZFidXQaf3PsUZIIRoWZvSZ3N5fhiImf nNTDeEKs5ghMfN+chNaKET2RpR31qOTR8tJqqNKLT/kGmzgr51qCNX6oS6gy4fYEGXpPLQR2mkVmN ocQ7Q4FA4W2WPwtH4JxgCchImV53+ZW/Za+M70xou8OP881WWGKYNbsT0UwZqetaabYHZUbZRFA92 MCWc5GPQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sdbLK-00000001Pi0-3Mc1; Mon, 12 Aug 2024 20:08:38 +0000 Received: from out-189.mta0.migadu.com ([2001:41d0:1004:224b::bd]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sdbHl-00000001OeL-3tOH for linux-arm-kernel@lists.infradead.org; Mon, 12 Aug 2024 20:04:59 +0000 X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1723493095; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=2aEOu7t9R2rrRYQa/tCBbrIef976QFuVjDof5KuWorE=; b=wuJ+bUQqmA1t8WZh2560Iy9mVSd4EB1b3t+TOK8Oap1ftO+/ZV+gTC9AzYJ4/FANBqyZkb +x92iV8nQkS63VrUuB47v1x3sBDsgi4bSElOHokJveG3ydfD7orarYxsP7+vGp2ftm2NM1 3RxgnjOUY2xkZu1vRqtC0zQ7dsPjKho= From: Sean Anderson To: Radhey Shyam Pandey , netdev@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Andrew Lunn , Michal Simek , Daniel Borkmann , Paolo Abeni , "David S . Miller" , Eric Dumazet , linux-arm-kernel@lists.infradead.org, Jakub Kicinski , Ariane Keller , Sean Anderson Subject: [PATCH net-next 1/4] net: xilinx: axienet: Always disable promiscuous mode Date: Mon, 12 Aug 2024 16:04:34 -0400 Message-Id: <20240812200437.3581990-2-sean.anderson@linux.dev> In-Reply-To: <20240812200437.3581990-1-sean.anderson@linux.dev> References: <20240812200437.3581990-1-sean.anderson@linux.dev> MIME-Version: 1.0 X-Migadu-Flow: FLOW_OUT X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240812_130458_217190_5054F32A X-CRM114-Status: UNSURE ( 9.44 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org If prmiscuous mode is disabled when there are fewer than four multicast addresses, then it will to be reflected in the hardware. Fix this by always clearing the promiscuous mode flag even when we program multicast addresses. Fixes: 8a3b7a252dca ("drivers/net/ethernet/xilinx: added Xilinx AXI Ethernet driver") Signed-off-by: Sean Anderson Reviewed-by: Simon Horman --- drivers/net/ethernet/xilinx/xilinx_axienet_main.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/net/ethernet/xilinx/xilinx_axienet_main.c b/drivers/net/ethernet/xilinx/xilinx_axienet_main.c index ca04c298daa2..e664611c29cf 100644 --- a/drivers/net/ethernet/xilinx/xilinx_axienet_main.c +++ b/drivers/net/ethernet/xilinx/xilinx_axienet_main.c @@ -451,6 +451,10 @@ static void axienet_set_multicast_list(struct net_device *ndev) } else if (!netdev_mc_empty(ndev)) { struct netdev_hw_addr *ha; + reg = axienet_ior(lp, XAE_FMI_OFFSET); + reg &= ~XAE_FMI_PM_MASK; + axienet_iow(lp, XAE_FMI_OFFSET, reg); + i = 0; netdev_for_each_mc_addr(ha, ndev) { if (i >= XAE_MULTICAST_CAM_TABLE_NUM)