@@ -42,32 +42,26 @@ impl lai::Host for LaiHost {
4242 }
4343
4444 // Port I/O functions:
45- #[ inline]
4645 fn outb ( & self , port : u16 , value : u8 ) {
4746 unsafe { io:: outb ( port, value) }
4847 }
4948
50- #[ inline]
5149 fn outw ( & self , port : u16 , value : u16 ) {
5250 unsafe { io:: outw ( port, value) }
5351 }
5452
55- #[ inline]
5653 fn outd ( & self , port : u16 , value : u32 ) {
5754 unsafe { io:: outl ( port, value) }
5855 }
5956
60- #[ inline]
6157 fn inb ( & self , port : u16 ) -> u8 {
6258 unsafe { io:: inb ( port) }
6359 }
6460
65- #[ inline]
6661 fn inw ( & self , port : u16 ) -> u16 {
6762 unsafe { io:: inw ( port) }
6863 }
6964
70- #[ inline]
7165 fn ind ( & self , port : u16 ) -> u32 {
7266 unsafe { io:: inl ( port) }
7367 }
@@ -91,7 +85,6 @@ impl lai::Host for LaiHost {
9185 }
9286
9387 // Memory functions:
94- #[ inline]
9588 fn map ( & self , address : usize , _count : usize ) -> * mut u8 {
9689 PhysAddr :: new ( address as u64 )
9790 . as_hhdm_virt ( )
@@ -105,6 +98,10 @@ impl aml::AmlSubsystem for LaiSubsystem {
10598 fn enter_state ( & self , state : aml:: SleepState ) {
10699 lai:: enter_sleep ( state as u8 )
107100 }
101+
102+ fn enable_acpi ( & self , mode : u32 ) {
103+ lai:: enable_acpi ( mode) ;
104+ }
108105}
109106
110107pub fn init_lai ( ) {
@@ -114,8 +111,6 @@ pub fn init_lai() {
114111 lai:: set_acpi_revision ( get_acpi_table ( ) . revision ( ) as _ ) ;
115112 lai:: create_namespace ( ) ;
116113
117- lai:: enable_acpi ( 1 ) ;
118-
119114 let subsystem = Arc :: new ( LaiSubsystem ) ;
120115 aml:: init ( subsystem) ;
121116}
0 commit comments