PCENGINES APU[1-7] Coreboot SeaBIOS Open Source Firmware

Started by tillsense, January 03, 2017, 07:36:55 PM

Previous topic - Next topic
After upgrading to v4.11.0.5, the command "sysctl dev.cpu" returns no values.
I'm pretty sure that there should be values for dev.cpu. Previously, there were over 50 values for dev.cpu

Update:
I looked at the the PC Engines Blog, https://pcengines.github.io/firmware/2020/03/31/PC-Engines-Firmware-v4-11-0-5.html

Apparently, it's a known issue. Near the bottom of the page.

4. ACPI Thermal Zones implementation. BSD systems suffer from lack of Thermal Zones and lack of temperature status on the dashboards of router distributions of BSD systems.

Another update:
When re-reading the blog, this item is under the 'What we planned" and item 4 has "DONE" after it.
Yes. ACPI Thermal Zone is available, hw.acpi.thermal.tz0.temperature. But, we no longer have dev.cpu in sysctl.
On the dashboard, ACPI temperature is shown.
Possibly, the Cputemp report uses dev.cpu.[0123].temperature values ?
Could the firmware be updated to return dev.cpu values ?

Yet another update:
It's been reported by pfSense users.
https://github.com/pcengines/coreboot/issues/389

Thank you

Hi all,

there seem to be several problems here at the moment: https://github.com/pcengines/coreboot/issues.

Can you get the serial number of your APU[1-5] with firmware v4.11.0.5 by using the widget "Hardware Information" or dmidecode on console?

[opnsense 20.1.4]

cheers
till

I have an APU2D4 with BIOS v4.11.0.5 and OPNsense 20.1.4

root@OPNsense:~ # dmidecode --string system-serial-number
1324981
root@OPNsense:~ #

As far as I can tell, the system is working fine. I get my full Internet speed, 200+ Mbps. Same as previous versions of the BIOS.
The only obvious differences are:
Lobby:Dashboard - Thermal Sensors shows 1 value hw.acpi.thermal.tz0.temperature
                            previously there were 4 individual core temperatures: dev.cpu.[0123].temperature
Reporting:Health:System:Cputemp - No CPU temp values probably due to "sysctl dev.cpu" values missing

On v4.11.0.5, "Enabled PCIe power management capabilities". According to 'hw.acpi.thermal.tz0.temperature" value, my CPU temperature is lower by at least a degree or two compared to earlier BIOS. So, less heat due to lower power consumption.

Thanks

I've got an APU2C4 with Bios v4.11.0.5 running OPNSense 20.1.4

I can verify @Gary7 observations that they are also true to the earlier revision of the APU2x4 platform. My internet speed is a modest 100 Mb/s.

Hello.

As a start, i apologize if not the good topic to post that question.

I'm using an APU2C4 with Opnsense up to update (20.1.4).
While flashing coreboot from v4.9.0.5 to v4.11.0.5 I experienced a huge performance drop :
average DL speed :
- v4.9.0.5 : 580~600 Mbps
- v4.11.0.5 : 260~300 Mbps

Reverting coreboot version to v4.9.0.5 turned back speed up to 580~600 Mbps as before.

Is anyone aware of similar problems ?
Did I miss some tunables to set after the firmware upgrade ?

Thanks for your help.
Cheers

With the earlier versions of BIOS, it was highly recommended (essentially required) that you shutdown and unplug your APU2 from power for 30 seconds, or so, after flashing the new BIOS.
After flashing to v4.11.0.5, shutdown and unplug from power for 30 seconds. After reboot, do you still see the large performance drop ?


Thanks Gary for your support.
I just did test with a 30s unplug before rebooting after flash and still experience the large performance drop with this method.

Happy Easter.
Cheers

Other people using other O/S have reported a performance decrease with v4.11.0.5
https://github.com/pcengines/coreboot/issues/387
Look at the last entry from the BIOS developer, miczyg1.
"due to enablement of PCIe ASPM the performance dropped in favor of power savings. We will make this option runtime configurable". Not yet configurable or controlled in FreeBSD.

Could you try v4.11.0.4 ?
PCIe power management capabilities was introduced in v4.11.0.5. Maybe with v.4.11.0.4, your performance will return to normal.

I don't see the performance decrease either because I only have 200Mbps Internet speed, or because I've set every setting and configuration that I could find to maximize APU2 throughput.

Good Luck and Happy Easter

Thanks for the hint, I will give a try flashing on v4.11.0.4 tomorrow.

I confirm the performance drop on v4.11.0.5 isn't only opnsense/freebsd related.
I tried booting on an openwrt flash drive on the same hardware, and experience performance drop in a worse way even : 940 Mbps down to 340 Mbps.
My fiber line is 1Gbps down / 400 Mbps up. Sadly not reaching full speed with apu2c4 on it. And tried a few performance tuning on it, not sure i have found all though.

I'll keep you informed of the test results with v4.11.0.4 tomorrow.
Have a lovely evening.

On Linux, you could try the kernel setting of "pcie_aspm.policy=performance" that was mentioned in Coreboot issue #387. https://github.com/pcengines/coreboot/issues/387

Good luck

A setting that I previously set in OPNsense that MIGHT make a difference in network performance was to disable Energy Efficient Ethernet for the 3 NICs.
It doesn't seem to work when the value is set in /etc/sysctl.conf.local, so I set it in the GUI.
System -> Settings -> Tunables
I added the variables dev.igb.0.eee_disabled (and 1 and 2) and set to a value of 1
I don't want the NICs to go to sleep because I'll probably get network errors or lose packets as the NIC wakes up.
I wonder with ASPM enabled whether the NICs are more aggressively trying to go to sleep to save power.
The NICs don't use that much power, so I want the NICs to always be active.

Just a thought.

Thanks Gary for your support.
I did the test as planned and there is no obvious performance drop upgrading up to v4.11.0.4. They start to appear with v4.11.0.5.
So it's obviously the new energy efficient parameter that creates the issue.

I've also tried to disable to NIC energy efficiency with your parameter in tunables.
There's a tiny performance bump with them, but that's not a very significant one.
I'm afraid i'll have to resign upgrading to some new hardware to handle my fiber at full gigabit speed with opnsense.

Thanks a lot to your help, and have a nice Easter Monday
Cheers

Quote from: Gary7 on April 13, 2020, 04:17:59 AM
A setting that I previously set in OPNsense that MIGHT make a difference in network performance was to disable Energy Efficient Ethernet for the 3 NICs.
It doesn't seem to work when the value is set in /etc/sysctl.conf.local, so I set it in the GUI.
System -> Settings -> Tunables
I added the variables dev.igb.0.eee_disabled (and 1 and 2) and set to a value of 1
I don't want the NICs to go to sleep because I'll probably get network errors or lose packets as the NIC wakes up.
I wonder with ASPM enabled whether the NICs are more aggressively trying to go to sleep to save power.
The NICs don't use that much power, so I want the NICs to always be active.

Just a thought.

Got interested in the tunables you mentioned, so did some research via Google. Came across a very extensive network tuning description. Just sharing:

https://calomel.org/freebsd_network_tuning.html

I used that page a lot for my APU2 optimization.
A few of the settings are specific to FreeBSD 12.1 (not in 11.2) and, of course, I ignore the ZFS settings.

Did you happen to come across this post about optimizing the APU2x4 for gigabit speed?

https://forum.opnsense.org/index.php?topic=13899.0