Open notstarboard opened 6 months ago
I have exact same error, and similar usecase. In my case undervolting was working (I was using intel-undervolt), but I need program to undervolt based on power source, intel-undervolt has no feature like that. For some reason, the same undervolt values are stable on AC but on battery with the same undervolt values my laptop freezes. Now throttled looks perfect for me, and it works (the undervolting part, which I'm only intrested in), but it throws ugly errors on logs. So it's the case of executing this in a clean way.
@notstarboard like I said, I have exact same usecase, I just want to undervolt, and I can confirm, the undervolting part works despite of the errors (I am sure it works, because when I set some absurdly high values like -200mV and I apply it, my laptop instantly freezes). So if you still can't undervolt with that tool, the problem should be somewhere else.
I've been having no success using georgewhewell/undervolt to undervolt my laptop and I stumbled upon this project as a possible alternative. I have no interest in anything other than undervolting, so I put together a relatively sparse config file aimed at doing just that:
This configuration causes an exception to be thrown by the service:
The issue seems to be that regs[power_source]['MSR_PKG_POWER_LIMIT'] is never set on line 625 because none of PL1_Tdp_W, PL1_Duration_s, PL2_Tdp_W, and PL2_Duration_s are set in my config file. power_thread is always called in main(), and then within power_thread it tries to use regs[power_source]['MSR_PKG_POWER_LIMIT'], which has not been set.
A conditional should probably be added to avoid this. I don't think power_thread needs to be called at all unless the user attempts to change related settings in the config file.