From 7ad83f1daa8614884bd0480290dc26ac0e8701b4 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 Io Signed-off-by: Rob Bradford --- acpi_tables/src/aml.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/acpi_tables/src/aml.rs b/acpi_tables/src/aml.rs index b267c7d5c..90588440a 100644 --- a/acpi_tables/src/aml.rs +++ b/acpi_tables/src/aml.rs @@ -494,16 +494,14 @@ impl Io { } impl Aml for Io { - fn to_aml_bytes(&self) -> Vec { - let mut bytes = vec![0x47]; /* Io Port Descriptor */ + fn append_aml_bytes(&self, bytes: &mut Vec) { + bytes.push(0x47); /* Io Port Descriptor */ bytes.push(1); /* IODecode16 */ bytes.append(&mut self.min.to_le_bytes().to_vec()); bytes.append(&mut self.max.to_le_bytes().to_vec()); bytes.push(self.alignment); bytes.push(self.length); - - bytes } }