f2fs: fix to do sanity check on inode type during garbage collection
[linux-2.6-microblaze.git] / fs / f2fs / gc.c
index a946ce0..e0bdc43 100644 (file)
@@ -1457,7 +1457,8 @@ next_step:
 
                if (phase == 3) {
                        inode = f2fs_iget(sb, dni.ino);
-                       if (IS_ERR(inode) || is_bad_inode(inode))
+                       if (IS_ERR(inode) || is_bad_inode(inode) ||
+                                       special_file(inode->i_mode))
                                continue;
 
                        if (!down_write_trylock(