Monday, February 27th 2017

AMD's Ryzen CPU Series will Need Modern Linux Kernel for Proper Support

So, it's not just Windows that will be pulling the "you need the latest version" card when it comes to Ryzen CPU support. Apparently, Linux will need kernel version 4.9.10 or better to enable a lot of features, SMT included. If you really want good support, the "newer the better" is generally the way to go.

Operating below that version won't necessarily stop Ryzen from functioning as a CPU, but several notable features, most notably SMT, will be completely "broken" according to the article at Phronix.

Phronix notes that the fix landed in early February. It notes in the commit message:
After: a33d331761bc ("x86/CPU/AMD: Fix Bulldozer topology") our SMT scheduling topology for Fam17h systems is broken, because the ThreadId is included in the ApicId when SMT is enabled. So, without further decoding cpu_core_id is unique for each thread rather than the same for threads on the same core. This didn't affect systems with SMT disabled. Make cpu_core_id be what it is defined to be.
So there it is, for you techno-wizards. Apparently, microcode actually is relevant to support features, and Microsoft's claims have some degree of merit.
Source: Phronix
Add your own comment

81 Comments on AMD's Ryzen CPU Series will Need Modern Linux Kernel for Proper Support

#1
eidairaman1
The Exiled Airman
They just don't want to spend time back coding it for older Kernels
Posted on Reply
#2
R-T-B
eidairaman1They just don't want to spend time back coding it for older Kernels
Microsoft surely could say the same thing for the Windows 7 kernel, to be fair. :)
Posted on Reply
#3
FordGT90Concept
"I go fast!1!11!1!"
I'm pretty sure R-T-B and Microsoft has it right: Microsoft had to push an update out on AMD's behalf to properly balance the load and power save with Bulldozer. It makes sense that with a new implementation of SMT, the OS has to know how to properly load balance and power save with Ryzen as well. Hell, pretty sure Microsoft had to push an update out for Pentium 4 w/ HTT way back in the day too.

In other words, this was inevitable with all operating systems running Ryzen.
Posted on Reply
#4
Nabarun
It's not the same as for windows. EVERYBODY updates/upgrades to the latest Linux kernel anyway. It's free.
Posted on Reply
#5
R-T-B
NabarunIt's not the same as for windows. EVERYBODY updates/upgrades to the latest Linux kernel anyway. It's free.
It may be free to use, but from a developer perspective, it is not free. Linux is a project with many many man hours. Microsoft and Linux both agree on one thing: Prioritization of resources make sense.
Posted on Reply
#6
xkm1948
This is actually pretty relevant for a lot of my fellow researchers who does tons of bioinformatics, since we work exclusively in linux environment. Good thing about linux is they are constantly pushing out new versions.
Posted on Reply
#7
simlariver
R-T-BIt may be free to use, but from a developer perspective, it is not free. Linux is a project with many many man hours. Microsoft and Linux both agree on one thing: Prioritization of resources make sense.
Dude, the code updates were written by AMD. Nobody outside AMD payed for this code commit.
New kernel can be compiled in any curent/past distro.
xkm1948This is actually pretty relevant for a lot of my fellow researchers who does tons of bioinformatics, since we work exclusively in linux environment. Good thing about linux is they are constantly pushing out new versions.
Science run on Linux. I recently visited the cutting edge AI research center in Montreal, it's Linux wall to wall on every machines. I asked about it and they mentionned scalability, performance and the fact that most researchers only use linux in university anyway. Cost (lack of) is just an added benefit.
Posted on Reply
#8
R-T-B
simlariverDude, the code updates were written by AMD. Nobody outside AMD payed for this code commit.
New kernel can be compiled in any curent/past distro.
It doesn't matter who's paying (though of course AMD would pay for their own cpus, that only makes sense), you still don't see them shoveling money towards the 3.x kernel, despite it still being supported as a longterm support release. It's because of prioritization of resources. My point stands.
Posted on Reply
#9
eidairaman1
The Exiled Airman
R-T-BMicrosoft surely could say the same thing for the Windows 7 kernel, to be fair. :)
they pretty much have
Posted on Reply
#10
notb
eidairaman1They just don't want to spend time back coding it for older Kernels
This is not exactly how Linux community works. :D
Posted on Reply
#11
notb
simlariverScience run on Linux. I recently visited the cutting edge AI research center in Montreal, it's Linux wall to wall on every machines. I asked about it and they mentionned scalability, performance and the fact that most researchers only use linux in university anyway. Cost (lack of) is just an added benefit.
Actually Linux is fairly expensive to introduce and support in an organization. You spend a lot more on training and even so some users never reach the same productivity they had on Windows.

