mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
lib: clean up put_cpu_var usage
put_cpu_var takes the percpu data, not the data returned from get_cpu_var. This doesn't change the behavior. Cc: Tejun Heo <[email protected]> Signed-off-by: Shaohua Li <[email protected]> Acked-by: Tejun Heo <[email protected]> Signed-off-by: David S. Miller <[email protected]>
This commit is contained in:
parent
b761fe226b
commit
3796c3cbfb
1 changed files with 2 additions and 2 deletions
|
|
@ -81,7 +81,7 @@ u32 prandom_u32(void)
|
|||
u32 res;
|
||||
|
||||
res = prandom_u32_state(state);
|
||||
put_cpu_var(state);
|
||||
put_cpu_var(net_rand_state);
|
||||
|
||||
return res;
|
||||
}
|
||||
|
|
@ -128,7 +128,7 @@ void prandom_bytes(void *buf, size_t bytes)
|
|||
struct rnd_state *state = &get_cpu_var(net_rand_state);
|
||||
|
||||
prandom_bytes_state(state, buf, bytes);
|
||||
put_cpu_var(state);
|
||||
put_cpu_var(net_rand_state);
|
||||
}
|
||||
EXPORT_SYMBOL(prandom_bytes);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue