Changeset 2b5d966 in mainline
- Timestamp:
- 2015-04-30T21:44:54Z (10 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- df2bce3
- Parents:
- bf1733d3
- Location:
- uspace
- Files:
-
- 1 added
- 2 deleted
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/crypto/Makefile
rbf1733d3 r2b5d966 33 33 crypto.c \ 34 34 aes.c \ 35 rc4.c 35 rc4.c \ 36 crc16_ibm.c 36 37 37 38 include $(USPACE_PREFIX)/Makefile.common -
uspace/lib/crypto/crypto.h
rbf1733d3 r2b5d966 56 56 extern int pbkdf2(uint8_t *, size_t, uint8_t *, size_t, uint8_t *); 57 57 58 extern uint16_t crc16_ibm(uint16_t crc, uint8_t *buf, size_t len); 59 58 60 #endif -
uspace/lib/ext4/Makefile
rbf1733d3 r2b5d966 29 29 USPACE_PREFIX = ../.. 30 30 LIBRARY = libext4 31 EXTRA_CFLAGS = -I$(LIBBLOCK_PREFIX) 32 LIBS = $(LIBBLOCK_PREFIX)/libblock.a 31 EXTRA_CFLAGS = -I$(LIBBLOCK_PREFIX) -I$(LIBCRYPTO_PREFIX) 32 LIBS = $(LIBBLOCK_PREFIX)/libblock.a $(LIBCRYPTO_PREFIX)/libcrypto.a 33 33 34 34 SOURCES = \ … … 36 36 libext4_bitmap.c \ 37 37 libext4_block_group.c \ 38 libext4_crc.c \39 38 libext4_directory.c \ 40 39 libext4_directory_index.c \ -
uspace/lib/ext4/libext4.h
rbf1733d3 r2b5d966 37 37 #include "libext4_bitmap.h" 38 38 #include "libext4_block_group.h" 39 #include "libext4_crc.h"40 39 #include "libext4_directory.h" 41 40 #include "libext4_directory_index.h" -
uspace/lib/ext4/libext4_filesystem.c
rbf1733d3 r2b5d966 41 41 #include <ipc/vfs.h> 42 42 #include <align.h> 43 #include <crypto.h> 43 44 #include "libext4.h" 44 45 … … 54 55 enum cache_mode cmode) 55 56 { 57 int rc; 56 58 ext4_superblock_t *temp_superblock = NULL; 57 59 … … 59 61 60 62 /* Initialize block library (4096 is size of communication channel) */ 61 intrc = block_init(EXCHANGE_SERIALIZE, fs->device, 4096);63 rc = block_init(EXCHANGE_SERIALIZE, fs->device, 4096); 62 64 if (rc != EOK) 63 65 goto err; … … 140 142 /* Release memory space for superblock */ 141 143 free(fs->superblock); 142 144 143 145 /* Finish work with block library */ 144 146 block_cache_fini(fs->device); … … 532 534 /* If checksum not supported, 0 will be returned */ 533 535 uint16_t crc = 0; 534 536 535 537 /* Compute the checksum only if the filesystem supports it */ 536 538 if (ext4_superblock_has_feature_read_only(sb, … … 545 547 546 548 /* Initialization */ 547 crc = crc16 (~0, sb->uuid, sizeof(sb->uuid));549 crc = crc16_ibm(~0, sb->uuid, sizeof(sb->uuid)); 548 550 549 551 /* Include index of block group */ 550 crc = crc16 (crc, (uint8_t *) &le_group, sizeof(le_group));552 crc = crc16_ibm(crc, (uint8_t *) &le_group, sizeof(le_group)); 551 553 552 554 /* Compute crc from the first part (stop before checksum field) */ 553 crc = crc16 (crc, (uint8_t *) bg, offset);555 crc = crc16_ibm(crc, (uint8_t *) bg, offset); 554 556 555 557 /* Skip checksum */ … … 560 562 EXT4_FEATURE_INCOMPAT_64BIT)) && 561 563 (offset < ext4_superblock_get_desc_size(sb))) 562 crc = crc16 (crc, ((uint8_t *) bg) + offset,564 crc = crc16_ibm(crc, ((uint8_t *) bg) + offset, 563 565 ext4_superblock_get_desc_size(sb) - offset); 564 566 } -
uspace/srv/fs/ext4fs/Makefile
rbf1733d3 r2b5d966 28 28 29 29 USPACE_PREFIX = ../../.. 30 LIBS = $(LIBBLOCK_PREFIX)/libblock.a $(LIBFS_PREFIX)/libfs.a $(LIBEXT4_PREFIX)/libext4.a 31 EXTRA_CFLAGS += -I$(LIBBLOCK_PREFIX) -I$(LIBFS_PREFIX) -I$(LIBEXT4_PREFIX) 30 LIBS = $(LIBBLOCK_PREFIX)/libblock.a $(LIBFS_PREFIX)/libfs.a \ 31 $(LIBEXT4_PREFIX)/libext4.a $(LIBCRYPTO_PREFIX)/libcrypto.a 32 EXTRA_CFLAGS += -I$(LIBBLOCK_PREFIX) -I$(LIBFS_PREFIX) -I$(LIBEXT4_PREFIX) -I$(LIBCRYPTO_PREFIX) 32 33 BINARY = ext4fs 33 34 STATIC_NEEDED = y
Note:
See TracChangeset
for help on using the changeset viewer.