diff options
author | zhenwei pi <pizhenwei@bytedance.com> | 2023-10-07 09:43:09 +0300 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2023-10-18 18:30:06 +0300 |
commit | fa2e6947aa8844f25f5bad0d8cd1a541d9bc83eb (patch) | |
tree | d92bb7764dbdf89efcda19d4d7c356308fab11f4 /drivers/crypto/virtio/virtio_crypto_common.h | |
parent | ca50ec377c2e94b0a9f8735de2856cd0f13beab4 (diff) | |
download | linux-fa2e6947aa8844f25f5bad0d8cd1a541d9bc83eb.tar.xz |
virtio-crypto: handle config changed by work queue
MST pointed out: config change callback is also handled incorrectly
in this driver, it takes a mutex from interrupt context.
Handle config changed by work queue instead.
Cc: stable@vger.kernel.org
Cc: Gonglei (Arei) <arei.gonglei@huawei.com>
Cc: Halil Pasic <pasic@linux.ibm.com>
Cc: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: zhenwei pi <pizhenwei@bytedance.com>
Message-Id: <20231007064309.844889-1-pizhenwei@bytedance.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'drivers/crypto/virtio/virtio_crypto_common.h')
-rw-r--r-- | drivers/crypto/virtio/virtio_crypto_common.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/crypto/virtio/virtio_crypto_common.h b/drivers/crypto/virtio/virtio_crypto_common.h index 59a4c0259456..154590e1f764 100644 --- a/drivers/crypto/virtio/virtio_crypto_common.h +++ b/drivers/crypto/virtio/virtio_crypto_common.h @@ -35,6 +35,9 @@ struct virtio_crypto { struct virtqueue *ctrl_vq; struct data_queue *data_vq; + /* Work struct for config space updates */ + struct work_struct config_work; + /* To protect the vq operations for the controlq */ spinlock_t ctrl_lock; |