Skip to content

Commit b070bb6

Browse files
committed
Remove deprecated functions/flags
Signed-off-by: Joe Richey <[email protected]>
1 parent 2e65c45 commit b070bb6

File tree

4 files changed

+0
-99
lines changed

4 files changed

+0
-99
lines changed

src/instructions/segmentation.rs

-89
Original file line numberDiff line numberDiff line change
@@ -103,92 +103,3 @@ impl GS {
103103
}
104104
}
105105
}
106-
107-
/// Alias for [`CS::set_reg()`]
108-
#[deprecated(since = "0.14.4", note = "use `CS::set_reg()` instead")]
109-
#[allow(clippy::missing_safety_doc)]
110-
#[inline]
111-
pub unsafe fn set_cs(sel: SegmentSelector) {
112-
unsafe { CS::set_reg(sel) }
113-
}
114-
/// Alias for [`SS::set_reg()`]
115-
#[deprecated(since = "0.14.4", note = "use `SS::set_reg()` instead")]
116-
#[allow(clippy::missing_safety_doc)]
117-
#[inline]
118-
pub unsafe fn load_ss(sel: SegmentSelector) {
119-
unsafe { SS::set_reg(sel) }
120-
}
121-
/// Alias for [`DS::set_reg()`]
122-
#[deprecated(since = "0.14.4", note = "use `DS::set_reg()` instead")]
123-
#[allow(clippy::missing_safety_doc)]
124-
#[inline]
125-
pub unsafe fn load_ds(sel: SegmentSelector) {
126-
unsafe { DS::set_reg(sel) }
127-
}
128-
/// Alias for [`ES::set_reg()`]
129-
#[deprecated(since = "0.14.4", note = "use `ES::set_reg()` instead")]
130-
#[allow(clippy::missing_safety_doc)]
131-
#[inline]
132-
pub unsafe fn load_es(sel: SegmentSelector) {
133-
unsafe { ES::set_reg(sel) }
134-
}
135-
/// Alias for [`FS::set_reg()`]
136-
#[deprecated(since = "0.14.4", note = "use `FS::set_reg()` instead")]
137-
#[allow(clippy::missing_safety_doc)]
138-
#[inline]
139-
pub unsafe fn load_fs(sel: SegmentSelector) {
140-
unsafe { FS::set_reg(sel) }
141-
}
142-
/// Alias for [`GS::set_reg()`]
143-
#[deprecated(since = "0.14.4", note = "use `GS::set_reg()` instead")]
144-
#[allow(clippy::missing_safety_doc)]
145-
#[inline]
146-
pub unsafe fn load_gs(sel: SegmentSelector) {
147-
unsafe { GS::set_reg(sel) }
148-
}
149-
/// Alias for [`GS::swap()`]
150-
#[deprecated(since = "0.14.4", note = "use `GS::swap()` instead")]
151-
#[allow(clippy::missing_safety_doc)]
152-
#[inline]
153-
pub unsafe fn swap_gs() {
154-
unsafe { GS::swap() }
155-
}
156-
/// Alias for [`CS::get_reg()`]
157-
#[deprecated(since = "0.14.4", note = "use `CS::get_reg()` instead")]
158-
#[allow(clippy::missing_safety_doc)]
159-
#[inline]
160-
pub fn cs() -> SegmentSelector {
161-
CS::get_reg()
162-
}
163-
/// Alias for [`FS::write_base()`].
164-
///
165-
/// Panics if the provided address is non-canonical.
166-
#[deprecated(since = "0.14.4", note = "use `FS::write_base()` instead")]
167-
#[allow(clippy::missing_safety_doc)]
168-
#[inline]
169-
pub unsafe fn wrfsbase(val: u64) {
170-
unsafe { FS::write_base(VirtAddr::new(val)) }
171-
}
172-
/// Alias for [`FS::read_base()`]
173-
#[deprecated(since = "0.14.4", note = "use `FS::read_base()` instead")]
174-
#[allow(clippy::missing_safety_doc)]
175-
#[inline]
176-
pub unsafe fn rdfsbase() -> u64 {
177-
FS::read_base().as_u64()
178-
}
179-
/// Alias for [`GS::write_base()`].
180-
///
181-
/// Panics if the provided address is non-canonical.
182-
#[deprecated(since = "0.14.4", note = "use `GS::write_base()` instead")]
183-
#[allow(clippy::missing_safety_doc)]
184-
#[inline]
185-
pub unsafe fn wrgsbase(val: u64) {
186-
unsafe { GS::write_base(VirtAddr::new(val)) }
187-
}
188-
/// Alias for [`GS::read_base()`]
189-
#[deprecated(since = "0.14.4", note = "use `GS::read_base()` instead")]
190-
#[allow(clippy::missing_safety_doc)]
191-
#[inline]
192-
pub unsafe fn rdgsbase() -> u64 {
193-
GS::read_base().as_u64()
194-
}

src/registers/control.rs

-3
Original file line numberDiff line numberDiff line change
@@ -141,9 +141,6 @@ bitflags! {
141141
/// Also enables access to the PKRU register (via the `RDPKRU`/`WRPKRU`
142142
/// instructions) to set user-mode protection key access controls.
143143
const PROTECTION_KEY_USER = 1 << 22;
144-
/// Alias for [`PROTECTION_KEY_USER`](Cr4Flags::PROTECTION_KEY_USER)
145-
#[deprecated(since = "0.14.5", note = "use `PROTECTION_KEY_USER` instead")]
146-
const PROTECTION_KEY = 1 << 22;
147144
/// Enables Control-flow Enforcement Technology (CET)
148145
///
149146
/// This enables the shadow stack feature, ensuring return addresses read

src/registers/mod.rs

-4
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,5 @@ pub mod rflags;
77
pub mod segmentation;
88
pub mod xcontrol;
99

10-
#[cfg(feature = "instructions")]
11-
#[allow(deprecated)]
12-
pub use crate::instructions::segmentation::{rdfsbase, rdgsbase, wrfsbase, wrgsbase};
13-
1410
#[cfg(feature = "instructions")]
1511
pub use crate::instructions::read_rip;

src/registers/xcontrol.rs

-3
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,6 @@ bitflags! {
2424
/// Enables AVX instructions and using the upper halves of the AVX registers
2525
/// with `XSAVE`/`XRSTOR`.
2626
const AVX = 1 << 2;
27-
/// Alias for [`AVX`](XCr0Flags::AVX)
28-
#[deprecated(since = "0.14.5", note = "use `AVX` instead")]
29-
const YMM = 1<<2;
3027
/// Enables MPX instructions and using the BND0-BND3 bound registers
3128
/// with `XSAVE`/`XRSTOR` (Intel Only).
3229
const BNDREG = 1 << 3;

0 commit comments

Comments
 (0)