File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -151,21 +151,25 @@ impl Segment for CS {
151151
152152/// Stack Segment
153153///
154- /// Entirely unused in 64-bit mode, setting the segment register does nothing.
154+ /// Entirely unused in 64-bit mode; setting the segment register does nothing.
155+ /// However, this register is often set by the `syscall`/`sysret` and
156+ /// `sysenter`/`sysexit` instructions (even on 64-bit transitions). This is to
157+ /// maintain symmetry with 32-bit transitions where setting SS actually will
158+ /// actually have an effect.
155159#[ derive( Debug ) ]
156160pub struct SS ;
157161segment_impl ! ( SS , "ss" , x86_64_asm_get_ss, x86_64_asm_load_ss) ;
158162
159163/// Data Segment
160164///
161- /// Entirely unused in 64-bit mode, setting the segment register does nothing.
165+ /// Entirely unused in 64-bit mode; setting the segment register does nothing.
162166#[ derive( Debug ) ]
163167pub struct DS ;
164168segment_impl ! ( DS , "ds" , x86_64_asm_get_ds, x86_64_asm_load_ds) ;
165169
166170/// ES Segment
167171///
168- /// Entirely unused in 64-bit mode, setting the segment register does nothing.
172+ /// Entirely unused in 64-bit mode; setting the segment register does nothing.
169173#[ derive( Debug ) ]
170174pub struct ES ;
171175segment_impl ! ( ES , "es" , x86_64_asm_get_es, x86_64_asm_load_es) ;
You can’t perform that action at this time.
0 commit comments