qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [virtio-dev] Re: [v23 1/2] virtio-crypto: Add virtio cr


From: Michael S. Tsirkin
Subject: Re: [Qemu-devel] [virtio-dev] Re: [v23 1/2] virtio-crypto: Add virtio crypto device specification
Date: Fri, 16 Mar 2018 18:27:03 +0200

On Tue, Jan 09, 2018 at 06:05:41PM +0100, Halil Pasic wrote:
> > +\item[\field{max_cipher_key_len}] is the maximum length of cipher key 
> > supported by the device.
> 
> I can't find what happens if this limit isn't honored by the driver. Moreover
> reading it is only SHOULD. Is it undefined behavior or should the device 
> reject/fail
> such requests? I think in qemu implementation we fail the request.
> 
> This question is only about niceness. We are already good enough, IMHO:
> since the implementer of the driver can't be sure what is going to happen
> if the driver disregards max_cipher_key_len it is already an implicit
> SHOULD.

I am not sure documenting undefined behaviour is always required.
We certainly do not do this for all other devices.

Reading a field being SHOULD seems reasonable: e.g.
driver might read it once and cache it in memory.

Halil, could you try to split your comments between requirements
for more conformance clauses/clarifications as opposed to
defects where it's wrong and does not match actual or
expected behaviour?

I think spec is better off with some documentation for this
device than none at all like today.

-- 
MST



reply via email to

[Prev in Thread] Current Thread [Next in Thread]