wok-6.x rev 22170
linld: clear heap in moverm
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Fri Nov 08 10:47:52 2019 +0100 (2019-11-08) |
parents | 8a056aec03a0 |
children | 19141648d795 |
files | c-client/receipt fastthread/receipt file-tail/receipt larch/receipt linld/stuff/src/A20.ASM linld/stuff/src/COMMON.H linld/stuff/src/CRTL.ASM linld/stuff/src/CRTL.H linld/stuff/src/LINLD.CPP linld/stuff/src/LOAD.CPP linld/stuff/src/TAZBOOT.CPP linld/stuff/src/_BEG.ASM linld/stuff/src/pipehole.awk rack/receipt rails/receipt rake/receipt spruz/receipt |
line diff
1.1 --- a/c-client/receipt Fri Nov 08 10:09:23 2019 +0100 1.2 +++ b/c-client/receipt Fri Nov 08 10:47:52 2019 +0100 1.3 @@ -6,7 +6,7 @@ 1.4 SHORT_DESC="mail store formats support." 1.5 MAINTAINER="pascal.bellard@slitaz.org" 1.6 LICENSE="Apache" 1.7 -WEB_SITE="http://www.washington.edu/imap/" 1.8 +WEB_SITE="https://www.washington.edu/imap/" 1.9 SOURCE="imap" 1.10 TARBALL="$SOURCE-$VERSION.tar.gz" 1.11 WGET_URL="ftp://ftp.cac.washington.edu/mail/$TARBALL"
2.1 --- a/fastthread/receipt Fri Nov 08 10:09:23 2019 +0100 2.2 +++ b/fastthread/receipt Fri Nov 08 10:47:52 2019 +0100 2.3 @@ -17,7 +17,7 @@ 2.4 # Rules to configure and make the package. 2.5 compile_rules() 2.6 { 2.7 - local _gemdir="$(ruby -rubygems -e'puts Gem.default_dir')" 2.8 + local _gemdir="$(ruby -rrubygems -e'puts Gem.default_dir')" 2.9 gem install --ignore-dependencies -i "$DESTDIR/$_gemdir" $SOURCES_REPOSITORY/$TARBALL 2.10 } 2.11
3.1 --- a/file-tail/receipt Fri Nov 08 10:09:23 2019 +0100 3.2 +++ b/file-tail/receipt Fri Nov 08 10:47:52 2019 +0100 3.3 @@ -18,7 +18,7 @@ 3.4 # Rules to configure and make the package. 3.5 compile_rules() 3.6 { 3.7 - local _gemdir="$(ruby -rubygems -e'puts Gem.default_dir')" 3.8 + local _gemdir="$(ruby -rrubygems -e'puts Gem.default_dir')" 3.9 gem install \ 3.10 --ignore-dependencies \ 3.11 -i "$DESTDIR/$_gemdir" \
4.1 --- a/larch/receipt Fri Nov 08 10:09:23 2019 +0100 4.2 +++ b/larch/receipt Fri Nov 08 10:47:52 2019 +0100 4.3 @@ -16,7 +16,7 @@ 4.4 # Rules to configure and make the package. 4.5 compile_rules() 4.6 { 4.7 - local _gemdir="$(ruby -rubygems -e'puts Gem.default_dir')" 4.8 + local _gemdir="$(ruby -rrubygems -e'puts Gem.default_dir')" 4.9 gem install --ignore-dependencies -i "$DESTDIR/$_gemdir" larch 4.10 } 4.11
5.1 --- a/linld/stuff/src/A20.ASM Fri Nov 08 10:09:23 2019 +0100 5.2 +++ b/linld/stuff/src/A20.ASM Fri Nov 08 10:47:52 2019 +0100 5.3 @@ -124,8 +124,10 @@ 5.4 mov cx,[bx-5] ; size 5.5 mov si,[bx-2] ; data 5.6 xor di,di 5.7 - rep 5.8 - movsb 5.9 +@@move_clear: 5.10 + movsb 5.11 + mov [byte si-1],0 5.12 + loop @@move_clear 5.13 ;push ds 5.14 ;pop es 5.15 ;pop di si
6.1 --- a/linld/stuff/src/COMMON.H Fri Nov 08 10:09:23 2019 +0100 6.2 +++ b/linld/stuff/src/COMMON.H Fri Nov 08 10:47:52 2019 +0100 6.3 @@ -72,6 +72,7 @@ 6.4 #define prev(p) --p 6.5 #endif 6.6 extern char vcpi; 6.7 +extern char version_string[]; 6.8 extern const char* kernel_name; 6.9 extern const char* initrd_name; 6.10 extern const char* cmdline; 6.11 @@ -93,6 +94,6 @@ 6.12 void load_image(struct image_himem *m); 6.13 extern _fastcall void open_image(struct image_himem *m, const char *name); 6.14 extern _fastcall int read_image(struct image_himem *m); 6.15 -char* load_kernel(); 6.16 +void load_kernel(); 6.17 void load_initrd(); 6.18 extern "C" void boot_kernel();
7.1 --- a/linld/stuff/src/CRTL.ASM Fri Nov 08 10:09:23 2019 +0100 7.2 +++ b/linld/stuff/src/CRTL.ASM Fri Nov 08 10:47:52 2019 +0100 7.3 @@ -478,15 +478,8 @@ 7.4 include "himem.inc" 7.5 7.6 ;*************************************************************** 7.7 -;_fastcall char* strdup(bx:const char* a); 7.8 ;_fastcall char* malloc_or_die(ax:unsigned size); 7.9 ;*************************************************************** 7.10 - global @strdup$qpxzc:near 7.11 -@strdup$qpxzc: 7.12 - mov ax,[_heap_top] 7.13 - xchg ax,bx 7.14 - call @strcpy$qpxzct1 ; bx = strcpy(bx, ax) end +1 7.15 - xchg ax,bx 7.16 xchg_heap_top: 7.17 xchg ax,[_heap_top] 7.18 ret
8.1 --- a/linld/stuff/src/CRTL.H Fri Nov 08 10:09:23 2019 +0100 8.2 +++ b/linld/stuff/src/CRTL.H Fri Nov 08 10:47:52 2019 +0100 8.3 @@ -22,7 +22,6 @@ 8.4 void parse_cmdline(); 8.5 extern _fastcall void strcatb(const char* a,const char* b); 8.6 extern _fastcall void strcpy(const char* a,const char* b); 8.7 -extern _fastcall int strdup(const char* a); 8.8 #ifdef USE_ARGSTR 8.9 extern _fastcall int argstr(const char *s, const char keywords[], const char **var); 8.10 extern _fastcall int argnum(char *s, const char keywords[], unsigned long *var);
9.1 --- a/linld/stuff/src/LINLD.CPP Fri Nov 08 10:09:23 2019 +0100 9.2 +++ b/linld/stuff/src/LINLD.CPP Fri Nov 08 10:47:52 2019 +0100 9.3 @@ -75,7 +75,8 @@ 9.4 boot: 9.5 puts(*clp); 9.6 set_cmdline(*clp); 9.7 - puts(load_kernel()); 9.8 + load_kernel(); 9.9 + puts(version_string); 9.10 load_initrd(); 9.11 boot_kernel(); 9.12 } 9.13 @@ -88,7 +89,8 @@ 9.14 argv++; 9.15 s=*argv; 9.16 if (!s) { 9.17 - puts(load_kernel()); 9.18 + load_kernel(); 9.19 + puts(version_string); 9.20 load_initrd(); 9.21 boot_kernel(); 9.22 }
10.1 --- a/linld/stuff/src/LOAD.CPP Fri Nov 08 10:09:23 2019 +0100 10.2 +++ b/linld/stuff/src/LOAD.CPP Fri Nov 08 10:47:52 2019 +0100 10.3 @@ -124,8 +124,7 @@ 10.4 struct image_himem imgs[2]; 10.5 10.6 static const char kernel_file_error[] = "Can't use kernel file"; 10.7 -static char *version_string=""; 10.8 -char* load_kernel() { 10.9 +void load_kernel() { 10.10 10.11 struct image_himem *m = ± 10.12 #define _rm_buf(m) (((u8**)(m))[-1]) 10.13 @@ -158,7 +157,6 @@ 10.14 if((kernelparams->setup_sects)>=(_32k/512) || // 0th sector not counted 10.15 kernelparams->boot_flag != 0xAA55) 10.16 die("Not a kernel"); 10.17 - heap_top += // Hack for VCPI. Need fix. 10.18 _rm_size=0x200*(kernelparams->setup_sects+1); 10.19 m->size -= _rm_size; 10.20 m->chunk_size -= _rm_size; 10.21 @@ -185,7 +183,7 @@ 10.22 hook_int15_88(); // break _ES 10.23 } 10.24 if (kernelparams->kernel_version) 10.25 - version_string = (char *) strdup((char *) first1k+kernelparams->kernel_version+0x200); 10.26 + strcpy(version_string,(char *) first1k+kernelparams->kernel_version+0x200); 10.27 kernelparams->type_of_loader = 0xff; // kernel do not know us (yet :-) 10.28 if(kernelparams->version >= 0x201) { 10.29 // * offset limit of the setup heap 10.30 @@ -223,7 +221,6 @@ 10.31 } 10.32 10.33 load_image(m); 10.34 - return version_string; 10.35 } 10.36 10.37 // Read initrd if needed
11.1 --- a/linld/stuff/src/TAZBOOT.CPP Fri Nov 08 10:09:23 2019 +0100 11.2 +++ b/linld/stuff/src/TAZBOOT.CPP Fri Nov 08 10:47:52 2019 +0100 11.3 @@ -58,7 +58,8 @@ 11.4 struct image_himem *m = ± 11.5 m->chunk_size = m->size = isofilesize4round(); 11.6 m->fd = isofd; 11.7 - return load_kernel(); 11.8 + load_kernel(); 11.9 + return version_string; 11.10 } 11.11 11.12 static char buf_cmdline[4096];
12.1 --- a/linld/stuff/src/_BEG.ASM Fri Nov 08 10:09:23 2019 +0100 12.2 +++ b/linld/stuff/src/_BEG.ASM Fri Nov 08 10:47:52 2019 +0100 12.3 @@ -32,6 +32,8 @@ 12.4 12.5 global _bss_start:byte 12.6 label _bss_start byte 12.7 + global _version_string:byte 12.8 + label _version_string byte 12.9 db STACK_SIZE-2 dup(?) 12.10 stktop dw ? 12.11 global _cpu_features:dword 12.12 @@ -52,7 +54,7 @@ 12.13 ; clear bss 12.14 ;*************************************************************** 12.15 mov sp,offset stktop 12.16 - mov si,sp 12.17 + mov si,offset _version_string 12.18 mov bx, 0F000h ; cld ; cli & empty string 12.19 clearbss: 12.20 mov [si],bl ; clear bss + heap + sp
13.1 --- a/linld/stuff/src/pipehole.awk Fri Nov 08 10:09:23 2019 +0100 13.2 +++ b/linld/stuff/src/pipehole.awk Fri Nov 08 10:47:52 2019 +0100 13.3 @@ -102,10 +102,7 @@ 13.4 if (/jb/) isload=12 13.5 sub(/jb/,"ja") 13.6 } 13.7 - if (/i,offset/) split($2,sidi,",") 13.8 - if (sidi[1] == "si") sidi[2]="di" 13.9 - else sidi[2]="si" 13.10 - sub(/DGROUP:_imgs\+65534/,"[" sidi[1] "-2]") 13.11 + sub(/_imgs\+65534/,"_imgs-2") 13.12 if (/m, _rm_size/) isload=10 13.13 if (isload == 10) { # LOAD.LST 13.14 if (/^ je /) next 13.15 @@ -127,13 +124,13 @@ 13.16 if (/cmd_line_ptr =/ && is386 == 0) isload=7 13.17 if (isload == 7) { # LOAD.LST 13.18 if (/add/ || /xor/ || /extrn/ || /N_LXLSH@/ || /cl,4/) next 13.19 - if (/enable A20 if needed/) { 13.20 - print " mov word ptr [bx+" sidi[2] "],8000h" 13.21 - isload=0 13.22 - } 13.23 + if (/enable A20 if needed/) { print nextinst; isload=0 } 13.24 if (/,ax/) $0=" mov bx,55" 13.25 if (/i-463/) $0=" mov bx,-463" 13.26 - if (/i-465/) { sub(/465/,"2"); sub(/\[/,"[bx+"); } 13.27 + if (/i-465/) { 13.28 + sub(/465/,"2"); sub(/\[/,"[bx+") 13.29 + nextinst=$0; sub(/-2\],-23745/,"],8000h",nextinst) 13.30 + } 13.31 if (/,dx/) { 13.32 print " mov cl,12" 13.33 print " shr ax,cl"
14.1 --- a/rack/receipt Fri Nov 08 10:09:23 2019 +0100 14.2 +++ b/rack/receipt Fri Nov 08 10:47:52 2019 +0100 14.3 @@ -17,7 +17,7 @@ 14.4 # Rules to configure and make the package. 14.5 compile_rules() 14.6 { 14.7 - local _gemdir="$(ruby -rubygems -e'puts Gem.default_dir')" 14.8 + local _gemdir="$(ruby -rrubygems -e'puts Gem.default_dir')" 14.9 gem install --ignore-dependencies -i "$DESTDIR/$_gemdir" $SOURCES_REPOSITORY/$TARBALL 14.10 } 14.11
15.1 --- a/rails/receipt Fri Nov 08 10:09:23 2019 +0100 15.2 +++ b/rails/receipt Fri Nov 08 10:47:52 2019 +0100 15.3 @@ -17,7 +17,7 @@ 15.4 # Rules to configure and make the package. 15.5 compile_rules() 15.6 { 15.7 - local _gemdir="$(ruby -rubygems -e'puts Gem.default_dir')" 15.8 + local _gemdir="$(ruby -rrubygems -e'puts Gem.default_dir')" 15.9 gem install --ignore-dependencies -i "$DESTDIR/$_gemdir" $SOURCES_REPOSITORY/$TARBALL 15.10 } 15.11
16.1 --- a/rake/receipt Fri Nov 08 10:09:23 2019 +0100 16.2 +++ b/rake/receipt Fri Nov 08 10:47:52 2019 +0100 16.3 @@ -17,7 +17,7 @@ 16.4 # Rules to configure and make the package. 16.5 compile_rules() 16.6 { 16.7 - local _gemdir="$(ruby -rubygems -e'puts Gem.default_dir')" 16.8 + local _gemdir="$(ruby -rrubygems -e'puts Gem.default_dir')" 16.9 gem install --ignore-dependencies -i "$DESTDIR/$_gemdir" $SOURCES_REPOSITORY/$TARBALL 16.10 } 16.11
17.1 --- a/spruz/receipt Fri Nov 08 10:09:23 2019 +0100 17.2 +++ b/spruz/receipt Fri Nov 08 10:47:52 2019 +0100 17.3 @@ -17,7 +17,7 @@ 17.4 # Rules to configure and make the package. 17.5 compile_rules() 17.6 { 17.7 - local _gemdir="$(ruby -rubygems -e'puts Gem.default_dir')" 17.8 + local _gemdir="$(ruby -rrubygems -e'puts Gem.default_dir')" 17.9 gem install --ignore-dependencies -i "$DESTDIR/$_gemdir" $SOURCES_REPOSITORY/$TARBALL 17.10 } 17.11