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_trans.c |
Line in file: | 1451 |
Project: | Linux Kernel |
Project version: | 2.6.28 |
Tools: |
Stanse
(1.2)
|
Entered: | 2012-03-02 21:35:18 UTC |
1421 * is possible that a later transaction completing 1422 * simultaneously with an earlier one using the 1423 * same item could complete first with a higher lsn. 1424 * This would cause the earlier transaction to fail 1425 * the test below. 1426 */ 1427 mp = lip->li_mountp; 1428 spin_lock(&mp->m_ail_lock); 1429 if (XFS_LSN_CMP(item_lsn, lip->li_lsn) > 0) { 1430 /* 1431 * This will set the item's lsn to item_lsn 1432 * and update the position of the item in 1433 * the AIL. 1434 * 1435 * xfs_trans_update_ail() drops the AIL lock. 1436 */ 1437 xfs_trans_update_ail(mp, lip, item_lsn); 1438 } else { 1439 spin_unlock(&mp->m_ail_lock); 1440 } 1441 1442 /* 1443 * Now that we've repositioned the item in the AIL, 1444 * unpin it so it can be flushed. Pass information 1445 * about buffer stale state down from the log item 1446 * flags, if anyone else stales the buffer we do not 1447 * want to pay any attention to it. 1448 */ 1449 IOP_UNPIN(lip, lidp->lid_flags & XFS_LID_BUF_STALE); 1450 } 1451}