From: Roman Kagan <rkagan@virtuozzo.com>
To: "qemu-devel@nongnu.org" <qemu-devel@nongnu.org>
Cc: "Amit Shah" <amit@kernel.org>,
"Michael S. Tsirkin" <mst@redhat.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Fam Zheng" <fam@euphon.net>,
"Markus Armbruster" <armbru@redhat.com>,
"Andreas Färber" <afaerber@suse.de>
Subject: [Qemu-devel] [RFC PATCH 4/5] virtio: drop DEFINE_VIRTIO_COMMON_FEATURES
Date: Fri, 14 Dec 2018 16:57:08 +0000 [thread overview]
Message-ID: <20181214165657.749-5-rkagan@virtuozzo.com> (raw)
In-Reply-To: <20181214165657.749-1-rkagan@virtuozzo.com>
This macro is only used in one place so seems to be unnecessary.
Signed-off-by: Roman Kagan <rkagan@virtuozzo.com>
---
include/hw/virtio/virtio.h | 12 ------------
hw/virtio/virtio.c | 11 ++++++++++-
2 files changed, 10 insertions(+), 13 deletions(-)
diff --git a/include/hw/virtio/virtio.h b/include/hw/virtio/virtio.h
index 9c1fa07d6d..cea356efed 100644
--- a/include/hw/virtio/virtio.h
+++ b/include/hw/virtio/virtio.h
@@ -254,18 +254,6 @@ typedef struct virtio_input_conf virtio_input_conf;
typedef struct VirtIOSCSIConf VirtIOSCSIConf;
typedef struct VirtIORNGConf VirtIORNGConf;
-#define DEFINE_VIRTIO_COMMON_FEATURES(_state, _field) \
- DEFINE_PROP_BIT64("indirect_desc", _state, _field, \
- VIRTIO_RING_F_INDIRECT_DESC, true), \
- DEFINE_PROP_BIT64("event_idx", _state, _field, \
- VIRTIO_RING_F_EVENT_IDX, true), \
- DEFINE_PROP_BIT64("notify_on_empty", _state, _field, \
- VIRTIO_F_NOTIFY_ON_EMPTY, true), \
- DEFINE_PROP_BIT64("any_layout", _state, _field, \
- VIRTIO_F_ANY_LAYOUT, true), \
- DEFINE_PROP_BIT64("iommu_platform", _state, _field, \
- VIRTIO_F_IOMMU_PLATFORM, false)
-
hwaddr virtio_queue_get_desc_addr(VirtIODevice *vdev, int n);
hwaddr virtio_queue_get_avail_addr(VirtIODevice *vdev, int n);
hwaddr virtio_queue_get_used_addr(VirtIODevice *vdev, int n);
diff --git a/hw/virtio/virtio.c b/hw/virtio/virtio.c
index 22bd1ac34e..99d396c516 100644
--- a/hw/virtio/virtio.c
+++ b/hw/virtio/virtio.c
@@ -2601,7 +2601,16 @@ static void virtio_device_instance_finalize(Object *obj)
}
static Property virtio_properties[] = {
- DEFINE_VIRTIO_COMMON_FEATURES(VirtIODevice, host_features),
+ DEFINE_PROP_BIT64("indirect_desc", VirtIODevice, host_features,
+ VIRTIO_RING_F_INDIRECT_DESC, true),
+ DEFINE_PROP_BIT64("event_idx", VirtIODevice, host_features,
+ VIRTIO_RING_F_EVENT_IDX, true),
+ DEFINE_PROP_BIT64("notify_on_empty", VirtIODevice, host_features,
+ VIRTIO_F_NOTIFY_ON_EMPTY, true),
+ DEFINE_PROP_BIT64("any_layout", VirtIODevice, host_features,
+ VIRTIO_F_ANY_LAYOUT, true),
+ DEFINE_PROP_BIT64("iommu_platform", VirtIODevice, host_features,
+ VIRTIO_F_IOMMU_PLATFORM, false),
DEFINE_PROP_END_OF_LIST(),
};
--
2.19.2
next prev parent reply other threads:[~2018-12-14 16:57 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-14 16:57 [Qemu-devel] [RFC PATCH 0/5] expose negotiated virtio features in r/o properties Roman Kagan
2018-12-14 16:57 ` [Qemu-devel] [RFC PATCH 1/5] qom: preserve get/set presence in aliased properties Roman Kagan
2018-12-14 16:57 ` [Qemu-devel] [RFC PATCH 2/5] qmp: further consolidate listing of device and object properties Roman Kagan
2018-12-14 16:57 ` [Qemu-devel] [RFC PATCH 3/5] qdev-properties: add r/o 64bit bitfield property Roman Kagan
2018-12-14 16:57 ` Roman Kagan [this message]
2018-12-14 16:57 ` [Qemu-devel] [RFC PATCH 5/5] virtio: expose negotiated features in r/o properties Roman Kagan
2018-12-23 11:05 ` [Qemu-devel] [RFC PATCH 0/5] expose negotiated virtio " no-reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20181214165657.749-5-rkagan@virtuozzo.com \
--to=rkagan@virtuozzo.com \
--cc=afaerber@suse.de \
--cc=amit@kernel.org \
--cc=armbru@redhat.com \
--cc=fam@euphon.net \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).