@@ -63,7 +63,7 @@ pub(crate) mod crashdump;
6363
6464use std:: fmt:: Debug ;
6565use std:: str:: FromStr ;
66- use std:: sync:: atomic:: { AtomicBool , AtomicU64 , Ordering } ;
66+ use std:: sync:: atomic:: { AtomicBool , AtomicU8 , Ordering } ;
6767use std:: sync:: { Arc , Mutex } ;
6868#[ cfg( any( kvm, mshv3) ) ]
6969use std:: time:: Duration ;
@@ -588,7 +588,7 @@ pub(super) struct LinuxInterruptHandle {
588588 ///
589589 /// CANCEL_BIT persists across vcpu exits/re-entries within a single `VirtualCPU::run()` call
590590 /// (e.g., during host function calls), but is cleared at the start of each new `VirtualCPU::run()` call.
591- state : AtomicU64 ,
591+ state : AtomicU8 ,
592592
593593 /// Thread ID where the vcpu is running.
594594 ///
@@ -608,10 +608,10 @@ pub(super) struct LinuxInterruptHandle {
608608
609609#[ cfg( any( kvm, mshv3) ) ]
610610impl LinuxInterruptHandle {
611- const RUNNING_BIT : u64 = 1 << 1 ;
612- const CANCEL_BIT : u64 = 1 << 0 ;
611+ const RUNNING_BIT : u8 = 1 << 1 ;
612+ const CANCEL_BIT : u8 = 1 << 0 ;
613613 #[ cfg( gdb) ]
614- const DEBUG_INTERRUPT_BIT : u64 = 1 << 2 ;
614+ const DEBUG_INTERRUPT_BIT : u8 = 1 << 2 ;
615615
616616 /// Get the running, cancel and debug flags atomically.
617617 ///
@@ -756,18 +756,18 @@ pub(super) struct WindowsInterruptHandle {
756756 ///
757757 /// CANCEL_BIT persists across vcpu exits/re-entries within a single `VirtualCPU::run()` call
758758 /// (e.g., during host function calls), but is cleared at the start of each new `VirtualCPU::run()` call.
759- state : AtomicU64 ,
759+ state : AtomicU8 ,
760760
761761 partition_handle : windows:: Win32 :: System :: Hypervisor :: WHV_PARTITION_HANDLE ,
762762 dropped : AtomicBool ,
763763}
764764
765765#[ cfg( target_os = "windows" ) ]
766766impl WindowsInterruptHandle {
767- const RUNNING_BIT : u64 = 1 << 1 ;
768- const CANCEL_BIT : u64 = 1 << 0 ;
767+ const RUNNING_BIT : u8 = 1 << 1 ;
768+ const CANCEL_BIT : u8 = 1 << 0 ;
769769 #[ cfg( gdb) ]
770- const DEBUG_INTERRUPT_BIT : u64 = 1 << 2 ;
770+ const DEBUG_INTERRUPT_BIT : u8 = 1 << 2 ;
771771}
772772
773773#[ cfg( target_os = "windows" ) ]
0 commit comments