mirror of https://github.com/FDOS/kernel.git
Correct get_root, make kbdType public, sys config patches from Tom.
git-svn-id: https://svn.code.sf.net/p/freedos/svn/kernel/trunk@614 6ac86273-5f31-0410-b378-82cca8765d1b
This commit is contained in:
parent
f98fc8640b
commit
9f15e02db9
|
@ -11,8 +11,7 @@
|
|||
+ Changes Eric Auer
|
||||
* add sanity check to initdisk.c for (driveParam->chs.Sector == 0)
|
||||
+ some display tweaks
|
||||
* add ANYDOS, KBDRATE, VIDMODE, MENUCOLOR and EECHO support to the
|
||||
config.sys parser.
|
||||
* add EECHO (echo with $=ESC) support to the config.sys parser.
|
||||
* distinguish between the builtin DOS version and the settable
|
||||
DOS version.
|
||||
* console.asm now accepts extended scancodes (modified by Bart)
|
||||
|
@ -47,6 +46,9 @@
|
|||
* Fix problem with attributes with the volume label bit + findnext
|
||||
* SYS: avoid copying kernel.sys and command.com if the destination
|
||||
is identical to the source.
|
||||
* Fix bug in DeleteBlockInBufferCache: needs to make the block
|
||||
invalid, not flush it, if we're writing.
|
||||
* added switches=/k/n/f support to the config.sys parser.
|
||||
2003 Mar 14 - Build 2029
|
||||
-------- Bart Oldeman (bart@dosemu.org)
|
||||
+ Changes Tom
|
||||
|
|
|
@ -54,7 +54,8 @@ segment _LOWTEXT
|
|||
|
||||
uScanCode db 0 ; Scan code for con: device
|
||||
|
||||
kbdType db 0 ; 00 for 84key, 10h for 102key
|
||||
global _kbdType
|
||||
_kbdType db 0 ; 00 for 84key, 10h for 102key
|
||||
|
||||
global ConInit
|
||||
ConInit:
|
||||
|
@ -62,7 +63,7 @@ ConInit:
|
|||
mov ds,ax
|
||||
mov al,[96h]
|
||||
and al,10h
|
||||
mov byte[cs:kbdType],al ; enhanced keyboard if bit 4 set
|
||||
mov byte[cs:_kbdType],al ; enhanced keyboard if bit 4 set
|
||||
jmp _IOExit
|
||||
|
||||
;
|
||||
|
@ -90,7 +91,7 @@ ConRead2:
|
|||
|
||||
|
||||
readkey:
|
||||
mov ah,[cs:kbdType]
|
||||
mov ah,[cs:_kbdType]
|
||||
int 16h
|
||||
checke0: cmp al,0xe0 ; must check for 0xe0 scan code
|
||||
jne .ret
|
||||
|
@ -152,7 +153,7 @@ CommonNdRdExit: ; *** tell if key waiting and return its ASCII if yes
|
|||
or al,al ; Was it zero ?
|
||||
jnz ConNdRd2 ; Jump if there's a char waiting
|
||||
mov ah,1
|
||||
add ah,[cs:kbdType]
|
||||
add ah,[cs:_kbdType]
|
||||
int 16h ; Get status, if zf=0 al=char
|
||||
jz ConNdRd4 ; Jump if no char available
|
||||
call checke0 ; check for e0 scancode
|
||||
|
@ -194,7 +195,7 @@ KbdInpChar: ; *** get ??00 or the last waiting key after flushing the queue
|
|||
mov byte [cs:uScanCode],al
|
||||
KbdInpCh1:
|
||||
mov ah,1
|
||||
add ah,[cs:kbdType]
|
||||
add ah,[cs:_kbdType]
|
||||
int 16h ; get status, if zf=0 al=char
|
||||
jz KbdInpRtnZero ; Jump if zero
|
||||
; returns 0 or the last key that was waiting in AL
|
||||
|
|
|
@ -448,8 +448,10 @@ const char FAR *get_root(const char FAR * fname)
|
|||
{
|
||||
length--;
|
||||
c = *--fname;
|
||||
if (c == '/' || c == '\\' || c == ':')
|
||||
if (c == '/' || c == '\\' || c == ':') {
|
||||
fname++;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return fname;
|
||||
}
|
||||
|
|
|
@ -654,8 +654,11 @@ EmulatedDriveStatus(int drive,char statusOnly)
|
|||
|
||||
void CheckContinueBootFromHarddisk(void)
|
||||
{
|
||||
char *bootedFrom = "CD";
|
||||
char *bootedFrom = "Floppy/CD";
|
||||
iregs r;
|
||||
int key;
|
||||
|
||||
__int__(3); /* necessary for some strange reasons ?? (TE) */
|
||||
|
||||
if (InitKernelConfig.BootHarddiskSeconds == 0)
|
||||
return;
|
||||
|
@ -677,12 +680,15 @@ void CheckContinueBootFromHarddisk(void)
|
|||
"\n"
|
||||
"\n"
|
||||
" Hit any key within %d seconds to continue booot from %s\n"
|
||||
" else continue to boot from Harddisk\n",
|
||||
" Hit 'H' or wait %d seconds to boot from Harddisk\n",
|
||||
InitKernelConfig.BootHarddiskSeconds,
|
||||
bootedFrom
|
||||
bootedFrom,
|
||||
InitKernelConfig.BootHarddiskSeconds
|
||||
);
|
||||
|
||||
if (GetBiosKey(InitKernelConfig.BootHarddiskSeconds) != (UWORD)-1)
|
||||
key = GetBiosKey(InitKernelConfig.BootHarddiskSeconds);
|
||||
|
||||
if (key != (UWORD)-1 && (key & 0xff) != 'h' && (key & 0xff) != 'H' )
|
||||
{
|
||||
/* user has hit a key, continue to boot from floppy/CD */
|
||||
printf("\n");
|
||||
|
|
|
@ -84,7 +84,8 @@ void showUsage(void)
|
|||
" the value set will be the rightmost one.\n");
|
||||
printf(" Current Options are: DLASORT=0|1, SHOWDRIVEASSIGNMENT=0|1\n"
|
||||
" SKIPCONFIGSECONDS=#, FORCELBA=0|1\n"
|
||||
" GLOBALENABLELBASUPPORT=0|1\n");
|
||||
" GLOBALENABLELBASUPPORT=0|1\n"
|
||||
" BootHarddiskSeconds=0|seconds to wait\n");
|
||||
}
|
||||
|
||||
/* simply reads in current configuration values, exiting program
|
||||
|
|
Loading…
Reference in New Issue