From: Halil Pasic <pasic@linux.vnet.ibm.com>
To: Stefan Hajnoczi <stefanha@redhat.com>, Gonglei <arei.gonglei@huawei.com>
Cc: qemu-devel@nongnu.org, virtio-dev@lists.oasis-open.org,
luonengjun@huawei.com, mst@redhat.com, cornelia.huck@de.ibm.com,
denglingli@chinamobile.com, Jani.Kokkonen@huawei.com,
Ola.Liljedahl@arm.com, Varun.Sethi@freescale.com,
xin.zeng@intel.com, brian.a.keating@intel.com,
liang.j.ma@intel.com, john.griffin@intel.com,
weidong.huang@huawei.com, mike.caraman@nxp.com, agraf@suse.de,
jasowang@redhat.com, nmorey@kalray.eu, vincent.jardin@6wind.com,
wu.wubin@huawei.com, arei.gonglei@hotmail.com,
linqiangmin@huawei.com, zhbzg@huawei.com, eety.chen@huawei.com,
amy.zhanghuimin@huawei.com, lixiao91@huawei.com
Subject: Re: [Qemu-devel] [virtio-dev] [PATCH v18 1/2] virtio-crypto: Add virtio crypto device specification
Date: Wed, 17 May 2017 00:40:38 +0200 [thread overview]
Message-ID: <300c670c-6116-2882-17a6-f39f9008efd8@linux.vnet.ibm.com> (raw)
In-Reply-To: <20170516153348.GR8498@stefanha-x1.localdomain>
[-- Attachment #1: Type: text/plain, Size: 1782 bytes --]
On 05/16/2017 05:33 PM, Stefan Hajnoczi wrote:
> On Sat, Apr 22, 2017 at 02:23:50PM +0800, Gonglei wrote:
>> +Dataq requests for both session and stateless modes are as follows:
>> +
>> +\begin{lstlisting}
>> +struct virtio_crypto_op_data_req_mux {
>> + struct virtio_crypto_op_header header;
>> +
>> + union {
>> + struct virtio_crypto_sym_data_req sym_req;
>> + struct virtio_crypto_hash_data_req hash_req;
>> + struct virtio_crypto_mac_data_req mac_req;
>> + struct virtio_crypto_aead_data_req aead_req;
>> + struct virtio_crypto_sym_data_req_stateless sym_stateless_req;
>> + struct virtio_crypto_hash_data_req_stateless hash_stateless_req;
>> + struct virtio_crypto_mac_data_req_stateless mac_stateless_req;
>> + struct virtio_crypto_aead_data_req_stateless aead_stateless_req;
>> + } u;
>> +};
>> +\end{lstlisting}
>
> Halil touched on this in the discussion: this spec uses a C-like struct
> syntax but does not define whether unions really affect sizeof(mystruct)
> like they would in C or whether you just mean that any of the union
> fields can be used. This distinction is important so device and driver
> authors understand the exact memory layout of requests and responses.
>
> Please include an explanation about the meaning of "union" in the text.
>
I do not think simple explaining the union will do. I think this
description is bleeding from more wounds. I tried to explain this
while reviewing the implementation here:
https://lists.gnu.org/archive/html/qemu-devel/2017-05/msg03876.html
Unfortunately some technical issues precluded me from posting it
in a timely manner.
@Stefan: Thanks for joining the discussion.
Regards,
Halil
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2017-05-16 22:41 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-22 6:23 [Qemu-devel] [PATCH v18 0/2] virtio-crypto: virtio crypto device specification Gonglei
2017-04-22 6:23 ` [Qemu-devel] [PATCH v18 1/2] virtio-crypto: Add " Gonglei
2017-05-03 17:11 ` Halil Pasic
2017-05-04 13:33 ` Gonglei (Arei)
2017-05-04 13:55 ` Halil Pasic
2017-05-04 14:13 ` Gonglei (Arei)
2017-05-04 16:10 ` Halil Pasic
2017-05-05 3:39 ` Gonglei (Arei)
2017-05-05 13:52 ` [Qemu-devel] [virtio-dev] " Halil Pasic
2017-05-06 1:30 ` Gonglei (Arei)
2017-05-04 17:32 ` Halil Pasic
2017-05-04 13:53 ` [Qemu-devel] " Gonglei (Arei)
2017-05-04 16:19 ` [Qemu-devel] [virtio-dev] " Halil Pasic
2017-05-05 5:56 ` Gonglei (Arei)
2017-05-05 14:32 ` Halil Pasic
2017-05-06 1:50 ` Gonglei (Arei)
2017-05-10 18:02 ` [Qemu-devel] " Halil Pasic
2017-05-15 17:02 ` [Qemu-devel] [virtio-dev] " Halil Pasic
2017-05-16 3:48 ` [Qemu-devel] " Gonglei (Arei)
2017-05-16 11:00 ` Halil Pasic
2017-05-16 15:33 ` [Qemu-devel] [virtio-dev] " Stefan Hajnoczi
2017-05-16 22:40 ` Halil Pasic [this message]
2017-05-17 9:18 ` Gonglei (Arei)
2017-04-22 6:23 ` [Qemu-devel] [PATCH v18 2/2] virtio-crypto: Add conformance clauses Gonglei
2017-05-02 21:55 ` [Qemu-devel] [virtio-dev] [PATCH v18 0/2] virtio-crypto: virtio crypto device specification Halil Pasic
2017-05-03 6:29 ` Gonglei (Arei)
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=300c670c-6116-2882-17a6-f39f9008efd8@linux.vnet.ibm.com \
--to=pasic@linux.vnet.ibm.com \
--cc=Jani.Kokkonen@huawei.com \
--cc=Ola.Liljedahl@arm.com \
--cc=Varun.Sethi@freescale.com \
--cc=agraf@suse.de \
--cc=amy.zhanghuimin@huawei.com \
--cc=arei.gonglei@hotmail.com \
--cc=arei.gonglei@huawei.com \
--cc=brian.a.keating@intel.com \
--cc=cornelia.huck@de.ibm.com \
--cc=denglingli@chinamobile.com \
--cc=eety.chen@huawei.com \
--cc=jasowang@redhat.com \
--cc=john.griffin@intel.com \
--cc=liang.j.ma@intel.com \
--cc=linqiangmin@huawei.com \
--cc=lixiao91@huawei.com \
--cc=luonengjun@huawei.com \
--cc=mike.caraman@nxp.com \
--cc=mst@redhat.com \
--cc=nmorey@kalray.eu \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@redhat.com \
--cc=vincent.jardin@6wind.com \
--cc=virtio-dev@lists.oasis-open.org \
--cc=weidong.huang@huawei.com \
--cc=wu.wubin@huawei.com \
--cc=xin.zeng@intel.com \
--cc=zhbzg@huawei.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.