From d2319124f5d55aeaed67ff1d9c2dcf6ddda84b22 Mon Sep 17 00:00:00 2001 From: Rob Bradford Date: Wed, 3 Nov 2021 14:29:05 +0000 Subject: [PATCH] acpi_tables: aml: Implement Aml::append_aml_bytes() for Notify For now it still relies on Aml::to_aml_bytes() for the children as not all structures have been ported. Signed-off-by: Rob Bradford --- acpi_tables/src/aml.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/acpi_tables/src/aml.rs b/acpi_tables/src/aml.rs index e7869eb08..fe9c1f8f8 100644 --- a/acpi_tables/src/aml.rs +++ b/acpi_tables/src/aml.rs @@ -946,11 +946,10 @@ impl<'a> Notify<'a> { } impl<'a> Aml for Notify<'a> { - fn to_aml_bytes(&self) -> Vec { - let mut bytes = vec![0x86]; /* NotifyOp */ + fn append_aml_bytes(&self, bytes: &mut Vec) { + bytes.push(0x86); /* NotifyOp */ bytes.extend_from_slice(&self.object.to_aml_bytes()); bytes.extend_from_slice(&self.value.to_aml_bytes()); - bytes } }