Skip to content

Commit

Permalink
Disable net emulation when net.model==none
Browse files Browse the repository at this point in the history
when net.model==none, there should no net emulation.

Tracked-On: OAM-105246
Signed-off-by: Yadong Qi <yadong.qi@intel.com>
  • Loading branch information
YadongQi authored and sysopenci committed Dec 13, 2022
1 parent efefbbd commit 4ba2371
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/guest/vm_builder_qemu.cc
Original file line number Diff line number Diff line change
Expand Up @@ -573,6 +573,9 @@ void VmBuilderQemu::BuildNetCmd(void) {
if (model.empty())
model = "e1000";

if (model.compare("none") == 0)
return;

std::string net_arg = " -netdev user,id=net0";
std::string adb_port = cfg_.GetValue(kGroupNet, kNetAdbPort);
if (!adb_port.empty())
Expand Down

0 comments on commit 4ba2371

Please sign in to comment.