x86/libsel4: Rename ia32->x86
Rename all functions, constants and types in libsel4 that are in the general x86 architecture to have an X86 name instead of an IA32 name. As libsel4 and the kernel share names this requires changing those in the kernel as well. All the original IA32 names can still be used for the moment, but are marked as deprecated.
This commit is contained in:
parent
eb5b792bca
commit
5349282478
12 changed files with 226 additions and 102 deletions
|
|
@ -9,60 +9,60 @@
|
|||
@TAG(NICTA_BSD)
|
||||
-->
|
||||
<api>
|
||||
<interface name="seL4_IA32_PageDirectory">
|
||||
<method id="IA32PageDirectoryMap" name="Map">
|
||||
<interface name="seL4_X86_PageDirectory">
|
||||
<method id="X86PageDirectoryMap" name="Map">
|
||||
<param dir="in" name="vroot" type="seL4_CPtr"/>
|
||||
<param dir="in" name="vaddr" type="seL4_Word"/>
|
||||
<param dir="in" name="attr" type="seL4_IA32_VMAttributes"/>
|
||||
<param dir="in" name="attr" type="seL4_X86_VMAttributes"/>
|
||||
</method>
|
||||
<method id="IA32PageDirectoryUnmap" name="Unmap">
|
||||
<method id="X86PageDirectoryUnmap" name="Unmap">
|
||||
</method>
|
||||
</interface>
|
||||
|
||||
<interface name="seL4_IA32_PageTable">
|
||||
<method id="IA32PageTableMap" name="Map">
|
||||
<interface name="seL4_X86_PageTable">
|
||||
<method id="X86PageTableMap" name="Map">
|
||||
<param dir="in" name="vroot" type="seL4_CPtr"/>
|
||||
<param dir="in" name="vaddr" type="seL4_Word"/>
|
||||
<param dir="in" name="attr" type="seL4_IA32_VMAttributes"/>
|
||||
<param dir="in" name="attr" type="seL4_X86_VMAttributes"/>
|
||||
</method>
|
||||
<method id="IA32PageTableUnmap" name="Unmap">
|
||||
<method id="X86PageTableUnmap" name="Unmap">
|
||||
</method>
|
||||
</interface>
|
||||
|
||||
<interface name="seL4_IA32_IOPageTable">
|
||||
<method id="IA32IOPageTableMap" name="Map">
|
||||
<param dir="in" name="iospace" type="seL4_IA32_IOSpace"/>
|
||||
<interface name="seL4_X86_IOPageTable">
|
||||
<method id="X86IOPageTableMap" name="Map">
|
||||
<param dir="in" name="iospace" type="seL4_X86_IOSpace"/>
|
||||
<param dir="in" name="ioaddr" type="seL4_Word"/>
|
||||
</method>
|
||||
<method id="IA32IOPageTableUnmap" name="Unmap">
|
||||
<method id="X86IOPageTableUnmap" name="Unmap">
|
||||
</method>
|
||||
</interface>
|
||||
|
||||
<interface name="seL4_IA32_Page">
|
||||
<method id="IA32PageMap" name="Map">
|
||||
<interface name="seL4_X86_Page">
|
||||
<method id="X86PageMap" name="Map">
|
||||
<param dir="in" name="vroot" type="seL4_CPtr"/>
|
||||
<param dir="in" name="vaddr" type="seL4_Word"/>
|
||||
<param dir="in" name="rights" type="seL4_CapRights"/>
|
||||
<param dir="in" name="attr" type="seL4_IA32_VMAttributes"/>
|
||||
<param dir="in" name="attr" type="seL4_X86_VMAttributes"/>
|
||||
</method>
|
||||
<method id="IA32PageRemap" name="Remap">
|
||||
<method id="X86PageRemap" name="Remap">
|
||||
<param dir="in" name="vroot" type="seL4_CPtr"/>
|
||||
<param dir="in" name="rights" type="seL4_CapRights"/>
|
||||
<param dir="in" name="attr" type="seL4_IA32_VMAttributes"/>
|
||||
<param dir="in" name="attr" type="seL4_X86_VMAttributes"/>
|
||||
</method>
|
||||
<method id="IA32PageUnmap" name="Unmap"/>
|
||||
<method id="IA32PageMapIO" name="MapIO">
|
||||
<param dir="in" name="iospace" type="seL4_IA32_IOSpace"/>
|
||||
<method id="X86PageUnmap" name="Unmap"/>
|
||||
<method id="X86PageMapIO" name="MapIO">
|
||||
<param dir="in" name="iospace" type="seL4_X86_IOSpace"/>
|
||||
<param dir="in" name="rights" type="seL4_CapRights"/>
|
||||
<param dir="in" name="ioaddr" type="seL4_Word"/>
|
||||
</method>
|
||||
<method id="IA32PageGetAddress" name="GetAddress">
|
||||
<method id="X86PageGetAddress" name="GetAddress">
|
||||
<param dir="out" name="paddr" type="seL4_Word"/>
|
||||
</method>
|
||||
</interface>
|
||||
|
||||
<interface name="seL4_IA32_ASIDControl">
|
||||
<method id="IA32ASIDControlMakePool" name="MakePool">
|
||||
<interface name="seL4_X86_ASIDControl">
|
||||
<method id="X86ASIDControlMakePool" name="MakePool">
|
||||
<param dir="in" name="untyped" type="seL4_Untyped"/>
|
||||
<param dir="in" name="root" type="seL4_CNode"/>
|
||||
<param dir="in" name="index" type="seL4_Word"/>
|
||||
|
|
@ -70,41 +70,41 @@
|
|||
</method>
|
||||
</interface>
|
||||
|
||||
<interface name="seL4_IA32_ASIDPool">
|
||||
<method id="IA32ASIDPoolAssign" name="Assign">
|
||||
<interface name="seL4_X86_ASIDPool">
|
||||
<method id="X86ASIDPoolAssign" name="Assign">
|
||||
<param dir="in" name="vroot" type="seL4_CPtr"/>
|
||||
</method>
|
||||
</interface>
|
||||
|
||||
<interface name="seL4_IA32_IOPort">
|
||||
<method id="IA32IOPortIn8" name="In8">
|
||||
<interface name="seL4_X86_IOPort">
|
||||
<method id="X86IOPortIn8" name="In8">
|
||||
<param dir="out" name="result" type="seL4_Uint8"/>
|
||||
<param dir="in" name="port" type="seL4_Uint16"/>
|
||||
</method>
|
||||
<method id="IA32IOPortIn16" name="In16">
|
||||
<method id="X86IOPortIn16" name="In16">
|
||||
<param dir="out" name="result" type="seL4_Uint16"/>
|
||||
<param dir="in" name="port" type="seL4_Uint16"/>
|
||||
</method>
|
||||
<method id="IA32IOPortIn32" name="In32">
|
||||
<method id="X86IOPortIn32" name="In32">
|
||||
<param dir="out" name="result" type="seL4_Uint32"/>
|
||||
<param dir="in" name="port" type="seL4_Uint16"/>
|
||||
</method>
|
||||
<method id="IA32IOPortOut8" name="Out8">
|
||||
<method id="X86IOPortOut8" name="Out8">
|
||||
<param dir="in" name="port" type="seL4_Word"/>
|
||||
<param dir="in" name="data" type="seL4_Word"/>
|
||||
</method>
|
||||
<method id="IA32IOPortOut16" name="Out16">
|
||||
<method id="X86IOPortOut16" name="Out16">
|
||||
<param dir="in" name="port" type="seL4_Word"/>
|
||||
<param dir="in" name="data" type="seL4_Word"/>
|
||||
</method>
|
||||
<method id="IA32IOPortOut32" name="Out32">
|
||||
<method id="X86IOPortOut32" name="Out32">
|
||||
<param dir="in" name="port" type="seL4_Word"/>
|
||||
<param dir="in" name="data" type="seL4_Word"/>
|
||||
</method>
|
||||
</interface>
|
||||
|
||||
<interface name="seL4_IRQControl">
|
||||
<method id="IA32IRQIssueIRQHandlerIOAPIC" name="GetIOAPIC">
|
||||
<method id="X86IRQIssueIRQHandlerIOAPIC" name="GetIOAPIC">
|
||||
<param dir="in" name="root" type="seL4_CNode"/>
|
||||
<param dir="in" name="index" type="seL4_Word"/>
|
||||
<param dir="in" name="depth" type="seL4_Word"/>
|
||||
|
|
@ -114,7 +114,7 @@
|
|||
<param dir="in" name="polarity" type="seL4_Word"/>
|
||||
<param dir="in" name="vector" type="seL4_Word"/>
|
||||
</method>
|
||||
<method id="IA32IRQIssueIRQHandlerMSI" name="GetMSI">
|
||||
<method id="X86IRQIssueIRQHandlerMSI" name="GetMSI">
|
||||
<param dir="in" name="root" type="seL4_CNode"/>
|
||||
<param dir="in" name="index" type="seL4_Word"/>
|
||||
<param dir="in" name="depth" type="seL4_Word"/>
|
||||
|
|
|
|||
|
|
@ -16,23 +16,19 @@
|
|||
#endif /* HAVE_AUTOCONF */
|
||||
|
||||
typedef enum _object {
|
||||
seL4_IA32_4K = seL4_ModeObjectTypeCount,
|
||||
seL4_IA32_LargePage,
|
||||
seL4_IA32_PageTableObject,
|
||||
seL4_IA32_PageDirectoryObject,
|
||||
seL4_X86_4K = seL4_ModeObjectTypeCount,
|
||||
seL4_X86_LargePageObject,
|
||||
seL4_X86_PageTableObject,
|
||||
seL4_X86_PageDirectoryObject,
|
||||
#ifdef CONFIG_IOMMU
|
||||
seL4_IA32_IOPageTableObject,
|
||||
seL4_X86_IOPageTableObject,
|
||||
#endif
|
||||
seL4_ObjectTypeCount
|
||||
} seL4_ArchObjectType;
|
||||
typedef seL4_Word object_t;
|
||||
|
||||
#ifndef CONFIG_PAE_PAGING
|
||||
#define seL4_IA32_4M seL4_IA32_LargePage
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_IOMMU
|
||||
#define seL4_IA32_IOPageTableObject 0xffffff
|
||||
#define seL4_X86_IOPageTableObject 0xffffff
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -15,24 +15,24 @@
|
|||
#include <sel4/simple_types.h>
|
||||
#include <sel4/sel4_arch/types.h>
|
||||
|
||||
typedef seL4_CPtr seL4_IA32_ASIDControl;
|
||||
typedef seL4_CPtr seL4_IA32_ASIDPool;
|
||||
typedef seL4_CPtr seL4_IA32_IOSpace;
|
||||
typedef seL4_CPtr seL4_IA32_IOPort;
|
||||
typedef seL4_CPtr seL4_IA32_Page;
|
||||
typedef seL4_CPtr seL4_IA32_PDPT;
|
||||
typedef seL4_CPtr seL4_IA32_PageDirectory;
|
||||
typedef seL4_CPtr seL4_IA32_PageTable;
|
||||
typedef seL4_CPtr seL4_IA32_IOPageTable;
|
||||
typedef seL4_CPtr seL4_X86_ASIDControl;
|
||||
typedef seL4_CPtr seL4_X86_ASIDPool;
|
||||
typedef seL4_CPtr seL4_X86_IOSpace;
|
||||
typedef seL4_CPtr seL4_X86_IOPort;
|
||||
typedef seL4_CPtr seL4_X86_Page;
|
||||
typedef seL4_CPtr seL4_X86_PDPT;
|
||||
typedef seL4_CPtr seL4_X86_PageDirectory;
|
||||
typedef seL4_CPtr seL4_X86_PageTable;
|
||||
typedef seL4_CPtr seL4_X86_IOPageTable;
|
||||
|
||||
typedef enum {
|
||||
seL4_IA32_Default_VMAttributes = 0,
|
||||
seL4_IA32_WriteBack = 0,
|
||||
seL4_IA32_WriteThrough = 1,
|
||||
seL4_IA32_CacheDisabled = 2,
|
||||
seL4_IA32_Uncacheable = 3,
|
||||
seL4_IA32_WriteCombining = 4,
|
||||
SEL4_FORCE_LONG_ENUM(seL4_IA32_VMAttributes),
|
||||
} seL4_IA32_VMAttributes;
|
||||
seL4_X86_Default_VMAttributes = 0,
|
||||
seL4_X86_WriteBack = 0,
|
||||
seL4_X86_WriteThrough = 1,
|
||||
seL4_X86_CacheDisabled = 2,
|
||||
seL4_X86_Uncacheable = 3,
|
||||
seL4_X86_WriteCombining = 4,
|
||||
SEL4_FORCE_LONG_ENUM(seL4_X86_VMAttributes),
|
||||
} seL4_X86_VMAttributes;
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -15,4 +15,132 @@
|
|||
#include <sel4/types.h>
|
||||
#include <sel4/arch/syscalls.h>
|
||||
|
||||
#define IA32_DEPRECATED __attribute__((deprecated("use seL4_X86_* instead of seL4_IA32_*")))
|
||||
|
||||
#define seL4_IA32_PageDirectoryObject _Pragma("seL4_IA32_PageDirectoryObject is depreacted, use seL4_X86_PageDirectoryObject") seL4_X86_PageDirectoryObject
|
||||
#define seL4_IA32_4K _Pragma("seL4_IA32_4K is depreacted, use seL4_X86_4K") seL4_X86_4K
|
||||
#define seL4_IA32_LargePage _Pragma("seL4_IA32_LargePage is depreacted, use seL4_X86_LargePageObject") seL4_X86_LargePageObject
|
||||
#define seL4_IA32_PageTableObject _Pragma("seL4_IA32_PageTableObject is depreacted, use seL4_X86_PageTableObject") seL4_X86_PageTableObject
|
||||
#define seL4_IA32_4M _Pragma("seL4_IA32_4M is depreacted, use seL4_X86_LargePageObject") seL4_X86_LargePageObject
|
||||
|
||||
#define seL4_IA32_Default_VMAttributes _Pragma("seL4_IA32_Default_VMAttributes is depreacted, use seL4_X86_Default_VMAttributes") seL4_X86_Default_VMAttributes
|
||||
#define seL4_IA32_WriteBack _Pragma("seL4_IA32_WriteBack is depreacted, use seL4_X86_WriteBack") seL4_X86_WriteBack
|
||||
#define seL4_IA32_WriteThrough _Pragma("seL4_IA32_WriteThrough is depreacted, use seL4_X86_WriteThrough") seL4_X86_WriteThrough
|
||||
#define seL4_IA32_CacheDisabled _Pragma("seL4_IA32_CacheDisabled is depreacted, use seL4_X86_CacheDisabled") seL4_X86_CacheDisabled
|
||||
#define seL4_IA32_Uncacheable _Pragma("seL4_IA32_Uncacheable is depreacted, use seL4_X86_Uncacheable") seL4_X86_Uncacheable
|
||||
#define seL4_IA32_WriteCombining _Pragma("seL4_IA32_WriteCombining is depreacted, use seL4_X86_WriteCombining") seL4_X86_WriteCombining
|
||||
|
||||
typedef seL4_X86_VMAttributes seL4_IA32_VMAttributes IA32_DEPRECATED;
|
||||
typedef seL4_X86_Page_GetAddress_t seL4_IA32_Page_GetAddress_t IA32_DEPRECATED;
|
||||
typedef seL4_X86_IOPort_In8_t seL4_IA32_IOPort_In8_t IA32_DEPRECATED;
|
||||
typedef seL4_X86_IOPort_In16_t seL4_IA32_IOPort_In16_t IA32_DEPRECATED;
|
||||
typedef seL4_X86_IOPort_In32_t seL4_IA32_IOPort_In32_t IA32_DEPRECATED;
|
||||
typedef seL4_X86_ASIDControl seL4_IA32_ASIDControl IA32_DEPRECATED;
|
||||
typedef seL4_X86_ASIDPool seL4_IA32_ASIDPool IA32_DEPRECATED;
|
||||
typedef seL4_X86_IOSpace seL4_IA32_IOSpace IA32_DEPRECATED;
|
||||
typedef seL4_X86_IOPort seL4_IA32_IOPort IA32_DEPRECATED;
|
||||
typedef seL4_X86_Page seL4_IA32_Page IA32_DEPRECATED;
|
||||
typedef seL4_X86_PDPT seL4_IA32_PDPT IA32_DEPRECATED;
|
||||
typedef seL4_X86_PageDirectory seL4_IA32_PageDirectory IA32_DEPRECATED;
|
||||
typedef seL4_X86_PageTable seL4_IA32_PageTable IA32_DEPRECATED;
|
||||
typedef seL4_X86_IOPageTable seL4_IA32_IOPageTable IA32_DEPRECATED;
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_PageDirectory_Map(seL4_X86_PageDirectory service, seL4_CPtr vroot, seL4_Word vaddr, seL4_X86_VMAttributes attr) {
|
||||
return seL4_X86_PageDirectory_Map(service, vroot, vaddr, attr);
|
||||
}
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_PageDirectory_Unmap(seL4_X86_PageDirectory service) {
|
||||
return seL4_X86_PageDirectory_Unmap(service);
|
||||
}
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_PageTable_Map(seL4_X86_PageTable service, seL4_CPtr vroot, seL4_Word vaddr, seL4_X86_VMAttributes attr) {
|
||||
return seL4_X86_PageTable_Map(service, vroot, vaddr, attr);
|
||||
}
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_PageTable_Unmap(seL4_X86_PageTable service) {
|
||||
return seL4_X86_PageTable_Unmap(service);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_IOMMU
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_IOPageTable_Map(seL4_X86_IOPageTable service, seL4_X86_IOSpace iospace, seL4_Word ioaddr) {
|
||||
return seL4_X86_IOPageTable_Map(service, iospace, ioaddr);
|
||||
}
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_IOPageTable_Unmap(seL4_X86_IOPageTable service) {
|
||||
return seL4_X86_IOPageTable_Unmap(service);
|
||||
}
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_Page_MapIO(seL4_X86_Page service, seL4_X86_IOSpace iospace, seL4_CapRights rights, seL4_Word ioaddr) {
|
||||
return seL4_X86_Page_MapIO(service, iospace, rights, ioaddr);
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_Page_Map(seL4_X86_Page service, seL4_CPtr vroot, seL4_Word vaddr, seL4_CapRights rights, seL4_X86_VMAttributes attr) {
|
||||
return seL4_X86_Page_Map(service, vroot, vaddr, rights, attr);
|
||||
}
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_Page_Remap(seL4_X86_Page service, seL4_CPtr vroot, seL4_CapRights rights, seL4_X86_VMAttributes attr) {
|
||||
return seL4_X86_Page_Remap(service, vroot, rights, attr);
|
||||
}
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_Page_Unmap(seL4_X86_Page service) {
|
||||
return seL4_X86_Page_Unmap(service);
|
||||
}
|
||||
|
||||
static inline seL4_X86_Page_GetAddress_t IA32_DEPRECATED
|
||||
seL4_IA32_Page_GetAddress(seL4_X86_Page service) {
|
||||
return seL4_X86_Page_GetAddress(service);
|
||||
}
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_ASIDControl_MakePool(seL4_X86_ASIDControl service, seL4_Untyped untyped, seL4_CNode root, seL4_Word index, seL4_Uint8 depth) {
|
||||
return seL4_X86_ASIDControl_MakePool(service, untyped, root, index, depth);
|
||||
}
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_ASIDPool_Assign(seL4_X86_ASIDPool service, seL4_CPtr vroot) {
|
||||
return seL4_X86_ASIDPool_Assign(service, vroot);
|
||||
}
|
||||
|
||||
static inline seL4_X86_IOPort_In8_t IA32_DEPRECATED
|
||||
seL4_IA32_IOPort_In8(seL4_X86_IOPort service, seL4_Uint16 port) {
|
||||
return seL4_X86_IOPort_In8(service, port);
|
||||
}
|
||||
|
||||
static inline seL4_X86_IOPort_In16_t IA32_DEPRECATED
|
||||
seL4_IA32_IOPort_In16(seL4_X86_IOPort service, seL4_Uint16 port) {
|
||||
return seL4_X86_IOPort_In16(service, port);
|
||||
}
|
||||
|
||||
static inline seL4_X86_IOPort_In32_t IA32_DEPRECATED
|
||||
seL4_IA32_IOPort_In32(seL4_X86_IOPort service, seL4_Uint16 port) {
|
||||
return seL4_X86_IOPort_In32(service, port);
|
||||
}
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_IOPort_Out8(seL4_X86_IOPort service, seL4_Word port, seL4_Word data) {
|
||||
return seL4_X86_IOPort_Out8(service, port, data);
|
||||
}
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_IOPort_Out16(seL4_X86_IOPort service, seL4_Word port, seL4_Word data) {
|
||||
return seL4_X86_IOPort_Out16(service, port, data);
|
||||
}
|
||||
|
||||
static inline int IA32_DEPRECATED
|
||||
seL4_IA32_IOPort_Out32(seL4_X86_IOPort service, seL4_Word port, seL4_Word data) {
|
||||
return seL4_X86_IOPort_Out32(service, port, data);
|
||||
}
|
||||
|
||||
#undef IA32_DEPRECATED
|
||||
|
||||
#endif /* __ARCH_DEPRECATED_H__ */
|
||||
|
|
|
|||
|
|
@ -245,15 +245,15 @@ def InitTypes():
|
|||
],
|
||||
|
||||
"ia32" : [
|
||||
Type("seL4_IA32_VMAttributes", WORD_SIZE_BITS),
|
||||
CapType("seL4_IA32_ASIDControl"),
|
||||
CapType("seL4_IA32_ASIDPool"),
|
||||
CapType("seL4_IA32_IOSpace"),
|
||||
CapType("seL4_IA32_IOPort"),
|
||||
CapType("seL4_IA32_Page"),
|
||||
CapType("seL4_IA32_PageDirectory"),
|
||||
CapType("seL4_IA32_PageTable"),
|
||||
CapType("seL4_IA32_IOPageTable"),
|
||||
Type("seL4_X86_VMAttributes", WORD_SIZE_BITS),
|
||||
CapType("seL4_X86_IOPort"),
|
||||
CapType("seL4_X86_ASIDControl"),
|
||||
CapType("seL4_X86_ASIDPool"),
|
||||
CapType("seL4_X86_IOSpace"),
|
||||
CapType("seL4_X86_Page"),
|
||||
CapType("seL4_X86_PageDirectory"),
|
||||
CapType("seL4_X86_PageTable"),
|
||||
CapType("seL4_X86_IOPageTable"),
|
||||
StructType("seL4_UserContext", WORD_SIZE_BITS * 13),
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -338,7 +338,7 @@ decodeIA32PageDirectoryInvocation(
|
|||
asid_t asid;
|
||||
cap_t threadRoot;
|
||||
|
||||
if (invLabel == IA32PageDirectoryUnmap) {
|
||||
if (invLabel == X86PageDirectoryUnmap) {
|
||||
if (!isFinalCapability(cte)) {
|
||||
current_syscall_error.type = seL4_RevokeFirst;
|
||||
userError("IA32PageDirectory: Cannot unmap if more than one cap exists.");
|
||||
|
|
@ -360,7 +360,7 @@ decodeIA32PageDirectoryInvocation(
|
|||
return EXCEPTION_NONE;
|
||||
}
|
||||
|
||||
if (invLabel != IA32PageDirectoryMap) {
|
||||
if (invLabel != X86PageDirectoryMap) {
|
||||
userError("IA32PageDirectory: Illegal operation.");
|
||||
current_syscall_error.type = seL4_IllegalOperation;
|
||||
return EXCEPTION_SYSCALL_ERROR;
|
||||
|
|
|
|||
|
|
@ -116,7 +116,7 @@ cap_t
|
|||
Mode_createObject(object_t t, void *regionBase, word_t userSize)
|
||||
{
|
||||
switch (t) {
|
||||
case seL4_IA32_4K:
|
||||
case seL4_X86_4K:
|
||||
memzero(regionBase, 1 << pageBitsForSize(IA32_SmallPage));
|
||||
return cap_frame_cap_new(
|
||||
IA32_SmallPage, /* capFSize */
|
||||
|
|
@ -128,7 +128,7 @@ Mode_createObject(object_t t, void *regionBase, word_t userSize)
|
|||
(word_t)regionBase /* capFBasePtr */
|
||||
);
|
||||
|
||||
case seL4_IA32_LargePage:
|
||||
case seL4_X86_LargePageObject:
|
||||
memzero(regionBase, 1 << pageBitsForSize(IA32_LargePage));
|
||||
return cap_frame_cap_new(
|
||||
IA32_LargePage, /* capFSize */
|
||||
|
|
@ -140,7 +140,7 @@ Mode_createObject(object_t t, void *regionBase, word_t userSize)
|
|||
(word_t)regionBase /* capFBasePtr */
|
||||
);
|
||||
|
||||
case seL4_IA32_PageTableObject:
|
||||
case seL4_X86_PageTableObject:
|
||||
memzero(regionBase, 1 << seL4_PageTableBits);
|
||||
return cap_page_table_cap_new(
|
||||
0, /* capPTIsMapped */
|
||||
|
|
@ -149,7 +149,7 @@ Mode_createObject(object_t t, void *regionBase, word_t userSize)
|
|||
(word_t)regionBase /* capPTBasePtr */
|
||||
);
|
||||
|
||||
case seL4_IA32_PageDirectoryObject:
|
||||
case seL4_X86_PageDirectoryObject:
|
||||
memzero(regionBase, 1 << seL4_PageDirBits);
|
||||
#ifndef CONFIG_PAE_PAGING
|
||||
copyGlobalMappings(regionBase);
|
||||
|
|
@ -173,7 +173,7 @@ Mode_createObject(object_t t, void *regionBase, word_t userSize)
|
|||
);
|
||||
#endif
|
||||
|
||||
case seL4_IA32_IOPageTableObject:
|
||||
case seL4_X86_IOPageTableObject:
|
||||
memzero(regionBase, 1 << VTD_PT_SIZE_BITS);
|
||||
return cap_io_page_table_cap_new(
|
||||
0, /* capIOPTIsMapped */
|
||||
|
|
|
|||
|
|
@ -754,7 +754,7 @@ exception_t decodeX86FrameInvocation(
|
|||
)
|
||||
{
|
||||
switch (invLabel) {
|
||||
case IA32PageMap: { /* Map */
|
||||
case X86PageMap: { /* Map */
|
||||
word_t vaddr;
|
||||
word_t vtop;
|
||||
word_t w_rightsMask;
|
||||
|
|
@ -918,7 +918,7 @@ exception_t decodeX86FrameInvocation(
|
|||
return EXCEPTION_NONE;
|
||||
}
|
||||
|
||||
case IA32PageRemap: { /* Remap */
|
||||
case X86PageRemap: { /* Remap */
|
||||
word_t vaddr;
|
||||
word_t w_rightsMask;
|
||||
paddr_t paddr;
|
||||
|
|
@ -1052,7 +1052,7 @@ exception_t decodeX86FrameInvocation(
|
|||
return EXCEPTION_NONE;
|
||||
}
|
||||
|
||||
case IA32PageUnmap: { /* Unmap */
|
||||
case X86PageUnmap: { /* Unmap */
|
||||
if (cap_frame_cap_get_capFMappedASID(cap) != asidInvalid) {
|
||||
if (isIOSpaceFrame(cap)) {
|
||||
return decodeIA32IOUnMapInvocation(invLabel, length, cte, cap, excaps);
|
||||
|
|
@ -1071,11 +1071,11 @@ exception_t decodeX86FrameInvocation(
|
|||
return EXCEPTION_NONE;
|
||||
}
|
||||
|
||||
case IA32PageMapIO: { /* MapIO */
|
||||
case X86PageMapIO: { /* MapIO */
|
||||
return decodeIA32IOMapInvocation(invLabel, length, cte, cap, excaps, buffer);
|
||||
}
|
||||
|
||||
case IA32PageGetAddress: {
|
||||
case X86PageGetAddress: {
|
||||
/* Return it in the first message register. */
|
||||
assert(n_msgRegisters >= 1);
|
||||
|
||||
|
|
@ -1108,7 +1108,7 @@ decodeX86PageTableInvocation(
|
|||
paddr_t paddr;
|
||||
asid_t asid;
|
||||
|
||||
if (invLabel == IA32PageTableUnmap) {
|
||||
if (invLabel == X86PageTableUnmap) {
|
||||
if (! isFinalCapability(cte)) {
|
||||
current_syscall_error.type = seL4_RevokeFirst;
|
||||
userError("IA32PageTable: Cannot unmap if more than one cap exists.");
|
||||
|
|
@ -1130,7 +1130,7 @@ decodeX86PageTableInvocation(
|
|||
return EXCEPTION_NONE;
|
||||
}
|
||||
|
||||
if (invLabel != IA32PageTableMap ) {
|
||||
if (invLabel != X86PageTableMap ) {
|
||||
userError("IA32PageTable: Illegal operation.");
|
||||
current_syscall_error.type = seL4_IllegalOperation;
|
||||
return EXCEPTION_SYSCALL_ERROR;
|
||||
|
|
@ -1253,7 +1253,7 @@ exception_t decodeX86MMUInvocation(
|
|||
void* frame;
|
||||
exception_t status;
|
||||
|
||||
if (invLabel != IA32ASIDControlMakePool) {
|
||||
if (invLabel != X86ASIDControlMakePool) {
|
||||
current_syscall_error.type = seL4_IllegalOperation;
|
||||
|
||||
return EXCEPTION_SYSCALL_ERROR;
|
||||
|
|
@ -1321,7 +1321,7 @@ exception_t decodeX86MMUInvocation(
|
|||
word_t i;
|
||||
asid_t asid;
|
||||
|
||||
if (invLabel != IA32ASIDPoolAssign) {
|
||||
if (invLabel != X86ASIDPoolAssign) {
|
||||
current_syscall_error.type = seL4_IllegalOperation;
|
||||
|
||||
return EXCEPTION_SYSCALL_ERROR;
|
||||
|
|
|
|||
|
|
@ -168,7 +168,7 @@ Arch_decodeIRQControlInvocation(word_t invLabel, word_t length, cte_t *srcSlot,
|
|||
}
|
||||
|
||||
switch (invLabel) {
|
||||
case IA32IRQIssueIRQHandlerIOAPIC: {
|
||||
case X86IRQIssueIRQHandlerIOAPIC: {
|
||||
word_t ioapic = getSyscallArg(2, buffer);
|
||||
word_t pin = getSyscallArg(3, buffer);
|
||||
word_t level = getSyscallArg(4, buffer);
|
||||
|
|
@ -189,7 +189,7 @@ Arch_decodeIRQControlInvocation(word_t invLabel, word_t length, cte_t *srcSlot,
|
|||
return invokeIssueIRQHandlerIOAPIC(irq, ioapic, pin, level, polarity, vector, destSlot, srcSlot);
|
||||
}
|
||||
break;
|
||||
case IA32IRQIssueIRQHandlerMSI: {
|
||||
case X86IRQIssueIRQHandlerMSI: {
|
||||
word_t pci_bus = getSyscallArg(2, buffer);
|
||||
word_t pci_dev = getSyscallArg(3, buffer);
|
||||
word_t pci_func = getSyscallArg(4, buffer);
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ decodeIA32PortInvocation(
|
|||
return EXCEPTION_SYSCALL_ERROR;
|
||||
}
|
||||
|
||||
if (invLabel == IA32IOPortOut8 || invLabel == IA32IOPortOut16 || invLabel == IA32IOPortOut32) {
|
||||
if (invLabel == X86IOPortOut8 || invLabel == X86IOPortOut16 || invLabel == X86IOPortOut32) {
|
||||
/* Ensure the incoming message is long enough for the write. */
|
||||
if (length < 2) {
|
||||
userError("IOPort Out32: Truncated message.");
|
||||
|
|
@ -71,7 +71,7 @@ decodeIA32PortInvocation(
|
|||
port = getSyscallArg(0, buffer) & 0xffff;
|
||||
|
||||
switch (invLabel) {
|
||||
case IA32IOPortIn8: { /* inport 8 bits */
|
||||
case X86IOPortIn8: { /* inport 8 bits */
|
||||
|
||||
/* Check we are allowed to perform the operation. */
|
||||
ret = ensurePortOperationAllowed(cap, port, 1);
|
||||
|
|
@ -85,7 +85,7 @@ decodeIA32PortInvocation(
|
|||
break;
|
||||
}
|
||||
|
||||
case IA32IOPortIn16: { /* inport 16 bits */
|
||||
case X86IOPortIn16: { /* inport 16 bits */
|
||||
|
||||
/* Check we are allowed to perform the operation. */
|
||||
ret = ensurePortOperationAllowed(cap, port, 2);
|
||||
|
|
@ -99,7 +99,7 @@ decodeIA32PortInvocation(
|
|||
break;
|
||||
}
|
||||
|
||||
case IA32IOPortIn32: { /* inport 32 bits */
|
||||
case X86IOPortIn32: { /* inport 32 bits */
|
||||
|
||||
/* Check we are allowed to perform the operation. */
|
||||
ret = ensurePortOperationAllowed(cap, port, 4);
|
||||
|
|
@ -113,7 +113,7 @@ decodeIA32PortInvocation(
|
|||
break;
|
||||
}
|
||||
|
||||
case IA32IOPortOut8: { /* outport 8 bits */
|
||||
case X86IOPortOut8: { /* outport 8 bits */
|
||||
uint8_t data;
|
||||
|
||||
/* Check we are allowed to perform the operation. */
|
||||
|
|
@ -129,7 +129,7 @@ decodeIA32PortInvocation(
|
|||
break;
|
||||
}
|
||||
|
||||
case IA32IOPortOut16: { /* outport 16 bits */
|
||||
case X86IOPortOut16: { /* outport 16 bits */
|
||||
uint16_t data;
|
||||
|
||||
/* Check we are allowed to perform the operation. */
|
||||
|
|
@ -145,7 +145,7 @@ decodeIA32PortInvocation(
|
|||
break;
|
||||
}
|
||||
|
||||
case IA32IOPortOut32: { /* outport 32 bits */
|
||||
case X86IOPortOut32: { /* outport 32 bits */
|
||||
uint32_t data;
|
||||
|
||||
/* Check we are allowed to perform the operation. */
|
||||
|
|
|
|||
|
|
@ -129,7 +129,7 @@ decodeIA32IOPTInvocation(
|
|||
vtd_cte_t* vtd_context_slot;
|
||||
vtd_pte_t* vtd_pte;
|
||||
|
||||
if (invLabel == IA32IOPageTableUnmap) {
|
||||
if (invLabel == X86IOPageTableUnmap) {
|
||||
deleteIOPageTable(slot->cap);
|
||||
slot->cap = cap_io_page_table_cap_set_capIOPTIsMapped(slot->cap, 0);
|
||||
|
||||
|
|
@ -142,7 +142,7 @@ decodeIA32IOPTInvocation(
|
|||
return EXCEPTION_SYSCALL_ERROR;
|
||||
}
|
||||
|
||||
if (invLabel != IA32IOPageTableMap ) {
|
||||
if (invLabel != X86IOPageTableMap ) {
|
||||
current_syscall_error.type = seL4_IllegalOperation;
|
||||
return EXCEPTION_SYSCALL_ERROR;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -395,17 +395,17 @@ word_t
|
|||
Arch_getObjectSize(word_t t)
|
||||
{
|
||||
switch (t) {
|
||||
case seL4_IA32_4K:
|
||||
case seL4_X86_4K:
|
||||
return pageBitsForSize(IA32_SmallPage);
|
||||
case seL4_IA32_LargePage:
|
||||
case seL4_X86_LargePageObject:
|
||||
return pageBitsForSize(IA32_LargePage);
|
||||
case seL4_IA32_PageTableObject:
|
||||
case seL4_X86_PageTableObject:
|
||||
return seL4_PageTableBits;
|
||||
case seL4_IA32_PageDirectoryObject:
|
||||
case seL4_X86_PageDirectoryObject:
|
||||
return seL4_PageDirBits;
|
||||
case seL4_IA32_PDPTObject:
|
||||
return seL4_PDPTBits;
|
||||
case seL4_IA32_IOPageTableObject:
|
||||
case seL4_X86_IOPageTableObject:
|
||||
return VTD_PT_SIZE_BITS;
|
||||
default:
|
||||
return Mode_getObjectSize(t);
|
||||
|
|
|
|||
Loading…
Reference in a new issue