search for: fat_uuid_len

Displaying 1 result from an estimated 1 matches for "fat_uuid_len".

2013 Nov 19
2
[PATCH] Add filesystem UUID to SYSAPPEND for FAT
...if (FAT32 == sbi->fat_type) + sbi->uuid = fat.fat32.num_serial; + else + sbi->uuid = fat.fat12_16.num_serial; + /* Initialize the cache */ cache_init(fs->fs_dev, fs->block_shift); @@ -811,6 +818,29 @@ static int vfat_copy_superblock(void *buf) return 0; } +#define FAT_UUID_LEN (4 + 1 + 4 + 1) +static char *vfat_fs_uuid(struct fs_info *fs) +{ + char *uuid = NULL; + char *ptr; + + uuid = malloc(FAT_UUID_LEN); + if (!uuid) + return NULL; + + if (snprintf(uuid, FAT_UUID_LEN, "%04x-%04x", + (uint16_t)(FAT_SB(fs)->uuid >> 16), +...