Kernel: Cleanup AML code and add evaluate for string

This commit is contained in:
Bananymous 2024-04-16 17:39:16 +03:00
parent 7707e01352
commit 6a4f999b88
2 changed files with 7 additions and 0 deletions

View File

@ -104,6 +104,7 @@ namespace Kernel::ACPI::AML
AML_ERROR("BinaryOP {2H} LHS not an integer", static_cast<uint8_t>(opcode));
if (lhs_result.node())
lhs_result.node()->debug_print(1);
AML_DEBUG_PRINTLN("");
return ParseResult::Failure;
}
@ -116,6 +117,7 @@ namespace Kernel::ACPI::AML
AML_ERROR("BinaryOP {2H} RHS not an integer", static_cast<uint8_t>(opcode));
if (rhs_result.node())
rhs_result.node()->debug_print(1);
AML_DEBUG_PRINTLN("");
return ParseResult::Failure;
}

View File

@ -13,6 +13,11 @@ namespace Kernel::ACPI::AML
String() : Node(Node::Type::String) {}
BAN::RefPtr<AML::Node> evaluate() override
{
return this;
}
static ParseResult parse(ParseContext& context)
{
ASSERT(context.aml_data.size() >= 1);