summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMartynas Venckus <martynas@cvs.openbsd.org>2009-09-18 21:08:20 +0000
committerMartynas Venckus <martynas@cvs.openbsd.org>2009-09-18 21:08:20 +0000
commit4947fa6be7004932bd9029501aafeaad1492ea4a (patch)
tree81bc9abb869dea417470973267ceb4d7c330789b /sys
parent61f0ff8a7eda80754ecd5ba77d421a27333148f7 (diff)
ldt removal missed some. amd64_{get,set}_ldt gone. also remove
ldt_{alloc,free} to shave a few. ok jasper@, oga@
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/amd64/amd64/gdt.c24
-rw-r--r--sys/arch/amd64/include/sysarch.h19
2 files changed, 2 insertions, 41 deletions
diff --git a/sys/arch/amd64/amd64/gdt.c b/sys/arch/amd64/amd64/gdt.c
index 0753153a884..9faec1b13f5 100644
--- a/sys/arch/amd64/amd64/gdt.c
+++ b/sys/arch/amd64/amd64/gdt.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: gdt.c,v 1.14 2009/02/03 11:24:19 mikeb Exp $ */
+/* $OpenBSD: gdt.c,v 1.15 2009/09/18 21:08:19 martynas Exp $ */
/* $NetBSD: gdt.c,v 1.1 2003/04/26 18:39:28 fvdl Exp $ */
/*-
@@ -270,25 +270,3 @@ tss_free(int sel)
gdt_put_slot(IDXDYNSEL(sel));
}
-void
-ldt_alloc(struct pmap *pmap, char *ldt, size_t len)
-{
- int slot;
- struct sys_segment_descriptor *gdt;
-
- gdt = (struct sys_segment_descriptor *)&gdtstore[DYNSEL_START];
-
- slot = gdt_get_slot();
- set_sys_gdt(&gdt[slot], ldt, len - 1, SDT_SYSLDT, SEL_KPL, 0);
- pmap->pm_ldt_sel = GSEL(slot, SEL_KPL);
-}
-
-void
-ldt_free(struct pmap *pmap)
-{
- int slot;
-
- slot = IDXDYNSEL(pmap->pm_ldt_sel);
-
- gdt_put_slot(slot);
-}
diff --git a/sys/arch/amd64/include/sysarch.h b/sys/arch/amd64/include/sysarch.h
index 4a2ed77b4c5..1be21cd9bd1 100644
--- a/sys/arch/amd64/include/sysarch.h
+++ b/sys/arch/amd64/include/sysarch.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: sysarch.h,v 1.3 2004/02/27 23:45:55 deraadt Exp $ */
+/* $OpenBSD: sysarch.h,v 1.4 2009/09/18 21:08:19 martynas Exp $ */
/* $NetBSD: sysarch.h,v 1.1 2003/04/26 18:39:48 fvdl Exp $ */
#ifndef _AMD64_SYSARCH_H_
@@ -19,21 +19,6 @@
#define AMD64_GET_MTRR 11
#define AMD64_SET_MTRR 12
-/*
- * XXX todo.
- */
-struct amd64_get_ldt_args {
- int start;
- union descriptor *desc;
- int num;
-};
-
-struct amd64_set_ldt_args {
- int start;
- union descriptor *desc;
- int num;
-};
-
struct amd64_iopl_args {
int iopl;
};
@@ -95,8 +80,6 @@ int amd64_iopl(struct proc *, void *, register_t *);
int amd64_get_mtrr(struct proc *, void *, register_t *);
int amd64_set_mtrr(struct proc *, void *, register_t *);
#else
-int amd64_get_ldt(int, union descriptor *, int);
-int amd64_set_ldt(int, union descriptor *, int);
int amd64_iopl(int);
int amd64_get_ioperm(u_long *);
int amd64_set_ioperm(u_long *);