Enable tap mode network and vhost

This commit is contained in:
Jianfeng Jiang
2024-10-22 02:02:19 +00:00
committed by Tate, Hongliang Tian
parent 1b23182dcc
commit 7c3e3738a1
6 changed files with 56 additions and 5 deletions

16
tools/net/qemu-ifdown.sh Executable file
View File

@ -0,0 +1,16 @@
#!/bin/bash
# SPDX-License-Identifier: MPL-2.0
# Delete the TAP interface.
#
# It's used for the cleanup script of QEMU netdev, DO NOT run it manually.
if [ -n "$1" ]; then
ip link set dev "$1" down
ip link delete dev "$1"
exit
else
echo "Error: no interface specified"
exit 1
fi