Commit c5c8be3ce59dc59baf20b33dae3f8eb70af7b1f1

Authored by Matthias Kaehlcke
Committed by Linus Torvalds
1 parent af065b8a19

fs/inode.c: use hlist_for_each_entry()

fs/inode.c: use hlist_for_each_entry() in find_inode() and find_inode_fast()

[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Matthias Kaehlcke <matthias@kaehlcke.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

Showing 1 changed file with 2 additions and 4 deletions Side-by-side Diff

... ... @@ -495,8 +495,7 @@
495 495 struct inode * inode = NULL;
496 496  
497 497 repeat:
498   - hlist_for_each (node, head) {
499   - inode = hlist_entry(node, struct inode, i_hash);
  498 + hlist_for_each_entry(inode, node, head, i_hash) {
500 499 if (inode->i_sb != sb)
501 500 continue;
502 501 if (!test(inode, data))
... ... @@ -520,8 +519,7 @@
520 519 struct inode * inode = NULL;
521 520  
522 521 repeat:
523   - hlist_for_each (node, head) {
524   - inode = hlist_entry(node, struct inode, i_hash);
  522 + hlist_for_each_entry(inode, node, head, i_hash) {
525 523 if (inode->i_ino != ino)
526 524 continue;
527 525 if (inode->i_sb != sb)