Things like "scalability and performance" are important in servers and computation clusters (where Linux clearly is more popular), but they have little to do with popularity on typical end-user machine. :)
The reason why Linux is so popular among some scientists (mostly math and physics) is because it's beautifully easy to make semi-automatic workflow for scripting/coding/data analysis. That's because Linux is still basically a shell-driven OS and the graphical interface is somehow "forced" on a system that could easily work without it. Whenever you click something, a tiny command-line opens and does the job, so you can easily do the same thing just by writing the underneath command yourself. What's equally important: pretty much every application also has a text output.

By contrast, there are things on Windows you can't do by writing a command in prompt. And even if you can force a Windows workflow similar to that on Linux, it usually takes a lot more time.
Microsoft has already surrendered in forcing their own shell standard - the Powershell (although it's actually excellent - quite superior to bash in some ways). It has never become the "default" shell of Windows, so we're still using the awful cmd. Windows 10 already includes bash (like the one on Linux) and at some point will be fully built around it.

That said, Windows has a much better interface and is generally easier to use (because it is built to be operated using a mouse).
Posted on Reply
#12
Paphoved
eidairaman1They just don't want to spend time back coding it for older Kernels
The news article in question doesn't imply anything of the sorts. Ubuntu for example backports fixes like this into 'Hardware Enablement'-kernels especially for their LTS releases which are Long Term Support and will get up to 5 years of support. (Server packages, not for the desktop)

So just because the 4.10 version of the linux kernel is where the fix was made to support SMT from Ryzen chips isn't the same as saying that 'You need to upgrade your kernel'. You would need to get that information from the distros themselves.

People confuse what the individual Linux-based OS do to make their product appeal to certain users with the actual development of the kernel itself maintained by Linus Torvalds and contributed to by thousands of developers from companies like AMD and Intel, who has an interest in supporting their products on this kernel.

Both Ubuntu and Red Hat (I don't know about SUSE or other companies) maintain older version of the linux kernel for security and hardware fixes like these.
Posted on Reply
#13
RejZoR
NabarunIt's not the same as for windows. EVERYBODY updates/upgrades to the latest Linux kernel anyway. It's free.
Windows 10 was free for Windows 7 and Windows 8 users and they refused to update. So, that logic doesn't always apply...
Posted on Reply
#14
WaroDaBeast
notbThis is not exactly how Linux community works. :D
Maybe not in general, but for the kernel, older versions of the Linux kernel get security and stability updates in the form of backports. To get new features, you need to upgrade to a newer kernel.

I have yet to see an app that does get new features in older branches though.
Posted on Reply
#15
Camm
As a home user, you would have to be running a fairly esoteric configuration to actually care about this (distro hoppers, I'm looking at you).

Business might be somewhat more problematic, but neither have I seen many businesses move beyond Kiosk workers, and are probably running either SUSE or Ubuntu anyway, so again, downstream is pretty well much guaranteed. And anyone more esoteric than that has probably done it for a reason, and I'm sure they have the know how to implement the change in their environment.

Server is a different kettle of fish (but again, most are running Ubuntu\RedHat\SUSE) so apart from having to go thru the pain of verifying the update, probably not a problem.
Posted on Reply
#16
silentbogo
After: a33d331761bc ("x86/CPU/AMD: Fix Bulldozer topology") our SMT scheduling topology for Fam17h systems is broken, because the ThreadId is included in the ApicId when SMT is enabled. So, without further decoding cpu_core_id is unique for each thread rather than the same for threads on the same core. This didn't affect systems with SMT disabled. Make cpu_core_id be what it is defined to be.
That's why some Windows software, including Cinebench R15, shows Ryzen as 16C/16T. The OS sees each logical core as a physical core.

But, going back to the original topic... Here's a full quote from Phoronix:
I am told that if using Ubuntu 16.10 / Ubuntu 16.04.2 as a base state for AMD Ryzen, users should generally be okay. In other words, you won't get a kernel oops on boot or anything dramatic like that but could be missing some functionality. However, you will really be better off with a newer Linux kernel.

As I wrote about back in December, Linux 4.10 landed a lot of Zen/Ryzen code. So with Linux 4.10 looks to be -- and reaffirmed by this trusted confidant -- a good point for AMD Ryzen testing and usage. So far in the Linux 4.11 cycle we haven't seen anything Ryzen-specific appear to come through.

But if you don't feel comfortable moving to the recently-released Linux 4.10 or your distribution hasn't yet offered you an easy upgrade path, an alternative is to be running at least Linux 4.9.10.

I was pointed out in particular to this kernel commit that only landed in early February: "x86/CPU/AMD: Fix Zen SMT topology." It notes in the commit message, "After: a33d331761bc ("x86/CPU/AMD: Fix Bulldozer topology") our SMT scheduling topology for Fam17h systems is broken, because the ThreadId is included in the ApicId when SMT is enabled. So, without further decoding cpu_core_id is unique for each thread rather than the same for threads on the same core. This didn't affect systems with SMT disabled. Make cpu_core_id be what it is defined to be." That mentioned regression was introduced only in January but had been pulled back into stable kernel point releases from Linux 4.6 and newer. This fix for the (Ry)zen SMT topology is in Linux 4.10 and was back-ported to Linux 4.9.10+ for those still riding the 4.9 kernel.
So, 4.10 is fine. Fixes are backported to 4.9, so it should be fine too.
Which means, even today before Ryzen went on sale, most of us mortals should be fine.

Not so sure about BSD, but I'm confident they are working on it too (so far no news besides "it should work").
Posted on Reply
#17
Dartenor
Wasn't supposed to be today the end of the NDA of the reviews and benchmarks?
Posted on Reply
#18
notb
NabarunIt's not the same as for windows. EVERYBODY updates/upgrades to the latest Linux kernel anyway. It's free.
Not exactly.
1) people very serious about stability delay kernel update (they have bugs etc),
2) from time to time a new kernel stops supporting something (firmware/hardware), so people stay on an older version
3) a "power efficiency regression" is observable, e.g. new kernels increase power usage, so you may want to freeze the kernel in your notebook

