Skip to content

Commit

Permalink
crypto: virtio - Replace deprecated CPU-hotplug functions.
Browse files Browse the repository at this point in the history
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 <[email protected]>
Cc: "Michael S. Tsirkin" <[email protected]>
Cc: Jason Wang <[email protected]>
Cc: Herbert Xu <[email protected]>
Cc: "David S. Miller" <[email protected]>
Cc: [email protected]
Cc: [email protected]
Signed-off-by: Sebastian Andrzej Siewior <[email protected]>
Signed-off-by: Herbert Xu <[email protected]>
  • Loading branch information
Sebastian Andrzej Siewior authored and herbertx committed Aug 12, 2021
1 parent c391714 commit d01a9f7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/crypto/virtio/virtio_crypto_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;

Expand Down

0 comments on commit d01a9f7

Please sign in to comment.