longsleep / linux-pine64

Pine64 Linux Kernel
Other
111 stars 107 forks source link

Revert "random32: add prandom_u32_max and convert open coded users" #67

Open zx2c4 opened 6 years ago

zx2c4 commented 6 years ago

I'm not sure what the deal is with all the various branches you have, but I'd appreciate it if in addition to merging this in whatever random branch I've selected for this PR, you could also cherry-pick it into all the other branches folks are using.


This reverts commit a6cdc1c6420f274eae456252d700b24e8d1edc1c.

Linux 3.10 does not have this function, because nothing in Linux 3.10 uses it. It was never backported in any of the kernel.org stable trees to 3.10. Its current inclusion in this pine64 kernel here adds nothing.

The reason this is a problem is because wireguard's compat layer assumes that 3.10 kernels won't have this function, so having it here actually causes problems. Sure, we could work around this in wireguard, but it doesn't seem prudent to play the game of accounting for every possible frankenkernel out there.

Instead this commit simply reverts the faulty backport.

Signed-off-by: Jason A. Donenfeld Jason@zx2c4.com