From: Matthias Kaehlcke fs/inode.c: use hlist_for_each_entry() in find_inode() and find_inode_fast() Signed-off-by: Matthias Kaehlcke Signed-off-by: Andrew Morton --- fs/inode.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff -puN fs/inode.c~fs-inodec-use-hlist_for_each_entry fs/inode.c --- a/fs/inode.c~fs-inodec-use-hlist_for_each_entry +++ a/fs/inode.c @@ -495,8 +495,7 @@ static struct inode * find_inode(struct struct inode * inode = NULL; repeat: - hlist_for_each (node, head) { - inode = hlist_entry(node, struct inode, i_hash); + hlist_for_each_entry (inode, node, head, i_hash) { if (inode->i_sb != sb) continue; if (!test(inode, data)) @@ -520,8 +519,7 @@ static struct inode * find_inode_fast(st struct inode * inode = NULL; repeat: - hlist_for_each (node, head) { - inode = hlist_entry(node, struct inode, i_hash); + hlist_for_each_entry (inode, node, head, i_hash) { if (inode->i_ino != ino) continue; if (inode->i_sb != sb) _