@@ -323,16 +323,11 @@ impl Ps2Controller {
323323
324324 /// Push a scancode byte to the keyboard queue (called from UI)
325325 pub fn push_kb ( & self , key : KeyCode , pressed : bool ) {
326- if !self . running . load ( Ordering :: Relaxed ) {
327- eprintln ! ( "PS2: push_kb({:?}, {}) DROPPED — not running" , key, pressed) ;
328- return ;
329- }
326+ if !self . running . load ( Ordering :: Relaxed ) { return ; }
330327 let mut state = self . state . lock ( ) ;
331328 if !state. scanning_enabled {
332- eprintln ! ( "PS2: push_kb({:?}, {}) DROPPED — scanning disabled" , key, pressed) ;
333329 return ;
334330 }
335- eprintln ! ( "PS2: push_kb({:?}, {}) — scanning set={}, queue_len={}" , key, pressed, state. scancode_set, state. rx_queue. len( ) ) ;
336331
337332 match state. scancode_set {
338333 1 => {
@@ -737,16 +732,11 @@ impl Ps2Controller {
737732 /// queue is congested (≥8 pending mouse packets) and the tail has the
738733 /// same button state.
739734 pub fn push_mouse_packet ( & self , b0 : u8 , b1 : u8 , b2 : u8 ) {
740- if !self . running . load ( Ordering :: Relaxed ) {
741- eprintln ! ( "PS2: mouse packet DROPPED — not running" ) ;
742- return ;
743- }
735+ if !self . running . load ( Ordering :: Relaxed ) { return ; }
744736 let mut state = self . state . lock ( ) ;
745737 if !state. mouse_enabled {
746- eprintln ! ( "PS2: mouse packet DROPPED — mouse disabled" ) ;
747738 return ;
748739 }
749- eprintln ! ( "PS2: mouse packet b0={:02x} b1={:02x} b2={:02x} queue_len={}" , b0, b1, b2, state. rx_queue. len( ) ) ;
750740 let mouse_packets = state. mouse_queue_bytes / 3 ;
751741 let coalesced = if mouse_packets >= 8 {
752742 let len = state. rx_queue . len ( ) ;
0 commit comments