Subversion Repositories Kolibri OS

Rev

Rev 1311 | Rev 1322 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1311 Rev 1314
Line 3... Line 3...
3
;; Copyright (C) KolibriOS team 2004-2007. All rights reserved. ;;
3
;; Copyright (C) KolibriOS team 2004-2007. All rights reserved. ;;
4
;; Distributed under terms of the GNU General Public License    ;;
4
;; Distributed under terms of the GNU General Public License    ;;
5
;;                                                              ;;
5
;;                                                              ;;
6
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
6
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Line 7... Line 7...
7
 
7
 
Line 8... Line 8...
8
$Revision: 1311 $
8
$Revision: 1314 $
Line 9... Line 9...
9
 
9
 
Line 749... Line 749...
749
@@:
749
@@:
750
       cmp ecx, 0x8000
750
       cmp ecx, 0x8000
751
       jna @F
751
       jna @F
752
       mov ecx, 0x8000
752
       mov ecx, 0x8000
753
@@:
753
@@:
754
       mov eax, [slot]
-
 
755
       shl  eax,8
-
 
756
       mov ebx, [offset]
754
       mov ebx, [offset]
Line 757... Line 755...
757
 
755
 
758
       push ecx
756
       push ecx
759
       stdcall map_memEx, [proc_mem_map],\
-
 
760
                  [SLOT_BASE+eax+0xB8],\
757
       stdcall map_memEx, [proc_mem_map],\
761
                  ebx, ecx
758
                  [slot], ebx, ecx, PG_MAP
Line 762... Line 759...
762
       pop ecx
759
       pop ecx
763
 
760
 
-
 
761
       mov esi, [offset]
-
 
762
       and esi, 0xfff
-
 
763
       sub eax, esi
-
 
764
       jbe .ret
-
 
765
       cmp ecx, eax
-
 
766
       jbe @f
-
 
767
       mov ecx, eax
764
       mov esi, [offset]
768
       mov [tmp_r_cnt], eax
765
       and esi, 0xfff
769
@@:
766
       add esi, [proc_mem_map]
770
       add esi, [proc_mem_map]
767
       mov edi, [buff]
771
       mov edi, [buff]
768
       mov edx, ecx
772
       mov edx, ecx
Line 769... Line 773...
769
       rep movsb
773
       rep movsb
770
       add [r_count], edx
774
       add [r_count], edx
771
 
775
 
772
       add [offset], edx
776
       add [offset], edx
773
       sub [tmp_r_cnt], edx
777
       sub [tmp_r_cnt], edx
774
       jnz .read_mem
778
       jnz .read_mem
775
 
779
.ret:
776
       popad
780
       popad
Line 816... Line 820...
816
@@:
820
@@:
817
       cmp ecx, 0x8000
821
       cmp ecx, 0x8000
818
       jna @F
822
       jna @F
819
       mov ecx, 0x8000
823
       mov ecx, 0x8000
820
@@:
824
@@:
821
       mov eax, [slot]
-
 
822
       shl  eax,8
-
 
823
       mov ebx, [offset]
825
       mov ebx, [offset]
824
      ;     add ebx, new_app_base
826
      ;     add ebx, new_app_base
825
       push ecx
827
       push ecx
826
       stdcall map_memEx, [proc_mem_map],\
828
       stdcall map_memEx, [proc_mem_map],\
827
                  [SLOT_BASE+eax+0xB8],\
-
 
828
                  ebx, ecx
829
                  [slot], ebx, ecx, PG_SW
829
       pop ecx
830
       pop ecx
Line 830... Line 831...
830
 
831
 
831
       mov edi, [offset]
832
       mov edi, [offset]
-
 
833
       and edi, 0xfff
-
 
834
       sub eax, edi
-
 
835
       jbe .ret
-
 
836
       cmp ecx, eax
-
 
837
       jbe @f
-
 
838
       mov ecx, eax
-
 
839
       mov [tmp_w_cnt], eax
832
       and edi, 0xfff
840
@@:
833
       add edi, [proc_mem_map]
841
       add edi, [proc_mem_map]
834
       mov esi, [buff]
842
       mov esi, [buff]
835
       mov edx, ecx
843
       mov edx, ecx
Line 836... Line 844...
836
       rep movsb
844
       rep movsb
837
 
845
 
838
       add [w_count], edx
846
       add [w_count], edx
839
       add [offset], edx
847
       add [offset], edx
840
       sub [tmp_w_cnt], edx
848
       sub [tmp_w_cnt], edx
841
       jnz .read_mem
849
       jnz .read_mem
842
 
850
.ret:
843
       popad
851
       popad
844
       mov eax, [w_count]
852
       mov eax, [w_count]