grub-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 2/2] xfs: V5 filesystem format support


From: Andrei Borzenkov
Subject: Re: [PATCH 2/2] xfs: V5 filesystem format support
Date: Sat, 30 May 2015 09:59:09 +0300

В Wed, 13 May 2015 09:32:48 +0200
Jan Kara <address@hidden> пишет:

>  
>  struct grub_xfs_sblock
>  {
> @@ -54,12 +68,19 @@ struct grub_xfs_sblock
>    grub_uint8_t log2_agblk;
>    grub_uint8_t unused6[67];
>    grub_uint8_t log2_dirblk;
> +  grub_uint8_t unused7[7];
> +  grub_uint32_t features2;
> +  grub_uint8_t unused8[4];
> +  grub_uint32_t sb_features_compat;
> +  grub_uint32_t sb_features_ro_compat;
> +  grub_uint32_t sb_features_incompat;
> +  grub_uint32_t sb_features_log_incompat;

They do not seem to be really used. Normally the very first thing other
filesystems do is to check for incompatible features we do not support.
Even if there are no such such features right now you should add checks
to avoid attempt to access unsupported future format.

...

> @@ -281,6 +384,9 @@ grub_xfs_read_inode (struct grub_xfs_data *data, 
> grub_uint64_t ino,
>    grub_uint64_t block = grub_xfs_inode_block (data, ino);
>    int offset = grub_xfs_inode_offset (data, ino);
>  
> +  grub_dprintf("xfs", "Reading inode (%llu) - %llu, %d\n",

PRIuGRUB_UINT64_T and drop casts.

> +            (unsigned long long) ino,
> +            (unsigned long long) block, offset);



reply via email to

[Prev in Thread] Current Thread [Next in Thread]