From patchwork Wed Oct 31 23:10:07 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sasha Levin X-Patchwork-Id: 149904 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp101619ljp; Wed, 31 Oct 2018 16:11:00 -0700 (PDT) X-Google-Smtp-Source: AJdET5eteqRZebP6XOm7vIt9Xt+Iy0sXP1MIOY9LK/WrCnmMSzRVsULNA9nPVShLVDXfEk3H0Rq4 X-Received: by 2002:a62:2fc1:: with SMTP id v184-v6mr5273315pfv.115.1541027459939; Wed, 31 Oct 2018 16:10:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1541027459; cv=none; d=google.com; s=arc-20160816; b=H0pONwgjYKo7dWohbBCRihyvVMyMFReJZMc7St3ehI2qbQsLYf4GuXHup12zsZ2csg OdEx1SyVOzzk5+yy8KqlslPMxW0lkqHWLZtnA9xO4i2ifC8LfMX46sLuHpSUrjcYc8dG 86vUjqfkwtVR8piwFFHQqIkiEsuyJ/lX1XmZiEqNgpIj1wlZ0NNiTg8ywhUFpFnehx3H ILWtHTRc3gkcC4V9utv+rjum5ER3T5UrA003GkI8mtVTWLPJEE9cxSwfsE4/TunMZnSQ LQTCvHEmceEuRCjEe1mygyld2sBPzAIBOcfBQvcHgkJ+5jqk57KBVHlb3wI98pJNCFxg nebA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature; bh=tCWbIWgiv0vkxcEKndyhxQqA2StVpvI8AsCyMy1YD2k=; b=GToOSPJphszdYrSp4IDUWF9S0zBtKwEjANQ7/DLMFV13J9+ecUrRXcsdtlPtS59K4d Lrhui8lYq0zESJumPQBVv210d6i2IwZykVSQg+4dVGqNiZ76pNjay3bOe65gfA8L8pv1 m1yLhyGyFIHdD3hQrEpwh0hLFqtynrpEE3oehauV2pdVqoWjvWDPQkfTpBsMIaH4bJwa YzJVzWdk13njGTl0hWi1OM2Ijwpzl6Pg7X55vJI8dK3HsDdfJdYi6vL3xkrwEIVb+nYp YEYnndwu8UF5u2ScSb+XfhogEjjFa4v6nCV2n6m1Q3sVYIVo3Wq8aLt0NuXkLdb4Uw9p oBUg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=jKp5rzPb; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m5-v6si2292079plt.432.2018.10.31.16.10.59; Wed, 31 Oct 2018 16:10:59 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=jKp5rzPb; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731457AbeKAILI (ORCPT + 32 others); Thu, 1 Nov 2018 04:11:08 -0400 Received: from mail.kernel.org ([198.145.29.99]:34314 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731434AbeKAILH (ORCPT ); Thu, 1 Nov 2018 04:11:07 -0400 Received: from sasha-vm.mshome.net (c-73-47-72-35.hsd1.nh.comcast.net [73.47.72.35]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 23F492064C; Wed, 31 Oct 2018 23:10:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1541027455; bh=HwzRIO/UxH9qlZtd8H+2h3nBtj+3jj9eIhPNTbiZBqM=; h=From:To:Cc:Subject:Date:From; b=jKp5rzPb7gQ7jHOVgxXVucWpxdKcTZTdhU9foyyV0WSF6T6DbqOWhi+7zjJY6cJdF KNHkU+cxzmuri3PsGq55E4l4MBzm1vU/eTdVl7yF9FaUJLdyCbujQmKhdYhAkTuk9A B9Q1xoRrd1KDoOZAVbklfRDaYIhCf5ow+2K8dNZQ= From: Sasha Levin To: stable@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Ivan Khoronzhuk , "David S . Miller" , Sasha Levin Subject: [PATCH AUTOSEL 4.9 01/48] net: ethernet: ti: cpsw: unsync mcast entries while switch promisc mode Date: Wed, 31 Oct 2018 19:10:07 -0400 Message-Id: <20181031231054.29333-1-sashal@kernel.org> X-Mailer: git-send-email 2.17.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Ivan Khoronzhuk [ Upstream commit 9737cc99dd14b5b8b9d267618a6061feade8ea68 ] After flushing all mcast entries from the table, the ones contained in mc list of ndev are not restored when promisc mode is toggled off, because they are considered as synched with ALE, thus, in order to restore them after promisc mode - reset syncing info. This fix touches only switch mode devices, including single port boards like Beagle Bone. Fixes: commit 5da1948969bc ("net: ethernet: ti: cpsw: fix lost of mcast packets while rx_mode update") Signed-off-by: Ivan Khoronzhuk Reviewed-by: Grygorii Strashko Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- drivers/net/ethernet/ti/cpsw.c | 1 + 1 file changed, 1 insertion(+) -- 2.17.1 diff --git a/drivers/net/ethernet/ti/cpsw.c b/drivers/net/ethernet/ti/cpsw.c index d7cb205fe7e2..892b06852e15 100644 --- a/drivers/net/ethernet/ti/cpsw.c +++ b/drivers/net/ethernet/ti/cpsw.c @@ -590,6 +590,7 @@ static void cpsw_set_promiscious(struct net_device *ndev, bool enable) /* Clear all mcast from ALE */ cpsw_ale_flush_multicast(ale, ALE_ALL_PORTS, -1); + __dev_mc_unsync(ndev, NULL); /* Flood All Unicast Packets to Host port */ cpsw_ale_control_set(ale, 0, ALE_P0_UNI_FLOOD, 1);