cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
StevenNoonan
Paper Tape
Posts: 3
Registered: ‎02-08-2019
Location: US
Views: 791
Message 1 of 4

ThinkPad A485 TSC broken on BIOS 1.16

The ThinkPad A485 BIOS seems to be breaking TSC synchronization:

 

https://bugzilla.kernel.org/show_bug.cgi?id=202525

 

Basically, CPU0 has a TSC offset of about -1600ms from all the other CPUs. Since AMD CPUs do not support MSR_IA32_TSC_ADJUST, the Linux kernel isn't able to compensate for the delta and falls back to using clocksource=hpet (which is about 100x slower to read compared to the TSC). This will cause some serious performance problems for anything that reads a clocksource via clock_gettime/gettimeofday/ftime/etc.

 

Are there any Lenovo firmware engineers reading this forum?

samantham
Paper Tape
Posts: 4
Registered: ‎10-11-2018
Location: US
Views: 192
Message 2 of 4

Re: ThinkPad A485 TSC broken on BIOS 1.16

I also get this same issue. I wouldn't hold my breath for Lenovo engineers to read this forum. You can try contacting them over phone or on Twitter to see if you can get somebody to notice this.
StevenNoonan
Paper Tape
Posts: 3
Registered: ‎02-08-2019
Location: US
Views: 186
Message 3 of 4

Re: ThinkPad A485 TSC broken on BIOS 1.16

Yeah, I didn't have a lot of hope about it, but it's what Lenovo's support team actually recommended. (I know, right?!)

 

In any case, Lenovo is now aware of the issue -- I got ahold of some senior folks on the ThinkPad teams through other channels. After some explanation they confirmed that they could reproduce the issue and would work on a fix. Unfortunately since it's a firmware or microcode bug, it may be a while before we see a fix make it through QA.

StevenNoonan
Paper Tape
Posts: 3
Registered: ‎02-08-2019
Location: US
Views: 181
Message 4 of 4

Re: ThinkPad A485 TSC broken on BIOS 1.16

By the way, if you want a temporary fix that allows you to use the TSC as your clocksource, you can apply this patch and build your own kernel (or if you're on Arch you could add my repo and install "linux-hsw", I keep the kernel following current releases around once or twice per week):

 

https://git.uplinklabs.net/steven/projects/archlinux/ec2/ec2-packages.git/tree/linux-hsw/0006-tsc-al...

 

It's not a great fix because the lack of IA32_TSC_ADJUST means we have to try several times to get close to the right values for the TSCs, but I've been running with this patch for several months now on my A485 and haven't had any significant trouble with it yet. It does get slightly confused on suspend/resume (the timestamp prefixing each line in dmesg goes crazy) but I haven't seen any bad userspace-level issues.

Check out current deals!


Shop current deals

Top Kudoed Authors