Linux 5.3 Moves Ahead With No Longer Advertising RdRand On Older AMD CPUs/APUs
Just prior to yesterday's Linux 5.3-rc6 kernel release, a change was pulled into the code-base that disables the advertising of RdRand support on older AMD CPUs/APUs.
The change pulled into the current Linux 5.3 tree (as opposed to being delayed until Linux 5.4) is over hiding RdRand support on AMD Bulldozer and Jaguar era processors. RdRand is the instruction for returning random numbers from the CPU for what began as an Intel extension. The RdRand instruction will continue to function on affected AMD processors if encountered but the CPU ID bit is being cleared so that it won't be advertised for software checking for the presence of this bit. This is being done since those pre-Zen AMD CPUs tend to have issues with their RdRand instruction support following suspend/resume cycles for many motherboards.
On resume, many BIOS implementations are not doing the proper steps for ensuring RdRand support and is evidently widespread enough that AMD felt it necessary to just disable the support by default. Unfortunately there is no way to properly query whether RdRand is behaving fine on AMD hardware and thus for these older systems is more sane to just disable by default. The issue itself has been known for 5+ years where RdRand may effectively just return -1 but is now being addressed by the Linux stable tree as a kernel workaround.
For systems known to be in a good state or not seeing suspend/resume activity, the rdrand=force kernel parameter will override this default change.
So as of yesterday, the change is mainlined for Linux 5.3 and could end up being back-ported as well to existing stable series.
The change pulled into the current Linux 5.3 tree (as opposed to being delayed until Linux 5.4) is over hiding RdRand support on AMD Bulldozer and Jaguar era processors. RdRand is the instruction for returning random numbers from the CPU for what began as an Intel extension. The RdRand instruction will continue to function on affected AMD processors if encountered but the CPU ID bit is being cleared so that it won't be advertised for software checking for the presence of this bit. This is being done since those pre-Zen AMD CPUs tend to have issues with their RdRand instruction support following suspend/resume cycles for many motherboards.
On resume, many BIOS implementations are not doing the proper steps for ensuring RdRand support and is evidently widespread enough that AMD felt it necessary to just disable the support by default. Unfortunately there is no way to properly query whether RdRand is behaving fine on AMD hardware and thus for these older systems is more sane to just disable by default. The issue itself has been known for 5+ years where RdRand may effectively just return -1 but is now being addressed by the Linux stable tree as a kernel workaround.
For systems known to be in a good state or not seeing suspend/resume activity, the rdrand=force kernel parameter will override this default change.
So as of yesterday, the change is mainlined for Linux 5.3 and could end up being back-ported as well to existing stable series.
10 Comments