mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 08:13:54 -06:00
switch chardev to QemuOpts: infrastructure, null device
start switching chardevs to QemuOpts. This patch adds the infrastructure and converts the null device. The patch brings two new functions: qemu_chr_open_opts() same as qemu_chr_open(), but uses QemuOpts instead of a option char string. qemu_chr_parse_compat() accepts a traditional chardev option string, returns the corresponding QemuOpts instance, to handle backward compatibility. The patch also adds a new -chardev switch which can be used to create named+unconnected chardevs, like this: -chardev null,id=test This uses the new qemu_chr_open_opts. Thus with this patch alone only the null device works. The other devices will follow ... Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
parent
9d868d4517
commit
191bc01bc9
6 changed files with 93 additions and 4 deletions
|
@ -1195,6 +1195,8 @@ STEXI
|
|||
@table @option
|
||||
ETEXI
|
||||
|
||||
DEF("chardev", HAS_ARG, QEMU_OPTION_chardev, \
|
||||
"-chardev spec create unconnected chardev\n")
|
||||
DEF("serial", HAS_ARG, QEMU_OPTION_serial, \
|
||||
"-serial dev redirect the serial port to char device 'dev'\n")
|
||||
STEXI
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue