From: "Dr. David Alan Gilbert (git)" <dgilbert@redhat.com>
To: virtualization@lists.linux-foundation.org, mst@redhat.com,
jasowang@redhat.com
Cc: sebastien.boeuf@intel.com, vgoyal@redhat.com, stefanha@redhat.com
Subject: [PATCH 1/4] virtio_pci: Define id field
Date: Thu, 25 Jul 2019 18:50:41 +0100 [thread overview]
Message-ID: <20190725175044.29303-2-dgilbert@redhat.com> (raw)
In-Reply-To: <20190725175044.29303-1-dgilbert@redhat.com>
From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
The new virtio-shared memory region system allows multiple regions
to be defined for a device; each of these is the same type of
capability.
To allow multiple capabilities of the same type, create
an 'id' field to differentiate them.
Defined in virtio spec commit 39dfc8afc0b93 ("pci: Define id field")
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
---
include/uapi/linux/virtio_pci.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/include/uapi/linux/virtio_pci.h b/include/uapi/linux/virtio_pci.h
index 90007a1abcab..9defe4a124c5 100644
--- a/include/uapi/linux/virtio_pci.h
+++ b/include/uapi/linux/virtio_pci.h
@@ -121,7 +121,8 @@ struct virtio_pci_cap {
__u8 cap_len; /* Generic PCI field: capability length */
__u8 cfg_type; /* Identifies the structure. */
__u8 bar; /* Where to find it. */
- __u8 padding[3]; /* Pad to full dword. */
+ __u8 id; /* Multiple capabilities of the same type */
+ __u8 padding[2]; /* Pad to full dword. */
__le32 offset; /* Offset within bar. */
__le32 length; /* Length of the structure, in bytes. */
};
--
2.21.0
next prev parent reply other threads:[~2019-07-25 17:50 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-25 17:50 [PATCH 0/4] virtio: Add definitions for shared memory regions Dr. David Alan Gilbert (git)
2019-07-25 17:50 ` Dr. David Alan Gilbert (git) [this message]
2019-07-25 17:50 ` [PATCH 2/4] virtio_pci: Define virtio_pci_cap64 Dr. David Alan Gilbert (git)
2019-07-25 17:50 ` [PATCH 3/4] virtio_pci: Defined shared memory capability Dr. David Alan Gilbert (git)
2019-07-25 17:50 ` [PATCH 4/4] virito_mmio: Define shared memory region registers Dr. David Alan Gilbert (git)
2019-08-07 13:20 ` [PATCH 0/4] virtio: Add definitions for shared memory regions Stefan Hajnoczi
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=20190725175044.29303-2-dgilbert@redhat.com \
--to=dgilbert@redhat.com \
--cc=jasowang@redhat.com \
--cc=mst@redhat.com \
--cc=sebastien.boeuf@intel.com \
--cc=stefanha@redhat.com \
--cc=vgoyal@redhat.com \
--cc=virtualization@lists.linux-foundation.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).