From: Detlev Zundel <dzu@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH V2] JFFS2: bug fix for summary support.
Date: Wed, 27 Apr 2011 11:45:45 +0200 [thread overview]
Message-ID: <m2aafcc9iu.fsf@ohwell.denx.de> (raw)
In-Reply-To: <BANLkTimzHHS1Kjn_BxkrqNzEOv2E5inXhw@mail.gmail.com> (Baidu Liu's message of "Sun, 24 Apr 2011 11:45:40 +0800")
Hi Baidu,
[...]
>> Looking over the changes, I do _see_ changes in code, so you should tell
>> us about them.
>>
>>> [...]
>>
>>> diff --git a/include/jffs2/jffs2.h b/include/jffs2/jffs2.h
>>> index 651f94c..5b006c0 100644
>>> --- a/include/jffs2/jffs2.h
>>> +++ b/include/jffs2/jffs2.h
>>> @@ -41,6 +41,16 @@
>>> ?#include <asm/types.h>
>>> ?#include <jffs2/load_kernel.h>
>>>
>>> +#ifdef CONFIG_JFFS2_SUMMARY
>>> +#ifndef CONFIG_SYS_JFFS2_SORT_FRAGMENTS
>>> +/*
>>> +we should define CONFIG_SYS_JFFS2_SORT_FRAGMENTS,if
>>> +CONFIG_JFFS2_SUMMARY is enabled.
>>> +*/
>>> +#define CONFIG_SYS_JFFS2_SORT_FRAGMENTS
>>> +#endif
>>> +#endif
>>> +
>>> ?#define JFFS2_SUPER_MAGIC 0x72b6
>>>
>>> ?/* Values we may expect to find in the 'magic' field */
>>
>> I liked the previous version better:
>>
>>> diff --git a/include/jffs2/jffs2.h b/include/jffs2/jffs2.h
>>> index 651f94c..c01a76e 100644
>>> --- a/include/jffs2/jffs2.h
>>> +++ b/include/jffs2/jffs2.h
>>> @@ -41,6 +41,17 @@
>>> ?#include <asm/types.h>
>>> ?#include <jffs2/load_kernel.h>
>>>
>>> +#ifdef CONFIG_JFFS2_SUMMARY
>>> +#ifndef CONFIG_SYS_JFFS2_SORT_FRAGMENTS
>>> +/*
>>> + * ? if we define summary in jffs2, we also need to define
>>> + * ? CONFIG_SYS_JFFS2_SORT_FRAGMENTS. If not, the data in latest inode may be
>>> + * ?overwritten by the old one.
>>> +*/
>>> +#error "need to define CONFIG_SYS_JFFS2_SORT_FRAGMENTS,if summary is enabled"
>>> +#endif
>>> +#endif
>>> +
>>> ?#define JFFS2_SUPER_MAGIC 0x72b6
>>
>> Why did you change this to the worse?
>>
>
> If we use summary in uboot, we MUST also define CONFIG_SYS_JFFS2_SORT_FRAGMENTS.
> The reason is :
> All the inodes of a file will not marked as obsolete, if they do not
> sort in the list struct b_node *, the latest data in inode may be
> overwritten by the older one.
Yes, this is what you wrote in your first version and what I would like
to see. My question was why you deleted the (helpful) comment in your
second version...
Cheers
Detlev
--
Wenn ein Kopf und ein Buch zusammenstossen und es klingt hohl; ist
denn das allemal im Buche?
- Lichtenberg
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de
prev parent reply other threads:[~2011-04-27 9:45 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-17 2:07 [U-Boot] [PATCH V2] JFFS2: bug fix for summary support Baidu Liu
2011-04-19 15:01 ` Detlev Zundel
2011-04-24 3:45 ` Baidu Liu
2011-04-27 9:45 ` Detlev Zundel [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=m2aafcc9iu.fsf@ohwell.denx.de \
--to=dzu@denx.de \
--cc=u-boot@lists.denx.de \
/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