[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v2 5/7] virtio-serial-bus: move qdev properties into
From: |
Shannon Zhao |
Subject: |
[Qemu-devel] [PATCH v2 5/7] virtio-serial-bus: move qdev properties into virtio-serial-bus.c |
Date: |
Wed, 10 Jun 2015 23:04:34 +0800 |
As only one place in virtio-serial-bus.c uses
DEFINE_VIRTIO_SERIAL_PROPERTIES, there is no need to expose it. Inline
it into virtio-serial-bus.c to avoid wrongly use.
Signed-off-by: Shannon Zhao <address@hidden>
Signed-off-by: Shannon Zhao <address@hidden>
Reviewed-by: Paolo Bonzini <address@hidden>
Acked-by: Cornelia Huck <address@hidden>
---
hw/char/virtio-serial-bus.c | 3 ++-
include/hw/virtio/virtio-serial.h | 3 ---
2 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/hw/char/virtio-serial-bus.c b/hw/char/virtio-serial-bus.c
index f893523..d451b22 100644
--- a/hw/char/virtio-serial-bus.c
+++ b/hw/char/virtio-serial-bus.c
@@ -1083,7 +1083,8 @@ static void virtio_serial_device_unrealize(DeviceState
*dev, Error **errp)
}
static Property virtio_serial_properties[] = {
- DEFINE_VIRTIO_SERIAL_PROPERTIES(VirtIOSerial, serial),
+ DEFINE_PROP_UINT32("max_ports", VirtIOSerial, serial.max_virtserial_ports,
+ 31),
DEFINE_PROP_END_OF_LIST(),
};
diff --git a/include/hw/virtio/virtio-serial.h
b/include/hw/virtio/virtio-serial.h
index 18d1bcc..527d0bf 100644
--- a/include/hw/virtio/virtio-serial.h
+++ b/include/hw/virtio/virtio-serial.h
@@ -221,7 +221,4 @@ void virtio_serial_throttle_port(VirtIOSerialPort *port,
bool throttle);
#define VIRTIO_SERIAL(obj) \
OBJECT_CHECK(VirtIOSerial, (obj), TYPE_VIRTIO_SERIAL)
-#define DEFINE_VIRTIO_SERIAL_PROPERTIES(_state, _field) \
- DEFINE_PROP_UINT32("max_ports", _state, _field.max_virtserial_ports,
31)
-
#endif
--
2.1.0
- [Qemu-devel] [PATCH v2 0/7] virtio: inline private qdev properties into virtio devices, Shannon Zhao, 2015/06/10
- [Qemu-devel] [PATCH v2 1/7] virtio-net: move qdev properties into virtio-net.c, Shannon Zhao, 2015/06/10
- [Qemu-devel] [PATCH v2 2/7] virtio-net.h: Remove unsed DEFINE_VIRTIO_NET_PROPERTIES, Shannon Zhao, 2015/06/10
- [Qemu-devel] [PATCH v2 3/7] virtio-scsi: move qdev properties into virtio-scsi.c, Shannon Zhao, 2015/06/10
- [Qemu-devel] [PATCH v2 4/7] virtio-rng: move qdev properties into virtio-rng.c, Shannon Zhao, 2015/06/10
- [Qemu-devel] [PATCH v2 5/7] virtio-serial-bus: move qdev properties into virtio-serial-bus.c,
Shannon Zhao <=
- [Qemu-devel] [PATCH v2 6/7] virtio-9p-device: move qdev properties into virtio-9p-device.c, Shannon Zhao, 2015/06/10
- [Qemu-devel] [PATCH v2 7/7] vhost-scsi: move qdev properties into vhost-scsi.c, Shannon Zhao, 2015/06/10