Revision 0b8b716d hw/virtio-console.c
b/hw/virtio-console.c | ||
---|---|---|
11 | 11 |
*/ |
12 | 12 |
|
13 | 13 |
#include "qemu-char.h" |
14 |
#include "qemu-error.h" |
|
14 | 15 |
#include "virtio-serial.h" |
15 | 16 |
|
16 | 17 |
typedef struct VirtConsole { |
... | ... | |
113 | 114 |
{ |
114 | 115 |
VirtConsole *vcon = DO_UPCAST(VirtConsole, port, port); |
115 | 116 |
|
117 |
if (port->id == 0) { |
|
118 |
/* |
|
119 |
* Disallow a generic port at id 0, that's reserved for |
|
120 |
* console ports. |
|
121 |
*/ |
|
122 |
error_report("Port number 0 on virtio-serial devices reserved for virtconsole devices for backward compatibility."); |
|
123 |
return -1; |
|
124 |
} |
|
116 | 125 |
return generic_port_init(vcon, port); |
117 | 126 |
} |
118 | 127 |
|
Also available in: Unified diff