summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorGonglei2016-10-28 10:33:26 +0200
committerMichael S. Tsirkin2016-11-01 18:21:08 +0100
commit050652d9be4c723da2a36f2e9ca5be20e27e93b7 (patch)
treecd783d0b37ca28a648f1a3e0acdbbcd62746afc6 /include
parentvirtio-crypto-pci: add virtio crypto pci support (diff)
downloadqemu-050652d9be4c723da2a36f2e9ca5be20e27e93b7.tar.gz
qemu-050652d9be4c723da2a36f2e9ca5be20e27e93b7.tar.xz
qemu-050652d9be4c723da2a36f2e9ca5be20e27e93b7.zip
virtio-crypto: set capacity of algorithms supported
Expose the capacity of algorithms supported by virtio crypto device to the frontend driver using pci configuration space. Signed-off-by: Gonglei <arei.gonglei@huawei.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'include')
-rw-r--r--include/hw/virtio/virtio-crypto.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/include/hw/virtio/virtio-crypto.h b/include/hw/virtio/virtio-crypto.h
index 4652c21b20..783ea23e69 100644
--- a/include/hw/virtio/virtio-crypto.h
+++ b/include/hw/virtio/virtio-crypto.h
@@ -39,6 +39,24 @@ do { \
typedef struct VirtIOCryptoConf {
CryptoDevBackend *cryptodev;
+
+ /* Supported service mask */
+ uint32_t crypto_services;
+
+ /* Detailed algorithms mask */
+ uint32_t cipher_algo_l;
+ uint32_t cipher_algo_h;
+ uint32_t hash_algo;
+ uint32_t mac_algo_l;
+ uint32_t mac_algo_h;
+ uint32_t aead_algo;
+
+ /* Maximum length of cipher key */
+ uint32_t max_cipher_key_len;
+ /* Maximum length of authenticated key */
+ uint32_t max_auth_key_len;
+ /* Maximum size of each crypto request's content */
+ uint64_t max_size;
} VirtIOCryptoConf;
struct VirtIOCrypto;