Skip to content

Commit 83bdc72

Browse files
committed
random32: remove net_rand_state from the latent entropy gcc plugin
It turns out that the plugin right now ends up being really unhappy about the change from 'static' to 'extern' storage that happened in commit f227e3e ("random32: update the net random state on interrupt and activity"). This is probably a trivial fix for the latent_entropy plugin, but for now, just remove net_rand_state from the list of things the plugin worries about. Reported-by: Stephen Rothwell <[email protected]> Cc: Emese Revfy <[email protected]> Cc: Kees Cook <[email protected]> Cc: Willy Tarreau <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
1 parent d3590eb commit 83bdc72

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

include/linux/random.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ struct rnd_state {
120120
__u32 s1, s2, s3, s4;
121121
};
122122

123-
DECLARE_PER_CPU(struct rnd_state, net_rand_state) __latent_entropy;
123+
DECLARE_PER_CPU(struct rnd_state, net_rand_state);
124124

125125
u32 prandom_u32_state(struct rnd_state *state);
126126
void prandom_bytes_state(struct rnd_state *state, void *buf, size_t nbytes);

lib/random32.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ static inline void prandom_state_selftest(void)
4848
}
4949
#endif
5050

51-
DEFINE_PER_CPU(struct rnd_state, net_rand_state) __latent_entropy;
51+
DEFINE_PER_CPU(struct rnd_state, net_rand_state);
5252

5353
/**
5454
* prandom_u32_state - seeded pseudo-random number generator.

0 commit comments

Comments
 (0)