File tree Expand file tree Collapse file tree 5 files changed +6
-6
lines changed Expand file tree Collapse file tree 5 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ bitflags! {
1212 /// Configuration flags of the Cr0 register.
1313 pub struct Cr0Flags : u64 {
1414 /// Enables protected mode.
15- const PROTECTED_MODE_ENABLE = 1 << 0 ;
15+ const PROTECTED_MODE_ENABLE = 1 ;
1616 /// Enables monitoring of the coprocessor, typical for x87 instructions.
1717 ///
1818 /// Controls together with the `TASK_SWITCHED` flag whether a `wait` or `fwait`
@@ -73,7 +73,7 @@ bitflags! {
7373 pub struct Cr4Flags : u64 {
7474 /// Enables hardware-supported performance enhancements for software running in
7575 /// virtual-8086 mode.
76- const VIRTUAL_8086_MODE_EXTENSIONS = 1 << 0 ;
76+ const VIRTUAL_8086_MODE_EXTENSIONS = 1 ;
7777 /// Enables support for protected-mode virtual interrupts.
7878 const PROTECTED_MODE_VIRTUAL_INTERRUPTS = 1 << 1 ;
7979 /// When set, only privilege-level 0 can execute the RDTSC or RDTSCP instructions.
Original file line number Diff line number Diff line change @@ -85,7 +85,7 @@ bitflags! {
8585 /// Flags of the Extended Feature Enable Register.
8686 pub struct EferFlags : u64 {
8787 /// Enables the `syscall` and `sysret` instructions.
88- const SYSTEM_CALL_EXTENSIONS = 1 << 0 ;
88+ const SYSTEM_CALL_EXTENSIONS = 1 ;
8989 /// Activates long mode, requires activating paging.
9090 const LONG_MODE_ENABLE = 1 << 8 ;
9191 /// Indicates that long mode is active.
Original file line number Diff line number Diff line change @@ -58,7 +58,7 @@ bitflags! {
5858 const PARITY_FLAG = 1 << 2 ;
5959 /// Set by hardware if last arithmetic operation generated a carry out of the
6060 /// most-significant bit of the result.
61- const CARRY_FLAG = 1 << 0 ;
61+ const CARRY_FLAG = 1 ;
6262 }
6363}
6464
Original file line number Diff line number Diff line change @@ -824,7 +824,7 @@ bitflags! {
824824 pub struct PageFaultErrorCode : u64 {
825825 /// If this flag is set, the page fault was caused by a page-protection violation,
826826 /// else the page fault was caused by a not-present page.
827- const PROTECTION_VIOLATION = 1 << 0 ;
827+ const PROTECTION_VIOLATION = 1 ;
828828
829829 /// If this flag is set, the memory access that caused the page fault was a write.
830830 /// Else the access that caused the page fault is a memory read. This bit does not
Original file line number Diff line number Diff line change @@ -114,7 +114,7 @@ bitflags! {
114114 /// Possible flags for a page table entry.
115115 pub struct PageTableFlags : u64 {
116116 /// Specifies whether the mapped frame or page table is loaded in memory.
117- const PRESENT = 1 << 0 ;
117+ const PRESENT = 1 ;
118118 /// Controls whether writes to the mapped frames are allowed.
119119 ///
120120 /// If this bit is unset in a level 1 page table entry, the mapped frame is read-only.
You can’t perform that action at this time.
0 commit comments