Showing error 1009

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_log_recover.c
Line in file: 2750
Project: Linux Kernel
Project version: 2.6.28
Tools: Stanse (1.2)
Entered: 2012-03-02 21:35:18 UTC


Source:

2720        __uint64_t                efi_id;
2721
2722        if (pass == XLOG_RECOVER_PASS1) {
2723                return;
2724        }
2725
2726        efd_formatp = (xfs_efd_log_format_t *)item->ri_buf[0].i_addr;
2727        ASSERT((item->ri_buf[0].i_len == (sizeof(xfs_efd_log_format_32_t) +
2728                ((efd_formatp->efd_nextents - 1) * sizeof(xfs_extent_32_t)))) ||
2729               (item->ri_buf[0].i_len == (sizeof(xfs_efd_log_format_64_t) +
2730                ((efd_formatp->efd_nextents - 1) * sizeof(xfs_extent_64_t)))));
2731        efi_id = efd_formatp->efd_efi_id;
2732
2733        /*
2734         * Search for the efi with the id in the efd format structure
2735         * in the AIL.
2736         */
2737        mp = log->l_mp;
2738        spin_lock(&mp->m_ail_lock);
2739        lip = xfs_trans_first_ail(mp, &gen);
2740        while (lip != NULL) {
2741                if (lip->li_type == XFS_LI_EFI) {
2742                        efip = (xfs_efi_log_item_t *)lip;
2743                        if (efip->efi_format.efi_id == efi_id) {
2744                                /*
2745                                 * xfs_trans_delete_ail() drops the
2746                                 * AIL lock.
2747                                 */
2748                                xfs_trans_delete_ail(mp, lip);
2749                                xfs_efi_item_free(efip);
2750                                return;
2751                        }
2752                }
2753                lip = xfs_trans_next_ail(mp, lip, &gen, NULL);
2754        }
2755        spin_unlock(&mp->m_ail_lock);
2756}
2757
2758/*
2759 * Perform the transaction
2760 *
Show full sources