bits 16
section .text16
not_com32r:
- mov si,KernelCName
+ mov si,KernelName
call writestr
mov si,not_com32r_msg
call writestr
pm_call comboot_cleanup_lowmem
call adjust_screen ; The COMBOOT program might have changed the screen
jcxz .nomsg
- mov si,KernelCName
+ mov si,KernelName
call writestr
mov si,cx
call writestr
; fs.c
extern fs_init, pm_searchdir, getfssec, pm_mangle_name, load_config
- extern pm_unmangle_name, close_file
+ extern close_file
; chdir.c
extern pm_realpath
this_fs->fs_ops->mangle_name(dst, src);
}
-void pm_unmangle_name(com32sys_t *regs)
-{
- const char *src = MK_PTR(regs->ds, regs->esi.w[0]);
- char *dst = MK_PTR(regs->es, regs->edi.w[0]);
-
- dst = stpcpy(dst, src);
-
- /* Update the di register to point to the last null char */
- regs->edi.w[0] = OFFS_WRT(dst, regs->es);
-}
-
void getfssec(com32sys_t *regs)
{
int sectors;
(void)regs;
/* Save configuration file as an absolute path for posterity */
- realpath(ConfigName, KernelCName, FILENAME_MAX);
+ realpath(ConfigName, KernelName, FILENAME_MAX);
/* If we got anything on the command line, do a chdir */
p = cmd_line;
extern char KernelName[];
extern char cmd_line[];
extern char ConfigFile[];
-extern char KernelCName[];
/* diskstart.inc isolinux.asm*/
extern void getlinsec(void);
/* fs.c */
void pm_mangle_name(com32sys_t *);
-void pm_unmangle_name(com32sys_t *);
void pm_searchdir(com32sys_t *);
void mangle_name(char *, const char *);
-char *unmangle_name(char *, const char *);
int searchdir(const char *name);
void _close_file(struct file *);
size_t pmapi_read_file(uint16_t *handle, void *buf, size_t sectors);
err_noparm db 'Missing parameter in configuration file. Keyword: ',0
section .uibss
- global KernelName
alignb 4
vk_size equ (vk_end + 3) & ~3
VKernelBuf: resb vk_size ; "Current" vkernel
section .bss16
KbdMap resb 256 ; Keyboard map
FKeyName resb MAX_FKEYS*FILENAME_MAX ; File names for F-key help
-InitRDCNameLen resw 1 ; Length of unmangled initrd name
- global KernelName, KernelCName
+ global KernelName
KernelName resb FILENAME_MAX ; Mangled name for kernel
-KernelCName resb FILENAME_MAX ; Unmangled kernel name
-InitRDCName resb FILENAME_MAX ; Unmangled initrd name
MNameBuf resb FILENAME_MAX
InitRD resb FILENAME_MAX
mov cx,7 ; "initrd="
rep movsb
mov si,InitRD
- pm_call pm_unmangle_name
- mov al,' '
- stosb
+ call strcpy
+ mov byte [es:di-1],' '
; For better compression, clean up the append field
.noinitrd:
mov si,boot_image ; BOOT_IMAGE=
mov cx,boot_image_len
rep movsb
- mov si,KernelCName ; Unmangled kernel name
+ mov si,KernelName ; Unmangled kernel name
call strcpy
mov byte [es:di-1],' ' ; Follow by space
any_kernel:
mov si,loading_msg
call writestr_qchk
- mov si,KernelCName ; Print kernel name part of
+ mov si,KernelName ; Print kernel name part of
call writestr_qchk ; "Loading" message
;
mov ds,ax
mov es,ax
push edi
- mov si,InitRD
- mov di,InitRDCName
- pm_call pm_unmangle_name ; Create human-readable name
- sub di,InitRDCName
- mov [InitRDCNameLen],di
mov di,InitRD
pm_call pm_searchdir ; Look for it in directory
pop edi
push si
mov si,crlfloading_msg ; Write "Loading "
call writestr_qchk
- mov si,InitRDCName ; Write ramdisk name
+ mov si,InitRD ; Write ramdisk name
call writestr_qchk
mov si,dotdot_msg ; Write dots
call writestr_qchk
.notthere:
mov si,err_noinitrd
call writestr
- mov si,InitRDCName
+ mov si,InitRD
call writestr
mov si,crlf_msg
jmp abort_load
and cx,cx
jnz on_error
.really:
- mov si,KernelName
- mov di,KernelCName
- push di
- pm_call pm_unmangle_name ; Get human form
mov si,err_notfound ; Complain about missing kernel
call writestr
- pop si ; KernelCName
+ mov si,KernelName
call writestr
mov si,crlf_msg
jmp abort_load ; Ask user for clue
mov [KeepPXE],al
%endif
- mov si,KernelName
- mov di,KernelCName
- pm_call pm_unmangle_name
-
; Default memory limit, can be overridden by image loaders
mov eax,[HighMemRsvd]
mov [MyHighMemSize],eax