On Thu, Sep 15, 2016 at 18:14:29 +0200, Martin Kletzander wrote: > Just the default one now, new ones will be added in following commits. > > Signed-off-by: Martin Kletzander <mkletzan@xxxxxxxxxx> > --- > docs/schemas/domaincommon.rng | 9 +++++ > src/conf/domain_conf.c | 41 +++++++++++++++++------ > src/conf/domain_conf.h | 8 +++++ > src/libvirt_private.syms | 2 ++ > src/qemu/qemu_command.c | 14 ++++++-- > tests/qemuxml2argvdata/qemuxml2argv-shmem.xml | 2 ++ > tests/qemuxml2xmloutdata/qemuxml2xmlout-shmem.xml | 8 +++++ > 7 files changed, 70 insertions(+), 14 deletions(-) [...] > diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c > index 3a61863b9abb..5eae0631a14f 100644 > --- a/src/qemu/qemu_command.c > +++ b/src/qemu/qemu_command.c > @@ -8648,10 +8648,18 @@ qemuBuildShmemCommandLine(virLogManagerPtr logManager, > { > char *devstr = NULL; > > - if (!(devstr = qemuBuildShmemDevStr(def, shmem, qemuCaps))) > + switch ((virDomainShmemModel)shmem->model) { > + case VIR_DOMAIN_SHMEM_MODEL_IVSHMEM: > + if (!(devstr = qemuBuildShmemDevStr(def, shmem, qemuCaps))) > + return -1; > + virCommandAddArgList(cmd, "-device", devstr, NULL); > + VIR_FREE(devstr); > + break; > + > + /* coverity[dead_error_begin] */ I'd don't really like stuff like this. > + case VIR_DOMAIN_SHMEM_MODEL_LAST: > return -1; > - virCommandAddArgList(cmd, "-device", devstr, NULL); > - VIR_FREE(devstr); > + } > > if (shmem->server.enabled) { > if (!(devstr = qemuBuildShmemBackendStr(logManager, cmd, cfg, def, ACK nevertheless. Peter -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list