File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -219,7 +219,7 @@ vga = []
219219# # Enables the PS/2 keyboard driver.
220220# #
221221# # This is only useful on PCs (x86-64).
222- keyboard = []
222+ pc- keyboard = []
223223
224224# ! ### Performance Features
225225
Original file line number Diff line number Diff line change @@ -158,9 +158,9 @@ pub(crate) fn install() {
158158}
159159
160160pub ( crate ) fn install_handlers ( #[ allow( unused_mut) ] mut handlers : InterruptHandlerMap ) {
161- #[ cfg( feature = "keyboard" ) ]
161+ #[ cfg( feature = "pc- keyboard" ) ]
162162 {
163- use crate :: arch:: kernel:: keyboard :: get_keyboard_handler;
163+ use crate :: arch:: kernel:: pc_keyboard :: get_keyboard_handler;
164164 let ( irq, handler) = get_keyboard_handler ( ) ;
165165 handlers. entry ( irq) . or_default ( ) . push_back ( handler) ;
166166 }
Original file line number Diff line number Diff line change @@ -20,10 +20,10 @@ pub mod gdt;
2020pub mod interrupts;
2121#[ cfg( feature = "kernel-stack" ) ]
2222pub mod kernel_stack;
23- #[ cfg( feature = "keyboard" ) ]
24- pub mod keyboard;
2523#[ cfg( all( not( feature = "pci" ) , feature = "virtio" ) ) ]
2624pub mod mmio;
25+ #[ cfg( feature = "pc-keyboard" ) ]
26+ pub mod pc_keyboard;
2727#[ cfg( feature = "pci" ) ]
2828pub mod pci;
2929pub mod pic;
File renamed without changes.
Original file line number Diff line number Diff line change @@ -7,16 +7,9 @@ pub extern "C" fn sys_getpagesize() -> i32 {
77 BasePageSize :: SIZE . try_into ( ) . unwrap ( )
88}
99
10- #[ cfg( all( target_arch = "x86_64" , feature = "keyboard" ) ) ]
10+ #[ cfg( all( target_arch = "x86_64" , feature = "pc- keyboard" ) ) ]
1111#[ hermit_macro:: system]
1212#[ unsafe( no_mangle) ]
1313pub extern "C" fn sys_read_keyboard ( ) -> u8 {
14- crate :: kernel:: keyboard:: pop_scancode ( ) . unwrap_or ( 0 )
15- }
16-
17- #[ cfg( not( all( target_arch = "x86_64" , feature = "keyboard" ) ) ) ]
18- #[ hermit_macro:: system]
19- #[ unsafe( no_mangle) ]
20- pub extern "C" fn sys_read_keyboard ( ) -> u8 {
21- 0
14+ crate :: kernel:: pc_keyboard:: pop_scancode ( ) . unwrap_or ( 0 )
2215}
You can’t perform that action at this time.
0 commit comments