File tree Expand file tree Collapse file tree 3 files changed +35
-0
lines changed Expand file tree Collapse file tree 3 files changed +35
-0
lines changed Original file line number Diff line number Diff line change 785785 </node >
786786 </children >
787787 </tagNode >
788+ <node name =" interfaces" >
789+ <properties >
790+ <help >Interfaces settings</help >
791+ </properties >
792+ <children >
793+ <leafNode name =" allow-unsupported-nics" >
794+ <properties >
795+ <help >Allow VPP to use untested NICs. This disables official support for this system</help >
796+ </properties >
797+ </leafNode >
798+ </children >
799+ </node >
788800 <node name =" ipv6" >
789801 <properties >
790802 <help >IPv6 settings</help >
Original file line number Diff line number Diff line change 2828from vyos .vpp .utils import human_memory_to_bytes , bytes_to_human_memory
2929
3030
31+ # Community-tested DPDK drivers / not officially supported by VyOS
32+ community_drivers_dpdk : list [str ] = [
33+ 'iavf' ,
34+ ]
35+
36+
3137def verify_vpp_remove_kernel_interface (config : dict ):
3238 """Common verify for removed kernel-interfaces.
3339 Verify that removed kernel interface are not used in 'vpp kernel-interfaces'.
@@ -172,6 +178,12 @@ def verify_dev_driver(iface_name: str, driver_type: str) -> bool:
172178 if driver_type == 'dpdk' :
173179 if driver in drivers_dpdk :
174180 return True
181+ if driver in community_drivers_dpdk :
182+ Warning (
183+ f"Driver '{ driver } ' on interface { iface_name } is community-supported and not tested by VyOS "
184+ f"This disables official support for this system."
185+ )
186+ return True
175187 elif driver_type == 'xdp' :
176188 if driver in drivers_xdp :
177189 return True
Original file line number Diff line number Diff line change 4444from vyos .vpp import control_host
4545from vyos .vpp .config_deps import deps_xconnect_dict
4646from vyos .vpp .config_verify import (
47+ community_drivers_dpdk ,
4748 verify_dev_driver ,
4849 verify_vpp_minimum_cpus ,
4950 verify_vpp_minimum_memory ,
@@ -549,6 +550,16 @@ def verify(config):
549550 raise ConfigError (
550551 f'Driver { iface_config ["driver" ]} is not compatible with interface { iface } !'
551552 )
553+ is_community_dpdk_driver = (
554+ iface_config ['kernel_module' ] in community_drivers_dpdk
555+ )
556+ if is_community_dpdk_driver and 'allow-unsupported-nics' not in config .get (
557+ 'settings' , {}
558+ ).get ('interfaces' , {}):
559+ raise ConfigError (
560+ f'Driver { iface_config ["driver" ]} is not compatible with interface { iface } !'
561+ )
562+
552563 if iface_config ['driver' ] == 'xdp' and 'xdp_options' in iface_config :
553564 if iface_config ['xdp_options' ]['num_rx_queues' ] != 'all' :
554565 rx_queues = iface_config ['xdp_api_params' ]['rxq_num' ]
You can’t perform that action at this time.
0 commit comments