Subversion Repositories Kolibri OS

Rev

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

Rev 77 Rev 78
Line 3200... Line 3200...
3200
;----------------------------------------------------------------
3200
;----------------------------------------------------------------
3201
;
3201
;
3202
;  fs_HdReadFolder - LFN variant for reading hard disk folder
3202
;  fs_HdReadFolder - LFN variant for reading hard disk folder
3203
;
3203
;
3204
;  esi  points to filename
3204
;  esi  points to filename
3205
;  ebx  pointer to 32-bit number = first wanted block, 0+
3205
;  ebx  pointer to structure 32-bit number = first wanted block, 0+
-
 
3206
;                          & flags (bitfields)
-
 
3207
; flags: bit 0: 0=ANSI names, 1=UNICODE names
3206
;  ecx  number of blocks to read, 0+
3208
;  ecx  number of blocks to read, 0+
3207
;  edx  mem location to return data
3209
;  edx  mem location to return data
3208
;
3210
;
3209
;  ret ebx = blocks read or 0xffffffff folder not found
3211
;  ret ebx = blocks read or 0xffffffff folder not found
3210
;      eax = 0 ok read or other = errormsg
3212
;      eax = 0 ok read or other = errormsg
3211
;
3213
;
3212
;--------------------------------------------------------------
3214
;--------------------------------------------------------------
3213
fs_HdReadFolder:
3215
fs_HdReadFolder:
3214
        mov     ebx, [ebx]
-
 
3215
        mov     eax, [ROOT_CLUSTER]
3216
        mov     eax, [ROOT_CLUSTER]
3216
        push    edi
3217
        push    edi
3217
        cmp     byte [esi], 0
3218
        cmp     byte [esi], 0
3218
        jz      .doit
3219
        jz      .doit
3219
        call    hd_find_lfn
3220
        call    hd_find_lfn
Line 3235... Line 3236...
3235
.doit:
3236
.doit:
3236
        push    esi ecx
3237
        push    esi ecx
3237
        push    ebp
3238
        push    ebp
3238
        sub     esp, 262*2      ; reserve space for LFN
3239
        sub     esp, 262*2      ; reserve space for LFN
3239
        mov     ebp, esp
3240
        mov     ebp, esp
3240
        push    1               ; for fat_get_name: read UNICODE name
3241
        push    dword [ebx+4]   ; for fat_get_name: read ANSI/UNICODE name
-
 
3242
        mov     ebx, [ebx]
3241
; init header
3243
; init header
3242
        push    eax ecx
3244
        push    eax ecx
3243
        mov     edi, edx
3245
        mov     edi, edx
3244
        mov     ecx, 32/4
3246
        mov     ecx, 32/4
3245
        xor     eax, eax
3247
        xor     eax, eax