Showing error 1026

User: Jiri Slaby
Error type: Leaving function in locked state
Error type description: Some lock is not unlocked on all paths of a function, so it is leaked
File location: fs/xfs/xfs_filestream.c
Line in file: 325
Project: Linux Kernel
Project version: 2.6.28
Tools: Undetermined 1
Entered: 2012-03-04 17:07:06 UTC


Source:

295                if (ag != old_ag) {
296                        xfs_filestream_put_ag(mp, old_ag);
297                        xfs_filestream_get_ag(mp, ag);
298                }
299
300                /*
301                 * If ip is a file and its pip has changed, drop the old ref and
302                 * take a new one.
303                 */
304                if (pip && pip != old_pip) {
305                        IRELE(old_pip);
306                        IHOLD(pip);
307                }
308
309                TRACE_UPDATE(mp, ip, old_ag, xfs_filestream_peek_ag(mp, old_ag),
310                                ag, xfs_filestream_peek_ag(mp, ag));
311                return 0;
312        }
313
314        item = kmem_zone_zalloc(item_zone, KM_MAYFAIL);
315        if (!item)
316                return ENOMEM;
317
318        item->ag = ag;
319        item->ip = ip;
320        item->pip = pip;
321
322        err = xfs_mru_cache_insert(cache, ip->i_ino, item);
323        if (err) {
324                kmem_zone_free(item_zone, item);
325                return err;
326        }
327
328        /* Take a reference on the AG. */
329        xfs_filestream_get_ag(mp, ag);
330
331        /*
332         * Take a reference on the inode itself regardless of whether it's a
333         * regular file or a directory.
334         */
335        IHOLD(ip);
Show full sources