aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/drivers/net/ethernet/ti/cpsw_ale.h
diff options
context:
space:
mode:
authorIlias Apalodimas <ilias.apalodimas@linaro.org>2019-11-20 00:19:15 +0200
committerDavid S. Miller <davem@davemloft.net>2019-11-20 11:25:23 -0800
commite85c14370783bf9339a95cab9da0fa54dc770a72 (patch)
treeb5a910ef3c61112fb3133f2fca0c1de7a4c154ad /drivers/net/ethernet/ti/cpsw_ale.h
parentnet: ethernet: ti: cpsw: allow untagged traffic on host port (diff)
downloadwireguard-linux-e85c14370783bf9339a95cab9da0fa54dc770a72.tar.xz
wireguard-linux-e85c14370783bf9339a95cab9da0fa54dc770a72.zip
net: ethernet: ti: ale: modify vlan/mdb api for switchdev
A following patch introduces switchdev functionality, so modify ALE engine VLANs/MDBs API: - cpsw_ale_del_mcast(): update so it will remove only selected ports from mcast port_mask or delete whole mcast record if !port_mask - cpsw_ale_del_vlan(): update so it will remove only selected ports from all VLAN record's masks or delete whole VLAN record if !port_mask - add cpsw_ale_vlan_add_modify() to add or modify existing VLAN record's masks - add cpsw_ale_set_unreg_mcast() for enabling unreg mcast on port VLANs Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org> 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.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/ethernet/ti/cpsw_ale.h b/drivers/net/ethernet/ti/cpsw_ale.h
index 93d6d56d12f4..70d0955c2652 100644
--- a/drivers/net/ethernet/ti/cpsw_ale.h
+++ b/drivers/net/ethernet/ti/cpsw_ale.h
@@ -120,4 +120,10 @@ static inline int cpsw_ale_get_vlan_p0_untag(struct cpsw_ale *ale, u16 vid)
{
return test_bit(vid, ale->p0_untag_vid_mask);
}
+
+int cpsw_ale_vlan_add_modify(struct cpsw_ale *ale, u16 vid, int port_mask,
+ int untag_mask, int reg_mcast, int unreg_mcast);
+void cpsw_ale_set_unreg_mcast(struct cpsw_ale *ale, int unreg_mcast_mask,
+ bool add);
+
#endif