shithub: riscv

Download patch

ref: 5aa902c9535f4d52f8c941101e726f88a40e27e6
parent: 0b849750505a43d27deb1defcd8910193d066481
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Sun May 28 08:16:45 EDT 2023

aux/acpi: no need for amlval(), amleval() will dereference the name and run the method

--- a/sys/src/cmd/aux/acpi.c
+++ b/sys/src/cmd/aux/acpi.c
@@ -310,10 +310,10 @@
 	/* The ACPI spec requires we call _TTS and _PTS to prepare
 	 * the system to go to _S5 state. If they fail, too bad,
 	 * try to go to _S5 state anyway. */
-	pts = amlval(amlwalk(amlroot, "_PTS"));
-	tts = amlval(amlwalk(amlroot, "_TTS"));
+	pts = amlwalk(amlroot, "_PTS");
 	if(pts)
 		amleval(pts, "i", 5, nil);
+	tts = amlwalk(amlroot, "_TTS");
 	if(tts)
 		amleval(tts, "i", 5, nil);