Commit e904f839 authored by NeilBrown's avatar NeilBrown Committed by Greg Kroah-Hartman
Browse files

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: default avatarNeilBrown <neilb@suse.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 30f4236a
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -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;
+1 −1
Original line number Diff line number Diff line
@@ -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;
+1 −1
Original line number Diff line number Diff line
@@ -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 {