From: hujianyang <hujianyang@huawei.com>
To: Richard Weinberger <richard@nod.at>
Cc: linux-mtd <linux-mtd@lists.infradead.org>, dedekind1@gmail.com
Subject: Re: [PATCH resend] UBIFS: return -EINVAL if first log leb is empty
Date: Mon, 2 Feb 2015 17:00:15 +0800 [thread overview]
Message-ID: <54CF3C9F.2010502@huawei.com> (raw)
In-Reply-To: <54CF3333.7050909@nod.at>
Hi Richard,
On 2015/2/2 16:20, Richard Weinberger wrote:
> Am 02.02.2015 um 04:10 schrieb hujianyang:
>> Another problem. Someone <markus.heininger@online.de> asked:
>>
>> "UBIFS: Is it possible to get the compressed size of a file?"
>>
>> I think it's an interesting problem. Actually we used to separate an UBI
>> device into several volumes for space management reason. So could we
>> realize the compressed size getting mechanism and import *quota* to UBIFS
>> itself.
>
> You can get the actual size by accumulating the UBIFS data node sizes.
and xattr node sizes too? may store in another variable.
> But this means that you have to load the actual data node which is rather
> expensive. I had a short chat with Artem on this, we agreed that a nice solution
> would be to store the actual size in an inode. But that is a non-trivial change
> to UBIFS.
>
Yes, old images may not store the actual size and it's hard to
get compressed size from this kind of images by a new driver.
Users may get actual size from an ioctl call and maybe we could
return an error if this feature is not supported. How about
increasing file-system driver version and applying actual size
support in a higher version? or mark this feature as a flag
in super_node?
Another 'expensive' implement is whole scan the partition to
get the actual size of a required file in the old images.
What's your plan after that chat?
BR,
Hu
prev parent reply other threads:[~2015-02-02 9:02 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-31 3:43 [PATCH resend] UBIFS: return -EINVAL if first log leb is empty hujianyang
2015-01-31 9:51 ` Artem Bityutskiy
2015-01-31 10:34 ` hujianyang
2015-01-31 12:16 ` Artem Bityutskiy
2015-02-02 3:10 ` hujianyang
2015-02-02 8:20 ` Richard Weinberger
2015-02-02 9:00 ` hujianyang [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=54CF3C9F.2010502@huawei.com \
--to=hujianyang@huawei.com \
--cc=dedekind1@gmail.com \
--cc=linux-mtd@lists.infradead.org \
--cc=richard@nod.at \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox