For debian packaing, I should have matched the previous verions, v1.1.0.
So, this is the start of f2fs-tools version.
Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
This patch fixes the bug as follows.
"I'm trying to roll out f2fs on top of SDHC card and faced with following
issue - after mounting card I cannot read device root entry. It returns
-1 EINVAL (entry too big).
getdents(3, /* 1 entries */, 32768) = 24
getdents(3, 0x1082c88, 32768) = -1 EINVAL (Invalid argument)"
reported by Ruslan N. Marchenko [me@ruff.mobi].
This bug is easily reproducible and I couldn't have checked the mount
entry cautiously.
Due to the bug, f2fs couldn't get default dentries, . and .., in the root
directory. In the case of other newly created directories, that's fine.
The problem was the overflow during casting variables while calculating the
block address of the root dentry block.
In order to avoid that, I simply split the equation under consideration of
the casting issue.
Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
There are two superblock writes in mkfs.f2fs.
offset: 0 1024 4095 5119 8191
|------> 1'st superblock ----|--------> 2'nd superblock ----|
Therefore, each superblocks has 1024 byte-size offset.
Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
When f2fs is unmounted cleanly, it stores active summmary blocks of nodes in the
checkpoint pack in order to avoid reconstruct all of them at the later mount
time. Previously, mkfs didn't prepare that, which is why the initial mount time
is so huge.
Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
"Usually, it is used 128-bits UUID for serial number. Why do you use
__le32 as volume_serial_number?"
>From Vyacheslav Dubeyko.
I added an uuid facility for the serial number.
And sync with kernel/include/linux/f2fs_fs.h.
Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>
"You appear to have dropped i_btime - no big deal, you weren't using it anyway.
However if you ever want to support NFS export you will need some value which
is assigned when the inode is allocated and never changed until it is
de-allocated. This is used to detect when an NFS file-handle refers to a
previous incarnation of an inode and so should be rejected as STALE.
i_btime could have possibly provided this, but not any more. You might want
to add something back.
ext3 uses "i_generation" and has an 's_next_generation' in the superblock to
ensure that each new inode gets a new generation number.
You've also dropped i_atime. I can certainly understand the desire to do
that, but I wonder if it is entirely wise. There are some use-cases where
i_mtime is a poor substitute.
Also 'current_depth' looks a little odd without a 'i_' prefix. It wouldn't
hurt to have a comment noting that it is for directories."
>From Neil Brown.
Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>