All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: zhenwei pi <pizhenwei@bytedance.com>
Cc: arei.gonglei@huawei.com, mst@redhat.com, dgilbert@redhat.com,
	eblake@redhat.com, armbru@redhat.com, michael.roth@amd.com,
	pbonzini@redhat.com, qemu-devel@nongnu.org
Subject: Re: [for-8.0 v2 01/11] cryptodev: Introduce cryptodev.json
Date: Mon, 16 Jan 2023 10:58:40 +0000	[thread overview]
Message-ID: <Y8Ut4OqS+hPOjydv@redhat.com> (raw)
In-Reply-To: <20221122140756.686982-2-pizhenwei@bytedance.com>

On Tue, Nov 22, 2022 at 10:07:46PM +0800, zhenwei pi wrote:
> Introduce QCryptodevBackendType in cryptodev.json, also apply this to
> related codes. Then we can drop 'enum CryptoDevBackendOptionsType'.
> 
> Signed-off-by: zhenwei pi <pizhenwei@bytedance.com>
> ---
>  MAINTAINERS                     |  1 +
>  backends/cryptodev-builtin.c    |  2 +-
>  backends/cryptodev-lkcf.c       |  2 +-
>  backends/cryptodev-vhost-user.c |  4 ++--
>  backends/cryptodev-vhost.c      |  4 ++--
>  include/sysemu/cryptodev.h      | 11 ++---------
>  qapi/cryptodev.json             | 20 ++++++++++++++++++++
>  qapi/meson.build                |  1 +
>  qapi/qapi-schema.json           |  1 +
>  9 files changed, 31 insertions(+), 15 deletions(-)
>  create mode 100644 qapi/cryptodev.json


> @@ -215,16 +216,8 @@ struct CryptoDevBackendClass {
>                   void *opaque);
>  };
>  
> -typedef enum CryptoDevBackendOptionsType {
> -    CRYPTODEV_BACKEND_TYPE_NONE = 0,
> -    CRYPTODEV_BACKEND_TYPE_BUILTIN = 1,
> -    CRYPTODEV_BACKEND_TYPE_VHOST_USER = 2,
> -    CRYPTODEV_BACKEND_TYPE_LKCF = 3,
> -    CRYPTODEV_BACKEND_TYPE__MAX,
> -} CryptoDevBackendOptionsType;

Old code has a 'NONE' value as the default


> +##
> +# @QCryptodevBackendType:
> +#
> +# The crypto device backend type
> +#
> +# @builtin: the QEMU builtin support
> +# @vhost-user: vhost-user
> +# @lkcf: Linux kernel cryptographic framework
> +#
> +# Since: 8.0
> +##
> +{ 'enum': 'QCryptodevBackendType',
> +  'prefix': 'QCRYPTODEV_BACKEND_TYPE',
> +  'data': ['builtin', 'vhost-user', 'lkcf']}

...but new code has no 'none'. None the less I think that is
OK, as I'm not seeing anything that needed the 'none' type.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>


With regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|



  reply	other threads:[~2023-01-16 10:59 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-22 14:07 [for-8.0 v2 00/11] Refactor cryptodev zhenwei pi
2022-11-22 14:07 ` [for-8.0 v2 01/11] cryptodev: Introduce cryptodev.json zhenwei pi
2023-01-16 10:58   ` Daniel P. Berrangé [this message]
2022-11-22 14:07 ` [for-8.0 v2 02/11] cryptodev: Remove 'name' & 'model' fields zhenwei pi
2023-01-16 11:05   ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 03/11] cryptodev: Introduce cryptodev alg type in QAPI zhenwei pi
2023-01-16 11:08   ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 04/11] cryptodev: Introduce server " zhenwei pi
2023-01-16 11:09   ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 05/11] cryptodev: Introduce 'query-cryptodev' QMP command zhenwei pi
2023-01-16 11:18   ` Daniel P. Berrangé
2023-01-18 10:25     ` Michael S. Tsirkin
2023-01-18 10:29       ` Daniel P. Berrangé
2023-01-18 10:58         ` Thomas Huth
2023-01-18 11:01           ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 06/11] cryptodev: Support statistics zhenwei pi
2022-12-20 15:35   ` Michael S. Tsirkin
2023-01-16 11:22   ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 07/11] cryptodev-builtin: Detect akcipher capability zhenwei pi
2023-01-16 11:23   ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 08/11] hmp: add cryptodev info command zhenwei pi
2022-11-22 14:07 ` [for-8.0 v2 09/11] cryptodev: Use CryptoDevBackendOpInfo for operation zhenwei pi
2022-11-22 14:07 ` [for-8.0 v2 10/11] cryptodev: support QoS zhenwei pi
2022-11-22 14:07 ` [for-8.0 v2 11/11] MAINTAINERS: add myself as the maintainer for cryptodev zhenwei pi
2022-12-16  3:24 ` PING: [for-8.0 v2 00/11] Refactor cryptodev zhenwei pi
2022-12-20 15:36 ` Michael S. Tsirkin
2022-12-22  2:04   ` zhenwei pi
2023-01-03  6:14     ` PING: " zhenwei pi
2023-01-16  9:53   ` zhenwei pi
2023-01-16 11:27     ` Daniel P. Berrangé
2023-01-17  1:52       ` zhenwei pi

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=Y8Ut4OqS+hPOjydv@redhat.com \
    --to=berrange@redhat.com \
    --cc=arei.gonglei@huawei.com \
    --cc=armbru@redhat.com \
    --cc=dgilbert@redhat.com \
    --cc=eblake@redhat.com \
    --cc=michael.roth@amd.com \
    --cc=mst@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=pizhenwei@bytedance.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 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.