[Ocfs2-tools-devel] [PATCH 2/2] looped chain - Break loop in fsck
tristan
tristan.ye at oracle.com
Tue Mar 2 20:31:58 PST 2010
Tao Ma wrote:
> Hi tristan,
>
> tristan wrote:
>> Hi Goldwyn,
>>>
>>> +static errcode_t break_loop(o2fsck_state *ost, struct
>>> ocfs2_chain_rec *chain,
>>> + unsigned int max_depth)
>>
>> I guess it will make more sense if your rename the func name as
>> break_chain_loop() :)
>>> +{
>>> + uint64_t *list;
>>> + int i;
>>> + unsigned int depth = 0;
>>> + uint64_t blkno = chain->c_blkno;
>>
>> blkno = le64_to_cpu(chain->c_blkno);
> we don't need to call le64_to_cpu if we use ocfs2_read_inode to read a
> chain file in user space since it has done it for us already. But in
> case we call read_block directly, we need this. I haven't read through
> the codes, so just FYI.
Oh, that's exactly right, I saw ocfs2_swap_inode_to_cpu() in
ocfs2_read_inode(), great thanks for the reminding!
>
> Regards,
> Tao
More information about the Ocfs2-tools-devel
mailing list