I fixed following bugs in EDKII.

1. In AsmFuncs.asm, DebugSupport, Vect2Desc() function will use hardcode CS to fill the IDT. 20h for Ia32.If the system CS is changed by CPU driver, this driver can not work. System maybe crash.
2. In EBC, RegisterExceptionCallback() can not restore the environment and I add some enhancements.
3. In Image.c, CoreLoadImageCommon never return EFI_SECURITY_VIOLATION when SecurityStatus == EFI_SECURITY_VIOLATION.
4. In Variable.c, 1. There're additional unnecessary loop. All blocks will be gone through even if all the data has been written. We should check the "CurrWriteSize" to see if there's no more data to write, and stop the for loop immediately. 2 "if.else." can be merged to save lines of code.
5. in FvbServices,c, Checksum calculation error.


git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@1891 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
mikewuping
2006-11-03 03:34:43 +00:00
parent 511710d68f
commit c91eaa3d55
7 changed files with 305 additions and 154 deletions

View File

@@ -189,7 +189,8 @@ Vect2Desc PROC C PUBLIC DestPtr:DWORD, Vector:DWORD
mov eax, Vector
mov ecx, DestPtr
mov word ptr [ecx], ax ; write bits 15..0 of offset
mov word ptr [ecx+2], 20h ; SYS_CODE_SEL from GDT
mov dx, cs
mov word ptr [ecx+2], dx ; SYS_CODE_SEL from GDT
mov word ptr [ecx+4], 0e00h OR 8000h ; type = 386 interrupt gate, present
shr eax, 16
mov word ptr [ecx+6], ax ; write bits 31..16 of offset