[40/56] qemu-char: Register ring buffer driver with correct name "ringbuf"

Submitted by Michael Roth on Aug. 13, 2013, 3:11 p.m.


Message ID 1376406680-16302-41-git-send-email-mdroth@linux.vnet.ibm.com
State New
Headers show

Commit Message

Michael Roth Aug. 13, 2013, 3:11 p.m.
From: Markus Armbruster <armbru@redhat.com>

The driver is new in 1.4, with the documented name "ringbuf".
However, it's actual name is the completely undocumented "memory".
Screwed up in commit 3949e59.  Fix code to match documentation.

Keep the undocumented name working as an alias for compatibility.

Cc: qemu-stable@nongnu.org
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Message-id: 1374849874-25531-3-git-send-email-armbru@redhat.com
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
(cherry picked from commit c11ed9666d69abaf217c8800f299c519b487b7d3)



* removed dependency on command-line specifiable mux (bb6fb7c0)

Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
 qemu-char.c |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/qemu-char.c b/qemu-char.c
index b8ffcba..c6c4c6b 100644
--- a/qemu-char.c
+++ b/qemu-char.c
@@ -3764,7 +3764,7 @@  static void register_types(void)
     register_char_driver_qapi("null", CHARDEV_BACKEND_KIND_NULL, NULL);
     register_char_driver("socket", qemu_chr_open_socket);
     register_char_driver("udp", qemu_chr_open_udp);
-    register_char_driver_qapi("memory", CHARDEV_BACKEND_KIND_MEMORY,
+    register_char_driver_qapi("ringbuf", CHARDEV_BACKEND_KIND_MEMORY,
     register_char_driver_qapi("file", CHARDEV_BACKEND_KIND_FILE,
@@ -3782,6 +3782,9 @@  static void register_types(void)
     register_char_driver_qapi("console", CHARDEV_BACKEND_KIND_CONSOLE, NULL);
     register_char_driver_qapi("pipe", CHARDEV_BACKEND_KIND_PIPE,
+    /* Bug-compatibility: */
+    register_char_driver_qapi("memory", CHARDEV_BACKEND_KIND_MEMORY,
+                              qemu_chr_parse_ringbuf);