But in general you're right - kernels are free, don't change OS interface etc, so in general it is recommended to update
Posted on Reply
#20
Nabarun
RejZoRWindows 10 was free for Windows 7 and Windows 8 users and they refused to update. So, that logic doesn't always apply...
It does. Because 7 and 8 were not free in the 1st place.
notbNot exactly.
1) people very serious about stability delay kernel update (they have bugs etc),
2) from time to time a new kernel stops supporting something (firmware/hardware), so people stay on an older version
3) a "power efficiency regression" is observable, e.g. new kernels increase power usage, so you may want to freeze the kernel in your notebook

But in general you're right - kernels are free, don't change OS interface etc, so in general it is recommended to update
Well, one doesn't need to update overnight. Just like they don't need to update the damn cpu overnight. I am pretty sure patches for the kernels are more frequent that a major CPU upgrade.
Posted on Reply
#21
Paphoved
NabarunIt does. Because 7 and 8 were not free in the 1st place.
Also AFAIK. If you want to install Windows again, you will have to buy it. The upgrade isn't valid for later installs with the same Windows 8.1 license.
Posted on Reply
#22
efikkan
This is pretty much expected, is not news at all, and is mostly the case with Intel too. E.g. Skylake/Kaby Lake only partly works with Ubuntu 14.04, but works fine with 16.04.
eidairaman1They just don't want to spend time back coding it for older Kernels
Nobody has infinite resources. Full CPU-support is probably the hardest to backport, specifically because it's so closely optimized in the scheduler.
NabarunIt's not the same as for windows. EVERYBODY updates/upgrades to the latest Linux kernel anyway. It's free.
No way. I have barely ever seen a Linux user, even among developers, which uses a rolling release distribution. Those who don't have a good reason to do so stick with stable releases, most often "LTS" versions.
Posted on Reply
#23
kruk
efikkanNo way. I have barely ever seen a Linux user, even among developers, which uses a rolling release distribution. Those who don't have a good reason to do so stick with stable releases, most often "LTS" versions..
You don't have to use a rolling distro to have the latest kernel. You can use backports/PPAs/updates or whatever for your stable distribution and update only specific packages. This way you can have latest kernel on a stable system.

As for the news, it's not only Ryzen CPUs which need new code, but also motherboard components. For example Realtek ALC1220 audio codec is only going to be supported in kernel 4.11 and newer (it's in the linked Phoronix article).
Posted on Reply
#24
RejZoR
NabarunIt does. Because 7 and 8 were not free in the 1st place.


Well, one doesn't need to update overnight. Just like they don't need to update the damn cpu overnight. I am pretty sure patches for the kernels are more frequent that a major CPU upgrade.
Then again they aren't as crap as Linux either, so cost kinda explains itself why... I mean, lets be real, I'm not your casual user and I can't stand the monumental clumsiness of Linux. Yeah, it's great tool for live boot tools, but for OS that you expect something more from than just basic out of the box experience, it always drove me absolutely insane. Even something as simple as installing a graphic driver means you'll spend typing freaking long noodles of commands into the damn terminal. Or make 2 clicks in Windows and be done with it.

So, yeah, Windows costs money. But for a reason.
Posted on Reply
#25
FordGT90Concept
"I go fast!1!11!1!"
silentbogoThat's why some Windows software, including Cinebench R15, shows Ryzen as 16C/16T. The OS sees each logical core as a physical core.
Tis a bug which OSs have to fix. All SMT processors have a preference for work order. For example, I think HTT is even are physical cores and odds are logical cores. When power saving, it should cut the logical cores first; when load balancing, it should place the load on 0/2/4/6 before 1/3/5/7. Microsoft screwed up Bulldozer because the order is different. Microsoft pushed out an update which tells Windows that specific cores are logical and others are physical so it correctly load balances as well.
Posted on Reply
Add your own comment
Jun 3rd, 2024 16:53 EDT change timezone

New Forum Posts

Popular Reviews

Controversial News Posts