aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/ti/cpsw_ale.h
diff options
context:
space:
mode:
authorGrygorii Strashko <grygorii.strashko@ti.com>2019-04-26 20:12:33 +0300
committerDavid S. Miller <davem@davemloft.net>2019-04-27 17:11:49 -0400
commit06095f34f8a0a2c4c83a19514c272699edd5f80b (patch)
treea219665d9938d1d78a876e947cf491c70fa44de4 /drivers/net/ethernet/ti/cpsw_ale.h
parentnet: ethernet: ti: ale: use define for host port in cpsw_ale_set_allmulti() (diff)
downloadlinux-dev-06095f34f8a0a2c4c83a19514c272699edd5f80b.tar.xz
linux-dev-06095f34f8a0a2c4c83a19514c272699edd5f80b.zip
net: ethernet: ti: cpsw: fix allmulti cfg in dual_mac mode
Now CPSW ALE will set/clean Host port bit in Unregistered Multicast Flood Mask (UNREG_MCAST_FLOOD_MASK) for every VLAN without checking if this port belongs to VLAN or not when ALLMULTI mode flag is set for nedev. This is working in non dual_mac mode, but in dual_mac - it causes enabling/disabling ALLMULTI flag for both ports. Hence fix it by adding additional parameter to cpsw_ale_set_allmulti() to specify ALE port number for which ALLMULTI has to be enabled and check if port belongs to VLAN before modifying UNREG_MCAST_FLOOD_MASK. Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/ti/cpsw_ale.h')
-rw-r--r--drivers/net/ethernet/ti/cpsw_ale.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/ethernet/ti/cpsw_ale.h b/drivers/net/ethernet/ti/cpsw_ale.h
index 4777d626fac8..370df254eb12 100644
--- a/drivers/net/ethernet/ti/cpsw_ale.h
+++ b/drivers/net/ethernet/ti/cpsw_ale.h
@@ -30,7 +30,6 @@ struct cpsw_ale {
struct cpsw_ale_params params;
struct timer_list timer;
unsigned long ageout;
- int allmulti;
u32 version;
/* These bits are different on NetCP NU Switch ALE */
u32 port_mask_bits;
@@ -109,7 +108,7 @@ int cpsw_ale_del_mcast(struct cpsw_ale *ale, const u8 *addr, int port_mask,
int cpsw_ale_add_vlan(struct cpsw_ale *ale, u16 vid, int port, int untag,
int reg_mcast, int unreg_mcast);
int cpsw_ale_del_vlan(struct cpsw_ale *ale, u16 vid, int port);
-void cpsw_ale_set_allmulti(struct cpsw_ale *ale, int allmulti);
+void cpsw_ale_set_allmulti(struct cpsw_ale *ale, int allmulti, int port);
int cpsw_ale_control_get(struct cpsw_ale *ale, int port, int control);
int cpsw_ale_control_set(struct cpsw_ale *ale, int port,