From: Sebastian Andrzej Siewior Date: Tue, 3 Aug 2021 14:15:55 +0000 (+0200) Subject: crypto: virtio - Replace deprecated CPU-hotplug functions. X-Git-Tag: libata-5.15-2021-09-05~102^2~50 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=d01a9f7009c3812a8955b7ae5798470cd6ab3590;p=linux-block.git crypto: virtio - Replace deprecated CPU-hotplug functions. The functions get_online_cpus() and put_online_cpus() have been deprecated during the CPU hotplug rework. They map directly to cpus_read_lock() and cpus_read_unlock(). Replace deprecated CPU-hotplug functions with the official version. The behavior remains unchanged. Cc: Gonglei Cc: "Michael S. Tsirkin" Cc: Jason Wang Cc: Herbert Xu Cc: "David S. Miller" Cc: virtualization@lists.linux-foundation.org Cc: linux-crypto@vger.kernel.org Signed-off-by: Sebastian Andrzej Siewior Signed-off-by: Herbert Xu --- diff --git a/drivers/crypto/virtio/virtio_crypto_core.c b/drivers/crypto/virtio/virtio_crypto_core.c index 080955a1dd9c..e2375d992308 100644 --- a/drivers/crypto/virtio/virtio_crypto_core.c +++ b/drivers/crypto/virtio/virtio_crypto_core.c @@ -187,9 +187,9 @@ static int virtcrypto_init_vqs(struct virtio_crypto *vi) if (ret) goto err_free; - get_online_cpus(); + cpus_read_lock(); virtcrypto_set_affinity(vi); - put_online_cpus(); + cpus_read_unlock(); return 0;