Skip to content
  • Kevin Wolf's avatar
    5dacda51
    vl: Enable JSON syntax for -device · 5dacda51
    Kevin Wolf authored
    
    
    Like we already do for -object, introduce support for JSON syntax in
    -device, which can be kept stable in the long term and guarantees that a
    single code path with identical behaviour is used for both QMP and the
    command line. Compared to the QemuOpts based code, the parser contains
    less surprises and has support for non-scalar options (lists and
    structs). Switching management tools to JSON means that we can more
    easily change the "human" CLI syntax from QemuOpts to the keyval parser
    later.
    
    In the QAPI schema, a feature flag is added to the device-add command to
    allow management tools to detect support for this.
    
    Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
    Reviewed-by: default avatarEric Blake <eblake@redhat.com>
    Message-Id: <20211008133442.141332-16-kwolf@redhat.com>
    Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
    Tested-by: default avatarPeter Krempa <pkrempa@redhat.com>
    Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
    5dacda51
    vl: Enable JSON syntax for -device
    Kevin Wolf authored
    
    
    Like we already do for -object, introduce support for JSON syntax in
    -device, which can be kept stable in the long term and guarantees that a
    single code path with identical behaviour is used for both QMP and the
    command line. Compared to the QemuOpts based code, the parser contains
    less surprises and has support for non-scalar options (lists and
    structs). Switching management tools to JSON means that we can more
    easily change the "human" CLI syntax from QemuOpts to the keyval parser
    later.
    
    In the QAPI schema, a feature flag is added to the device-add command to
    allow management tools to detect support for this.
    
    Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
    Reviewed-by: default avatarEric Blake <eblake@redhat.com>
    Message-Id: <20211008133442.141332-16-kwolf@redhat.com>
    Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
    Tested-by: default avatarPeter Krempa <pkrempa@redhat.com>
    Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
Loading