Merge pull request #168 from nariox/master
Implement "Disable BDPROCHOT"
This commit is contained in:
@@ -20,6 +20,8 @@ PL2_Duration_S: 0.002
|
|||||||
Trip_Temp_C: 85
|
Trip_Temp_C: 85
|
||||||
# Set cTDP to normal=0, down=1 or up=2 (EXPERIMENTAL)
|
# Set cTDP to normal=0, down=1 or up=2 (EXPERIMENTAL)
|
||||||
cTDP: 0
|
cTDP: 0
|
||||||
|
# Disable BDPROCHOT (EXPERIMENTAL)
|
||||||
|
Disable_BDPROCHOT: False
|
||||||
|
|
||||||
## Settings to apply while connected to AC power
|
## Settings to apply while connected to AC power
|
||||||
[AC]
|
[AC]
|
||||||
@@ -39,6 +41,8 @@ Trip_Temp_C: 95
|
|||||||
HWP_Mode: False
|
HWP_Mode: False
|
||||||
# Set cTDP to normal=0, down=1 or up=2 (EXPERIMENTAL)
|
# Set cTDP to normal=0, down=1 or up=2 (EXPERIMENTAL)
|
||||||
cTDP: 0
|
cTDP: 0
|
||||||
|
# Disable BDPROCHOT (EXPERIMENTAL)
|
||||||
|
Disable_BDPROCHOT: False
|
||||||
|
|
||||||
[UNDERVOLT.BATTERY]
|
[UNDERVOLT.BATTERY]
|
||||||
# CPU core voltage offset (mV)
|
# CPU core voltage offset (mV)
|
||||||
|
|||||||
@@ -528,6 +528,18 @@ def set_hwp():
|
|||||||
log('[D] HWP - write "{:#02x}" - read "{:#02x}" - match {}'.format(HWP_VALUE, read_value, match))
|
log('[D] HWP - write "{:#02x}" - read "{:#02x}" - match {}'.format(HWP_VALUE, read_value, match))
|
||||||
|
|
||||||
|
|
||||||
|
def set_disable_bdprochot():
|
||||||
|
# Disable BDPROCHOT
|
||||||
|
cur_val = readmsr(0x1FC,flatten=True)
|
||||||
|
new_val = (cur_val & 0xFFFFFFFFFFFFFFFE)
|
||||||
|
|
||||||
|
writemsr(0x1FC, new_val)
|
||||||
|
if args.debug:
|
||||||
|
read_value = readmsr(0x1FC, from_bit=31, to_bit=31)[0]
|
||||||
|
match = OK if ~read_value else ERR
|
||||||
|
log('[D] BDPROCHOT - write "{:#02x}" - read "{:#02x}" - match {}'.format(0, read_value, match))
|
||||||
|
|
||||||
|
|
||||||
def power_thread(config, regs, exit_event):
|
def power_thread(config, regs, exit_event):
|
||||||
try:
|
try:
|
||||||
mchbar_mmio = MMIO(0xFED159A0, 8)
|
mchbar_mmio = MMIO(0xFED159A0, 8)
|
||||||
@@ -599,6 +611,11 @@ def power_thread(config, regs, exit_event):
|
|||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# Disable BDPROCHOT
|
||||||
|
disable_bdprochot = config.getboolean(power['source'], 'Disable_BDPROCHOT', fallback=None)
|
||||||
|
if disable_bdprochot is not None:
|
||||||
|
set_disable_bdprochot()
|
||||||
|
|
||||||
wait_t = config.getfloat(power['source'], 'Update_Rate_s')
|
wait_t = config.getfloat(power['source'], 'Update_Rate_s')
|
||||||
enable_hwp_mode = config.getboolean('AC', 'HWP_Mode', fallback=False)
|
enable_hwp_mode = config.getboolean('AC', 'HWP_Mode', fallback=False)
|
||||||
# set HWP less frequently. Just to be safe since (e.g.) TLP might reset this value
|
# set HWP less frequently. Just to be safe since (e.g.) TLP might reset this value
|
||||||
|
|||||||
Reference in New Issue
Block a user