[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <FDC91B229D965C458E3615E98C48ADDD0EC41869@dggemm511-mbx.china.huawei.com>
Date: Sat, 30 Jun 2018 01:26:43 +0000
From: "Gaoming (ming, consumer BG)" <gaoming20@...wei.com>
To: "Theodore Y. Ts'o" <tytso@....edu>
CC: "linux-ext4@...r.kernel.org" <linux-ext4@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"Liqingchao (sorp)" <sorp.liqingchao@...wei.com>,
"Shenchen (harry)" <harry.shen@...wei.com>,
"miaoxie (A)" <miaoxie@...wei.com>,
"yangfei (D)" <yangfei39@...wei.com>,
"Renlipeng (OS driver)" <renlipeng@...wei.com>
Subject: 答复: 答复: 答复: 答复: [PATCH] ext4: e2fsprogs: fix inode bitmap num not integer,incompatible for ancient android devices
Yes, it is caused by using 1024 blocksize.
It is historical problem, and I have to admit that's not good idea. I don't know why somebody choose it some years before.
It has been corrected two years before or more early. But some ancient devices exist.
It is not user data, no need to do file-based encryption. It is a small partition for some use.
However, 1024 is legal though not good, somebody may use it.
And we should fix it.
Regards,
Ming
-----邮件原件-----
发件人: Theodore Y. Ts'o [mailto:tytso@....edu]
发送时间: 2018年6月29日 22:26
收件人: Gaoming (ming, consumer BG)
抄送: linux-ext4@...r.kernel.org; linux-kernel@...r.kernel.org; Liqingchao (sorp); Shenchen (harry); miaoxie (A); yangfei (D); Renlipeng (OS driver)
主题: Re: 答复: 答复: 答复: [PATCH] ext4: e2fsprogs: fix inode bitmap num not integer,incompatible for ancient android devices
On Fri, Jun 29, 2018 at 02:06:03AM +0000, Gaoming (ming, consumer BG) wrote:
> We use usual inode size, it is 256 bytes.
>
> Yes, this commit is in my repository.
> But there is a bug in this patch.
>
> Let me show you,
> Here is the bug: " return ALIGN(inodes, (info.block_size / info.inode_size));"
>
> In my reproduce,
> info.block_size = 1024, (it is legal)
> info.inode_size =256,
But why are you using a block size of 1024? It's legal, but in
general, it's a bad idea (often will hurt performance, will impose
additional scalability limitations, etc.).... It's certainly not
the default.
A block size of 1024 is also incompatible with file-based encryption
(FBE), which is required for a number of Android features. Support
for FBE is strongly required, and it wouldn't surprise me if it
becomes an mandatory requirement at some point in the future.
How long have you been using a block size of 1024, and why?
> But in real scenario, we should align by 8,( 8 bit per bytes in inode map).
Yes, and that's why mke2fs does. make_ext4fs was an Android specific
abomination, that I've been pushing hard for Android to rid itself of.
This is not the only thing it's gotten wrong in the past, and I've had
to help Android developers deal with data corrupting bugs caused by
the fact that way back when, Android had a GPL-in-userspace allergy.
- Ted
Powered by blists - more mailing lists