2002-11-19 23:01:07 +00:00
|
|
|
/*
|
|
|
|
* (C) Copyright 2002
|
2011-08-04 16:45:45 +00:00
|
|
|
* Daniel Engström, Omicron Ceti AB, daniel@omicron.se
|
2003-06-27 21:31:46 +00:00
|
|
|
*
|
2013-07-08 07:37:19 +00:00
|
|
|
* SPDX-License-Identifier: GPL-2.0+
|
2002-11-19 23:01:07 +00:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __ASM_PROCESSOR_H_
|
|
|
|
#define __ASM_PROCESSOR_H_ 1
|
2011-02-12 04:11:30 +00:00
|
|
|
|
2011-12-30 23:24:36 +00:00
|
|
|
#define X86_GDT_ENTRY_SIZE 8
|
|
|
|
|
|
|
|
#ifndef __ASSEMBLY__
|
|
|
|
|
|
|
|
enum {
|
|
|
|
X86_GDT_ENTRY_NULL = 0,
|
|
|
|
X86_GDT_ENTRY_UNUSED,
|
|
|
|
X86_GDT_ENTRY_32BIT_CS,
|
|
|
|
X86_GDT_ENTRY_32BIT_DS,
|
2011-12-31 11:58:15 +00:00
|
|
|
X86_GDT_ENTRY_32BIT_FS,
|
2011-12-30 23:24:36 +00:00
|
|
|
X86_GDT_ENTRY_16BIT_CS,
|
|
|
|
X86_GDT_ENTRY_16BIT_DS,
|
|
|
|
X86_GDT_NUM_ENTRIES
|
|
|
|
};
|
|
|
|
#else
|
|
|
|
/* NOTE: If the above enum is modified, this define must be checked */
|
|
|
|
#define X86_GDT_ENTRY_32BIT_DS 3
|
2012-11-27 15:38:36 +00:00
|
|
|
#define X86_GDT_NUM_ENTRIES 7
|
2011-12-30 23:24:36 +00:00
|
|
|
#endif
|
|
|
|
|
|
|
|
#define X86_GDT_SIZE (X86_GDT_NUM_ENTRIES * X86_GDT_ENTRY_SIZE)
|
2011-02-12 04:11:30 +00:00
|
|
|
|
2002-11-19 23:01:07 +00:00
|
|
|
#endif
|