diff options
author | NeilBrown <neilb@suse.com> | 2017-12-18 12:41:42 +1100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-01-08 16:03:44 +0100 |
commit | e904f839cdb04d1b314753a83a6e58146e315c66 (patch) | |
tree | 456c0f779dbb6d40ee919dfdae240921eb1010dd /drivers/staging | |
parent | 30f4236aafa81722490e74ded48a9fb2aff013ab (diff) | |
download | linux-e904f839cdb04d1b314753a83a6e58146e315c66.tar.bz2 |
staging: lustre: replace cfs_get_random_bytes calls with get_random_byte()
The cfs_get_random_bytes() interface adds nothing of value
to get_random_byte() (which it uses internally). So just use the
standard interface.
Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r-- | drivers/staging/lustre/lustre/include/obd_class.h | 2 | ||||
-rw-r--r-- | drivers/staging/lustre/lustre/obdclass/lustre_handles.c | 2 | ||||
-rw-r--r-- | drivers/staging/lustre/lustre/ptlrpc/client.c | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/drivers/staging/lustre/lustre/include/obd_class.h b/drivers/staging/lustre/lustre/include/obd_class.h index 67c535c5aa98..25db7ec6ecd0 100644 --- a/drivers/staging/lustre/lustre/include/obd_class.h +++ b/drivers/staging/lustre/lustre/include/obd_class.h @@ -1562,7 +1562,7 @@ int class_procfs_init(void); int class_procfs_clean(void); /* prng.c */ -#define ll_generate_random_uuid(uuid_out) cfs_get_random_bytes(uuid_out, sizeof(class_uuid_t)) +#define ll_generate_random_uuid(uuid_out) get_random_bytes(uuid_out, sizeof(class_uuid_t)) /* statfs_pack.c */ struct kstatfs; diff --git a/drivers/staging/lustre/lustre/obdclass/lustre_handles.c b/drivers/staging/lustre/lustre/obdclass/lustre_handles.c index d1b6c2f134d7..2d6da2431a09 100644 --- a/drivers/staging/lustre/lustre/obdclass/lustre_handles.c +++ b/drivers/staging/lustre/lustre/obdclass/lustre_handles.c @@ -196,7 +196,7 @@ int class_handle_init(void) spin_lock_init(&bucket->lock); } - cfs_get_random_bytes(&handle_base, sizeof(handle_base)); + get_random_bytes(&handle_base, sizeof(handle_base)); LASSERT(handle_base != 0ULL); return 0; diff --git a/drivers/staging/lustre/lustre/ptlrpc/client.c b/drivers/staging/lustre/lustre/ptlrpc/client.c index 2a9f2f2ebaa8..bac4b2304bad 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/client.c +++ b/drivers/staging/lustre/lustre/ptlrpc/client.c @@ -3067,7 +3067,7 @@ void ptlrpc_init_xid(void) spin_lock_init(&ptlrpc_last_xid_lock); if (now < YEAR_2004) { - cfs_get_random_bytes(&ptlrpc_last_xid, sizeof(ptlrpc_last_xid)); + get_random_bytes(&ptlrpc_last_xid, sizeof(ptlrpc_last_xid)); ptlrpc_last_xid >>= 2; ptlrpc_last_xid |= (1ULL << 61); } else { |