Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
CSEP551
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Krishna Vinnakota
CSEP551
Commits
c7317d4d
Commit
c7317d4d
authored
16 years ago
by
kolya
Browse files
Options
Downloads
Patches
Plain Diff
always save and restore %fs, %gs to ensure old segment entries are never
accessible to user from the hidden CPU segment registers.
parent
adcd16c3
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
trapasm.S
+4
-0
4 additions, 0 deletions
trapasm.S
x86.h
+8
-4
8 additions, 4 deletions
x86.h
with
12 additions
and
4 deletions
trapasm.S
+
4
−
0
View file @
c7317d4d
...
...
@@ -8,6 +8,8 @@ alltraps:
#
Build
trap
frame
.
pushl
%
ds
pushl
%
es
pushl
%
fs
pushl
%
gs
pushal
#
Set
up
data
segments
.
...
...
@@ -24,6 +26,8 @@ alltraps:
.
globl
trapret
trapret
:
popal
popl
%
gs
popl
%
fs
popl
%
es
popl
%
ds
addl
$
0x8
,
%
esp
#
trapno
and
errcode
...
...
This diff is collapsed.
Click to expand it.
x86.h
+
8
−
4
View file @
c7317d4d
...
...
@@ -135,21 +135,25 @@ struct trapframe {
uint
eax
;
// rest of trap frame
ushort
e
s
;
ushort
g
s
;
ushort
padding1
;
ushort
d
s
;
ushort
f
s
;
ushort
padding2
;
ushort
es
;
ushort
padding3
;
ushort
ds
;
ushort
padding4
;
uint
trapno
;
// below here defined by x86 hardware
uint
err
;
uint
eip
;
ushort
cs
;
ushort
padding
3
;
ushort
padding
5
;
uint
eflags
;
// below here only when crossing rings, such as from user to kernel
uint
esp
;
ushort
ss
;
ushort
padding
4
;
ushort
padding
6
;
};
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment