regop.isa (5853:606b9525071d) | regop.isa (5855:d4e54239ed37) |
---|---|
1// Copyright (c) 2007-2008 The Hewlett-Packard Development Company 2// All rights reserved. 3// 4// Redistribution and use of this software in source and binary forms, 5// with or without modification, are permitted provided that the 6// following conditions are met: 7// 8// The software must be used only for Non-Commercial Use which means any --- 220 unchanged lines hidden (view full) --- 229 230output header {{ 231 void 232 divide(uint64_t dividend, uint64_t divisor, 233 uint64_t "ient, uint64_t &remainder); 234 235 enum SegmentSelectorCheck { 236 SegNoCheck, SegCSCheck, SegCallGateCheck, SegIntGateCheck, | 1// Copyright (c) 2007-2008 The Hewlett-Packard Development Company 2// All rights reserved. 3// 4// Redistribution and use of this software in source and binary forms, 5// with or without modification, are permitted provided that the 6// following conditions are met: 7// 8// The software must be used only for Non-Commercial Use which means any --- 220 unchanged lines hidden (view full) --- 229 230output header {{ 231 void 232 divide(uint64_t dividend, uint64_t divisor, 233 uint64_t "ient, uint64_t &remainder); 234 235 enum SegmentSelectorCheck { 236 SegNoCheck, SegCSCheck, SegCallGateCheck, SegIntGateCheck, |
237 SegSSCheck, SegIretCheck, SegIntCSCheck | 237 SegSoftIntGateCheck, SegSSCheck, SegIretCheck, SegIntCSCheck |
238 }; 239 240 enum LongModeDescriptorType { 241 LDT64 = 2, 242 AvailableTSS64 = 9, 243 BusyTSS64 = 0xb, 244 CallGate64 = 0xc, 245 IntGate64 = 0xe, --- 815 unchanged lines hidden (view full) --- 1061 break; 1062 case SegCSCheck: 1063 panic("CS checks for far calls/jumps not implemented.\\n"); 1064 break; 1065 case SegCallGateCheck: 1066 panic("CS checks for far calls/jumps through call gates" 1067 "not implemented.\\n"); 1068 break; | 238 }; 239 240 enum LongModeDescriptorType { 241 LDT64 = 2, 242 AvailableTSS64 = 9, 243 BusyTSS64 = 0xb, 244 CallGate64 = 0xc, 245 IntGate64 = 0xe, --- 815 unchanged lines hidden (view full) --- 1061 break; 1062 case SegCSCheck: 1063 panic("CS checks for far calls/jumps not implemented.\\n"); 1064 break; 1065 case SegCallGateCheck: 1066 panic("CS checks for far calls/jumps through call gates" 1067 "not implemented.\\n"); 1068 break; |
1069 case SegIntGateCheck: | 1069 case SegSoftIntGateCheck: |
1070 // Check permissions. 1071 if (desc.dpl < m5reg.cpl) { 1072 fault = new GeneralProtection((uint16_t)selector); 1073 } | 1070 // Check permissions. 1071 if (desc.dpl < m5reg.cpl) { 1072 fault = new GeneralProtection((uint16_t)selector); 1073 } |
1074 // Fall through on purpose 1075 case SegIntGateCheck: |
|
1074 // Make sure the gate's the right type. 1075 if (m5reg.mode == LongMode && ((desc.type & 0xe) != 0xe) || 1076 ((desc.type & 0x6) != 0x6)) { 1077 fault = new GeneralProtection(0); 1078 } 1079 break; 1080 case SegSSCheck: 1081 if (selector.si || selector.ti) { --- 127 unchanged lines hidden --- | 1076 // Make sure the gate's the right type. 1077 if (m5reg.mode == LongMode && ((desc.type & 0xe) != 0xe) || 1078 ((desc.type & 0x6) != 0x6)) { 1079 fault = new GeneralProtection(0); 1080 } 1081 break; 1082 case SegSSCheck: 1083 if (selector.si || selector.ti) { --- 127 unchanged lines hidden --- |