exfat文件系统(七)------exfat_core.c详解(二)------file entry相关

来源:互联网 发布:域名邮箱怎么设置 编辑:程序博客网 时间:2024/04/29 21:49

在cluster heap中的exfat file entry从64M.hex中可以看出如下图显示记录其entry的信息:


在对应的entry数据中分别对应代码中的如下数据结构(64M.hex中的截图颜色和数据结构颜色对应)

         typedef struct {

                   UINT8       type;

                   UINT8       num_ext;

                   UINT8       checksum[2];

                   UINT8       attr[2];

                   UINT8       reserved1[2];

                   UINT8       create_time[2];

                   UINT8       create_date[2];

                   UINT8       modify_time[2];

                   UINT8       modify_date[2];

                   UINT8       access_time[2];

                   UINT8       access_date[2];

                   UINT8       create_time_ms;

                   UINT8       modify_time_ms;

                   UINT8       access_time_ms;

                   UINT8       reserved2[9];

         } FILE_DENTRY_T;


         typedef struct {

                   UINT8       type;

                   UINT8       flags;

                   UINT8       reserved1;

                   UINT8       name_len;

                   UINT8       name_hash[2];

                   UINT8       reserved2[2];

                   UINT8       valid_size[8];

                   UINT8       reserved3[4];

                   UINT8       start_clu[4];

                   UINT8       size[8];

         } STRM_DENTRY_T;


         typedef struct {(黄色框图数据信息)

                   UINT8       type;

                   UINT8       flags;

                   UINT8       unicode_0_14[30];

         } NAME_DENTRY_T;


以上数据结构主要在如下函数中解析和调用到:

exfat_find_dir_entry(返回查找到的file的entry值,即file在cluster的偏移量)

get_entry_set_in_dir(获取到file entry的完整数据信息,并把相关数据信息指针指向返回值ep)


0 0