From b1d4bcf95215d7c4bf225695c8294f9bf5b3dab7 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 Mutex Signed-off-by: Rob Bradford --- acpi_tables/src/aml.rs | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/acpi_tables/src/aml.rs b/acpi_tables/src/aml.rs index 3ab644227..f1490d166 100644 --- a/acpi_tables/src/aml.rs +++ b/acpi_tables/src/aml.rs @@ -888,12 +888,11 @@ impl Mutex { } impl Aml for Mutex { - fn to_aml_bytes(&self) -> Vec { - let mut bytes = vec![0x5b]; /* ExtOpPrefix */ + fn append_aml_bytes(&self, bytes: &mut Vec) { + bytes.push(0x5b); /* ExtOpPrefix */ bytes.push(0x01); /* MutexOp */ - bytes.extend_from_slice(&self.path.to_aml_bytes()); + self.path.append_aml_bytes(bytes); bytes.push(self.sync_level); - bytes } }