Lines Matching refs:vid
200 static void vsc9953_vlan_table_membership_set(int vid, u32 port_no, u8 add) in vsc9953_vlan_table_membership_set() argument
214 val = bitfield_replace_by_mask(val, VSC9953_ANA_TBL_VID_MASK, vid); in vsc9953_vlan_table_membership_set()
226 val = bitfield_replace_by_mask(val, VSC9953_ANA_TBL_VID_MASK, vid); in vsc9953_vlan_table_membership_set()
256 u32 vid; in vsc9953_vlan_membership_show() local
263 for (vid = 0; vid < VSC9953_MAX_VLAN; vid++) { in vsc9953_vlan_membership_show()
271 vid); in vsc9953_vlan_membership_show()
286 printf("%d ", vid); in vsc9953_vlan_membership_show()
293 static void vsc9953_vlan_table_membership_all_set(int vid, int set_member) in vsc9953_vlan_table_membership_all_set() argument
309 bitfield_replace_by_mask(val, VSC9953_ANA_TBL_VID_MASK, vid)); in vsc9953_vlan_table_membership_all_set()
321 bitfield_replace_by_mask(val, VSC9953_ANA_TBL_VID_MASK, vid)); in vsc9953_vlan_table_membership_all_set()
1126 static void vsc9953_mac_table_show(int port_no, int vid) in vsc9953_mac_table_show() argument
1161 if (vid != ETHSW_CMD_VLAN_ALL) { in vsc9953_mac_table_show()
1163 vid) | VSC9953_AGE_VID_EN; in vsc9953_mac_table_show()
1237 static int vsc9953_mac_table_add(u8 port_no, uchar mac[6], int vid) in vsc9953_mac_table_add() argument
1246 val = bitfield_replace_by_mask(val, VSC9953_MACHDATA_VID_MASK, vid) | in vsc9953_mac_table_add()
1264 val = bitfield_replace_by_mask(val, VSC9953_MACHDATA_VID_MASK, vid) | in vsc9953_mac_table_add()
1286 static int vsc9953_mac_table_del(uchar mac[6], u16 vid) in vsc9953_mac_table_del() argument
1296 val = bitfield_replace_by_mask(val, VSC9953_MACHDATA_VID_MASK, vid) | in vsc9953_mac_table_del()
1313 printf("VLAN: %d does not exist.\n", vid); in vsc9953_mac_table_del()
1319 val = bitfield_replace_by_mask(val, VSC9953_MACHDATA_VID_MASK, vid) | in vsc9953_mac_table_del()
1331 val = bitfield_replace_by_mask(val, VSC9953_MACHDATA_VID_MASK, vid) | in vsc9953_mac_table_del()
1352 static void vsc9953_mac_table_age(int port_no, int vid) in vsc9953_mac_table_age() argument
1383 if (vid != ETHSW_CMD_VLAN_ALL) { in vsc9953_mac_table_age()
1384 val = bitfield_replace_by_mask(val, VSC9953_AGE_VID_MASK, vid) | in vsc9953_mac_table_age()
1409 static void vsc9953_mac_table_flush(int port, int vid) in vsc9953_mac_table_flush() argument
1411 vsc9953_mac_table_age(port, vid); in vsc9953_mac_table_flush()
1412 vsc9953_mac_table_age(port, vid); in vsc9953_mac_table_flush()
1928 if (parsed_cmd->vid != ETHSW_CMD_VLAN_ALL && in vsc9953_fdb_show_key_func()
1929 !VSC9953_VLAN_CHECK(parsed_cmd->vid)) { in vsc9953_fdb_show_key_func()
1930 printf("Invalid VID number: %d\n", parsed_cmd->vid); in vsc9953_fdb_show_key_func()
1934 vsc9953_mac_table_show(parsed_cmd->port, parsed_cmd->vid); in vsc9953_fdb_show_key_func()
1947 if (parsed_cmd->vid != ETHSW_CMD_VLAN_ALL && in vsc9953_fdb_flush_key_func()
1948 !VSC9953_VLAN_CHECK(parsed_cmd->vid)) { in vsc9953_fdb_flush_key_func()
1949 printf("Invalid VID number: %d\n", parsed_cmd->vid); in vsc9953_fdb_flush_key_func()
1953 vsc9953_mac_table_flush(parsed_cmd->port, parsed_cmd->vid); in vsc9953_fdb_flush_key_func()
1960 int vid; in vsc9953_fdb_entry_add_key_func() local
1974 vid = (parsed_cmd->vid == ETHSW_CMD_VLAN_ALL ? 1 : parsed_cmd->vid); in vsc9953_fdb_entry_add_key_func()
1976 if (!VSC9953_VLAN_CHECK(vid)) { in vsc9953_fdb_entry_add_key_func()
1977 printf("Invalid VID number: %d\n", vid); in vsc9953_fdb_entry_add_key_func()
1981 if (vsc9953_mac_table_add(parsed_cmd->port, parsed_cmd->ethaddr, vid)) in vsc9953_fdb_entry_add_key_func()
1989 int vid; in vsc9953_fdb_entry_del_key_func() local
1992 vid = (parsed_cmd->vid == ETHSW_CMD_VLAN_ALL ? 1 : parsed_cmd->vid); in vsc9953_fdb_entry_del_key_func()
1994 if (!VSC9953_VLAN_CHECK(vid)) { in vsc9953_fdb_entry_del_key_func()
1995 printf("Invalid VID number: %d\n", vid); in vsc9953_fdb_entry_del_key_func()
1999 if (vsc9953_mac_table_del(parsed_cmd->ethaddr, vid)) in vsc9953_fdb_entry_del_key_func()
2035 if (parsed_cmd->vid == ETHSW_CMD_VLAN_ALL) { in vsc9953_pvid_set_key_func()
2040 if (!VSC9953_VLAN_CHECK(parsed_cmd->vid)) { in vsc9953_pvid_set_key_func()
2041 printf("Invalid VID number: %d\n", parsed_cmd->vid); in vsc9953_pvid_set_key_func()
2050 vsc9953_port_vlan_pvid_set(parsed_cmd->port, parsed_cmd->vid); in vsc9953_pvid_set_key_func()
2052 vsc9953_port_all_vlan_pvid_set(parsed_cmd->vid); in vsc9953_pvid_set_key_func()
2082 if (parsed_cmd->vid == ETHSW_CMD_VLAN_ALL) { in vsc9953_vlan_set_key_func()
2087 if (!VSC9953_VLAN_CHECK(parsed_cmd->vid)) { in vsc9953_vlan_set_key_func()
2088 printf("Invalid VID number: %d\n", parsed_cmd->vid); in vsc9953_vlan_set_key_func()
2107 vsc9953_vlan_table_membership_set(parsed_cmd->vid, in vsc9953_vlan_set_key_func()
2111 vsc9953_vlan_table_membership_set(parsed_cmd->vid, i, in vsc9953_vlan_set_key_func()