1. 27 Nov, 2021 12 commits
    • Tonghao Zhang's avatar
      net: ethtool: set a default driver name · bde3b0fd
      Tonghao Zhang authored
      The netdev (e.g. ifb, bareudp), which not support ethtool ops
      (e.g. .get_drvinfo), we can use the rtnl kind as a default name.
      
      ifb netdev may be created by others prefix, not ifbX.
      
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Hao Chen <chenhao288@hisilicon.com>
      Cc: Heiner Kallweit <hkallweit1@gmail.com>
      Cc: "Gustavo A. R. Silva" <gustavoars@kernel.org>
      Cc: Danielle Ratson <danieller@nvidia.com>
      Cc: Andrew Lunn <andrew@lunn.ch>
      Signed-off-by: default avatarTonghao Zhang <xiangxia.m.yue@gmail.com>
      Reviewed-by: default avatarLeon Romanovsky <leonro@nvidia.com>
      Link: https://lore.kernel.org/r/20211125163049.84970-1-xiangxia.m.yue@gmail.comSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      bde3b0fd
    • Jakub Kicinski's avatar
      Merge branch 'selftests-net-bridge-vlan-multicast-tests' · c2e0cf08
      Jakub Kicinski authored
      Nikolay Aleksandrov says:
      
      ====================
      selftests: net: bridge: vlan multicast tests
      
      This patch-set adds selftests for the new vlan multicast options that
      were recently added. Most of the tests check for default values,
      changing options and try to verify that the changes actually take
      effect. The last test checks if the dependency between vlan_filtering
      and mcast_vlan_snooping holds. The rest are pretty self-explanatory.
      
      TEST: Vlan multicast snooping enable                                [ OK ]
      TEST: Vlan global options existence                                 [ OK ]
      TEST: Vlan mcast_snooping global option default value               [ OK ]
      TEST: Vlan 10 multicast snooping control                            [ OK ]
      TEST: Vlan mcast_querier global option default value                [ OK ]
      TEST: Vlan 10 multicast querier enable                              [ OK ]
      TEST: Vlan 10 tagged IGMPv2 general query sent                      [ OK ]
      TEST: Vlan 10 tagged MLD general query sent                         [ OK ]
      TEST: Vlan mcast_igmp_version global option default value           [ OK ]
      TEST: Vlan mcast_mld_version global option default value            [ OK ]
      TEST: Vlan 10 mcast_igmp_version option changed to 3                [ OK ]
      TEST: Vlan 10 tagged IGMPv3 general query sent                      [ OK ]
      TEST: Vlan 10 mcast_mld_version option changed to 2                 [ OK ]
      TEST: Vlan 10 tagged MLDv2 general query sent                       [ OK ]
      TEST: Vlan mcast_last_member_count global option default value      [ OK ]
      TEST: Vlan mcast_last_member_interval global option default value   [ OK ]
      TEST: Vlan 10 mcast_last_member_count option changed to 3           [ OK ]
      TEST: Vlan 10 mcast_last_member_interval option changed to 200      [ OK ]
      TEST: Vlan mcast_startup_query_interval global option default value   [ OK ]
      TEST: Vlan mcast_startup_query_count global option default value    [ OK ]
      TEST: Vlan 10 mcast_startup_query_interval option changed to 100    [ OK ]
      TEST: Vlan 10 mcast_startup_query_count option changed to 3         [ OK ]
      TEST: Vlan mcast_membership_interval global option default value    [ OK ]
      TEST: Vlan 10 mcast_membership_interval option changed to 200       [ OK ]
      TEST: Vlan 10 mcast_membership_interval mdb entry expire            [ OK ]
      TEST: Vlan mcast_querier_interval global option default value       [ OK ]
      TEST: Vlan 10 mcast_querier_interval option changed to 100          [ OK ]
      TEST: Vlan 10 mcast_querier_interval expire after outside query     [ OK ]
      TEST: Vlan mcast_query_interval global option default value         [ OK ]
      TEST: Vlan 10 mcast_query_interval option changed to 200            [ OK ]
      TEST: Vlan mcast_query_response_interval global option default value   [ OK ]
      TEST: Vlan 10 mcast_query_response_interval option changed to 200   [ OK ]
      TEST: Port vlan 10 option mcast_router default value                [ OK ]
      TEST: Port vlan 10 mcast_router option changed to 2                 [ OK ]
      TEST: Flood unknown vlan multicast packets to router port only      [ OK ]
      TEST: Disable multicast vlan snooping when vlan filtering is disabled   [ OK ]
      ====================
      
      Link: https://lore.kernel.org/r/20211125140858.3639139-1-razor@blackwall.orgSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      c2e0cf08
    • Nikolay Aleksandrov's avatar
      selftests: net: bridge: add test for vlan_filtering dependency · f5a9dd58
      Nikolay Aleksandrov authored
      Add a test for dependency of mcast_vlan_snooping on vlan_filtering. If
      vlan_filtering gets disabled, then mcast_vlan_snooping must be
      automatically disabled as well.
      
      TEST: Disable multicast vlan snooping when vlan filtering is disabled   [ OK ]
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@nvidia.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      f5a9dd58
    • Nikolay Aleksandrov's avatar
      selftests: net: bridge: add vlan mcast_router tests · 2cd67a4e
      Nikolay Aleksandrov authored
      Add tests for the new per-port/vlan mcast_router option, verify that
      unknown multicast packets are flooded only to router ports.
      
      TEST: Port vlan 10 option mcast_router default value                [ OK ]
      TEST: Port vlan 10 mcast_router option changed to 2                 [ OK ]
      TEST: Flood unknown vlan multicast packets to router port only      [ OK ]
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@nvidia.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      2cd67a4e
    • Nikolay Aleksandrov's avatar
      selftests: net: bridge: add vlan mcast query and query response interval tests · b4ce7b95
      Nikolay Aleksandrov authored
      Add tests which change the new per-vlan mcast_query_interval and verify
      the new value is in effect, also add a test to change
      mcast_query_response_interval's value.
      
      TEST: Vlan mcast_query_interval global option default value         [ OK ]
      TEST: Vlan 10 mcast_query_interval option changed to 200            [ OK ]
      TEST: Vlan mcast_query_response_interval global option default value   [ OK ]
      TEST: Vlan 10 mcast_query_response_interval option changed to 200   [ OK ]
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@nvidia.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      b4ce7b95
    • Nikolay Aleksandrov's avatar
      selftests: net: bridge: add vlan mcast_querier_interval tests · 4d8610ee
      Nikolay Aleksandrov authored
      Add tests which change the new per-vlan mcast_querier_interval and
      verify that it is taken into account when an outside querier is present.
      
      TEST: Vlan mcast_querier_interval global option default value       [ OK ]
      TEST: Vlan 10 mcast_querier_interval option changed to 100          [ OK ]
      TEST: Vlan 10 mcast_querier_interval expire after outside query     [ OK ]
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@nvidia.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      4d8610ee
    • Nikolay Aleksandrov's avatar
      selftests: net: bridge: add vlan mcast_membership_interval test · a45fe974
      Nikolay Aleksandrov authored
      Add a test which changes the new per-vlan mcast_membership_interval and
      verifies that a newly learned mdb entry would expire in that interval.
      
      TEST: Vlan mcast_membership_interval global option default value    [ OK ]
      TEST: Vlan 10 mcast_membership_interval option changed to 200       [ OK ]
      TEST: Vlan 10 mcast_membership_interval mdb entry expire            [ OK ]
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@nvidia.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      a45fe974
    • Nikolay Aleksandrov's avatar
      selftests: net: bridge: add vlan mcast_startup_query_count/interval tests · bdf1b2c0
      Nikolay Aleksandrov authored
      Add tests which change the new per-vlan startup query count/interval
      options and verify the proper number of queries are sent in the expected
      interval.
      
      TEST: Vlan mcast_startup_query_interval global option default value   [ OK ]
      TEST: Vlan mcast_startup_query_count global option default value    [ OK ]
      TEST: Vlan 10 mcast_startup_query_interval option changed to 100    [ OK ]
      TEST: Vlan 10 mcast_startup_query_count option changed to 3         [ OK ]
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@nvidia.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      bdf1b2c0
    • Nikolay Aleksandrov's avatar
      selftests: net: bridge: add vlan mcast_last_member_count/interval tests · 3825f1fb
      Nikolay Aleksandrov authored
      Add tests which verify the default values of mcast_last_member_count
      mcast_last_member_count and also try to change them.
      
      TEST: Vlan mcast_last_member_count global option default value      [ OK ]
      TEST: Vlan mcast_last_member_interval global option default value   [ OK ]
      TEST: Vlan 10 mcast_last_member_count option changed to 3           [ OK ]
      TEST: Vlan 10 mcast_last_member_interval option changed to 200      [ OK ]
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@nvidia.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      3825f1fb
    • Nikolay Aleksandrov's avatar
      selftests: net: bridge: add vlan mcast igmp/mld version tests · 2b75e9dd
      Nikolay Aleksandrov authored
      Add tests which change the new per-vlan IGMP/MLD versions and verify
      that proper tagged general query packets are sent.
      
      TEST: Vlan mcast_igmp_version global option default value           [ OK ]
      TEST: Vlan mcast_mld_version global option default value            [ OK ]
      TEST: Vlan 10 mcast_igmp_version option changed to 3                [ OK ]
      TEST: Vlan 10 tagged IGMPv3 general query sent                      [ OK ]
      TEST: Vlan 10 mcast_mld_version option changed to 2                 [ OK ]
      TEST: Vlan 10 tagged MLDv2 general query sent                       [ OK ]
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@nvidia.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      2b75e9dd
    • Nikolay Aleksandrov's avatar
      selftests: net: bridge: add vlan mcast querier test · dee2cdc0
      Nikolay Aleksandrov authored
      Add a test to try the new global vlan mcast_querier control and also
      verify that tagged general query packets are properly generated when
      querier is enabled for a single vlan.
      
      TEST: Vlan mcast_querier global option default value                [ OK ]
      TEST: Vlan 10 multicast querier enable                              [ OK ]
      TEST: Vlan 10 tagged IGMPv2 general query sent                      [ OK ]
      TEST: Vlan 10 tagged MLD general query sent                         [ OK ]
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@nvidia.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      dee2cdc0
    • Nikolay Aleksandrov's avatar
      selftests: net: bridge: add vlan mcast snooping control test · 71ae450f
      Nikolay Aleksandrov authored
      Add the first test for bridge per-vlan multicast snooping which checks
      if control of the global and per-vlan options work as expected, joins
      and leaves are tested at each option value.
      
      TEST: Vlan multicast snooping enable                                [ OK ]
      TEST: Vlan global options existence                                 [ OK ]
      TEST: Vlan mcast_snooping global option default value               [ OK ]
      TEST: Vlan 10 multicast snooping control                            [ OK ]
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@nvidia.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      71ae450f
  2. 26 Nov, 2021 28 commits