1818from perfkitbenchmarker import errors
1919
2020DPDK_GIT_REPO = 'https://github.com/DPDK/dpdk.git'
21+ DPDK_GIT_REPO_TAG = 'v24.11'
2122DPDK_GCP_DRIVER_GIT_REPO = (
2223 'https://github.com/google/compute-virtual-ethernet-dpdk'
2324)
25+ # Head as of 2025-01-08.
26+ DPDK_GCP_DRIVER_GIT_REPO_COMMIT = '0342498eaa38e8db1cd663a99d470989fb60f803'
2427DPDK_AWS_DRIVER_GIT_REPO = 'https://github.com/amzn/amzn-drivers'
28+ DPDK_AWS_DRIVER_GIT_REPO_TAG = 'ena_linux_2.13.2'
2529DPDK_AWS_VFIO_DRIVER_DIR = 'amzn-drivers/userspace/dpdk/enav2-vfio-patch'
2630
2731
2832def _Install (vm ):
2933 """Install DPDK after installing dependencies and applying patches."""
3034 vm .Install ('pip' )
3135 vm .RobustRemoteCommand (f'git clone { DPDK_GIT_REPO } ' )
36+ vm .RobustRemoteCommand (f'cd dpdk && git checkout { DPDK_GIT_REPO_TAG } ' )
3237 if vm .CLOUD == 'GCP' :
3338 # Get out of tree driver
3439 vm .RobustRemoteCommand (f'git clone { DPDK_GCP_DRIVER_GIT_REPO } ' )
40+ vm .RobustRemoteCommand (
41+ 'cd compute-virtual-ethernet-dpdk && git checkout'
42+ f' { DPDK_GCP_DRIVER_GIT_REPO_COMMIT } '
43+ )
3544 vm .RemoteCommand (
3645 'cp -r compute-virtual-ethernet-dpdk/* dpdk/drivers/net/gve'
3746 )
@@ -71,6 +80,9 @@ def AptInstall(vm):
7180 vm .RemoteCommand ('sudo update-grub' )
7281 vm .Reboot ()
7382 vm .RemoteCommand (f'git clone { DPDK_AWS_DRIVER_GIT_REPO } ' )
83+ vm .RemoteCommand (
84+ f'cd amzn-drivers && git checkout { DPDK_AWS_DRIVER_GIT_REPO_TAG } '
85+ )
7486 vm .RemoteCommand (
7587 'sudo sed -i "s/# deb-src/deb-src/g" /etc/apt/sources.list'
7688 )
@@ -92,6 +104,9 @@ def YumInstall(vm):
92104 vm .RemoteCommand ('sudo pip3 install meson ninja pyelftools' )
93105 if vm .CLOUD == 'AWS' :
94106 vm .RemoteCommand (f'git clone { DPDK_AWS_DRIVER_GIT_REPO } ' )
107+ vm .RemoteCommand (
108+ f'cd amzn-drivers && git checkout { DPDK_AWS_DRIVER_GIT_REPO_TAG } '
109+ )
95110 vm .RemoteCommand (
96111 'sudo sed -i "s/linux-image-unsigned-/linux-image-/g"'
97112 f' { DPDK_AWS_VFIO_DRIVER_DIR } /get-vfio-with-wc.sh'
0 commit comments