wok-current rev 20225
grub: add ext4 patch (again)
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Thu Mar 01 11:50:30 2018 +0100 (2018-03-01) |
parents | 90f9ce95a98e |
children | e6d3b1fa06cd |
files | grub/stuff/ext3_256byte_inode+ext4.diff |
line diff
1.1 --- a/grub/stuff/ext3_256byte_inode+ext4.diff Thu Mar 01 11:38:49 2018 +0100 1.2 +++ b/grub/stuff/ext3_256byte_inode+ext4.diff Thu Mar 01 11:50:30 2018 +0100 1.3 @@ -378,7 +378,7 @@ 1.4 - (char *) SUPERBLOCK) 1.5 - || SUPERBLOCK->s_magic != EXT2_SUPER_MAGIC) 1.6 - retval = 0; 1.7 -+ if (!devread(SBLOCK, 0, sizeof(struct ext2_super_block), (char *)SUPERBLOCK, 0xedde0d90)) 1.8 ++ if (!devread(SBLOCK, 0, sizeof(struct ext2_super_block), (char *)SUPERBLOCK)) 1.9 + return 0; 1.10 1.11 - return retval; 1.12 @@ -424,15 +424,6 @@ 1.13 } 1.14 1.15 /* Takes a file system block number and reads it into BUFFER. */ 1.16 -@@ -276,7 +484,7 @@ 1.17 - printf ("fsblock %d buffer %d\n", fsblock, buffer); 1.18 - #endif /* E2DEBUG */ 1.19 - return devread (fsblock * (EXT2_BLOCK_SIZE (SUPERBLOCK) / DEV_BSIZE), 0, 1.20 -- EXT2_BLOCK_SIZE (SUPERBLOCK), (char *) buffer); 1.21 -+ EXT2_BLOCK_SIZE (SUPERBLOCK), (char *) buffer, 0xedde0d90); 1.22 - } 1.23 - 1.24 - /* from 1.25 @@ -285,7 +493,7 @@ 1.26 /* Maps LOGICAL_BLOCK (the file offset divided by the blocksize) into 1.27 a physical block (the location in the file system) via an inode. */ 1.28 @@ -596,10 +587,8 @@ 1.29 +} 1.30 + 1.31 /* preconditions: all preconds of ext2fs_block_map */ 1.32 --int 1.33 --ext2fs_read (char *buf, int len) 1.34 -+unsigned long 1.35 -+ext2fs_read (char *buf, unsigned long len, unsigned long write) 1.36 + int 1.37 + ext2fs_read (char *buf, int len) 1.38 { 1.39 - int logical_block; 1.40 - int offset; 1.41 @@ -672,7 +661,7 @@ 1.42 - devread (map * (EXT2_BLOCK_SIZE (SUPERBLOCK) / DEV_BSIZE), 1.43 - offset, size, buf); 1.44 + devread (map * (EXT2_BLOCK_SIZE (SUPERBLOCK) / DEV_BSIZE), 1.45 -+ offset, size, buf, write); 1.46 ++ offset, size, buf); 1.47 1.48 - disk_read_func = NULL; 1.49 + disk_read_func = NULL; 1.50 @@ -920,7 +909,7 @@ 1.51 + tmp_name[k] = 0; 1.52 1.53 + //dp->name[dp->name_len] = 0; 1.54 -+ str_chk = substring (dirname, tmp_name, 0); 1.55 ++ str_chk = substring (dirname, tmp_name); 1.56 + 1.57 # ifndef STAGE1_5 1.58 if (print_possibilities && ch != '/'