Skip to content
This repository has been archived by the owner on Jan 20, 2022. It is now read-only.

Commit

Permalink
Merge 6924d7c into 065d1d2
Browse files Browse the repository at this point in the history
  • Loading branch information
Julio Montes committed Feb 12, 2018
2 parents 065d1d2 + 6924d7c commit 102aeef
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions qemu/qemu.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ type Machine struct {

// Acceleration are the machine acceleration options to be used by qemu.
Acceleration string

// ExtraOptions are extra options for the machine type
// For example gic-version=host and usb=off
ExtraOptions string
}

// Device is the qemu device interface.
Expand Down Expand Up @@ -1240,6 +1244,10 @@ func (config *Config) appendMachine() {
machineParams = append(machineParams, fmt.Sprintf(",accel=%s", config.Machine.Acceleration))
}

if config.Machine.ExtraOptions != "" {
machineParams = append(machineParams, fmt.Sprintf(",%s", config.Machine.ExtraOptions))
}

config.qemuParams = append(config.qemuParams, "-machine")
config.qemuParams = append(config.qemuParams, strings.Join(machineParams, ""))
}
Expand Down

0 comments on commit 102aeef

Please sign in to comment.