JFS mtime support
This commit is contained in:
parent
58fa13fc7c
commit
7ac6c4842d
1 changed files with 12 additions and 1 deletions
|
@ -153,6 +153,12 @@ struct grub_jfs_leaf_next_dirent
|
||||||
grub_uint16_t namepart[15];
|
grub_uint16_t namepart[15];
|
||||||
} __attribute__ ((packed));
|
} __attribute__ ((packed));
|
||||||
|
|
||||||
|
struct grub_jfs_time
|
||||||
|
{
|
||||||
|
grub_int32_t sec;
|
||||||
|
grub_int32_t nanosec;
|
||||||
|
} __attribute__ ((packed));
|
||||||
|
|
||||||
struct grub_jfs_inode
|
struct grub_jfs_inode
|
||||||
{
|
{
|
||||||
grub_uint32_t stamp;
|
grub_uint32_t stamp;
|
||||||
|
@ -162,7 +168,10 @@ struct grub_jfs_inode
|
||||||
grub_uint64_t size;
|
grub_uint64_t size;
|
||||||
grub_uint8_t unused2[20];
|
grub_uint8_t unused2[20];
|
||||||
grub_uint32_t mode;
|
grub_uint32_t mode;
|
||||||
grub_uint8_t unused3[72];
|
struct grub_jfs_time atime;
|
||||||
|
struct grub_jfs_time ctime;
|
||||||
|
struct grub_jfs_time mtime;
|
||||||
|
grub_uint8_t unused3[48];
|
||||||
grub_uint8_t unused4[96];
|
grub_uint8_t unused4[96];
|
||||||
|
|
||||||
union
|
union
|
||||||
|
@ -751,6 +760,8 @@ grub_jfs_dir (grub_device_t device, const char *path,
|
||||||
|
|
||||||
info.dir = (grub_le_to_cpu32 (inode.mode)
|
info.dir = (grub_le_to_cpu32 (inode.mode)
|
||||||
& GRUB_JFS_FILETYPE_MASK) == GRUB_JFS_FILETYPE_DIR;
|
& GRUB_JFS_FILETYPE_MASK) == GRUB_JFS_FILETYPE_DIR;
|
||||||
|
info.mtimeset = 1;
|
||||||
|
info.mtime = grub_le_to_cpu32 (inode.mtime.sec);
|
||||||
if (hook (diro->name, &info))
|
if (hook (diro->name, &info))
|
||||||
goto fail;
|
goto fail;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue