[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Error in jffs2_read_dnode

clesiak@xxxxxxx.com said:
> After more data collection, I've found that the problem is when
> jffs_read_dnode() is called from jffs2_getlink().

> It looks as if jffs2_readlink() and jffs2_follow_link() don't lock
> jffs2_inode_info::sem but should be.  Is this true?

Er, yes - they should. Good catch, thanks. I've committed the fix, and I'll 
send it to Linus/Marcelo shortly. 

> I was a little concerned with jffs2_garbage_collect_metadata() and how
> it orders the obsoletion of the old node and the update of f->metadata
> to point to the new one.  But, it appears as if this is only done with
> jffs2_inode_info::sem locked. 

Indeed. I should document the locking and audit it. Not necessarily in that 
order. In fact, I suspect I should have documented the locking a few months 
ago, while I was still fairly confident that I knew how it worked (and 
indeed still fairly confident that it did).


To unsubscribe from this list: send the line "unsubscribe jffs-dev" in
the body of a message to majordomo@xxxxxxx.com