]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - fs/ntfs/mft.c
Merge git://git.kernel.org/pub/scm/linux/kernel/git/steve/gfs2-2.6-nmw
[linux-2.6-omap-h63xx.git] / fs / ntfs / mft.c
index 2ad5c8b104b934c9177e162d2c20c6da211ed0d9..17d32ca6bc35b7dc5036033e1afa8b91e5ee4d38 100644 (file)
@@ -586,7 +586,7 @@ int ntfs_sync_mft_mirror(ntfs_volume *vol, const unsigned long mft_no,
                for (i_bhs = 0; i_bhs < nr_bhs; i_bhs++) {
                        struct buffer_head *tbh = bhs[i_bhs];
 
-                       if (unlikely(test_set_buffer_locked(tbh)))
+                       if (!trylock_buffer(tbh))
                                BUG();
                        BUG_ON(!buffer_uptodate(tbh));
                        clear_buffer_dirty(tbh);
@@ -779,7 +779,7 @@ int write_mft_record_nolock(ntfs_inode *ni, MFT_RECORD *m, int sync)
        for (i_bhs = 0; i_bhs < nr_bhs; i_bhs++) {
                struct buffer_head *tbh = bhs[i_bhs];
 
-               if (unlikely(test_set_buffer_locked(tbh)))
+               if (!trylock_buffer(tbh))
                        BUG();
                BUG_ON(!buffer_uptodate(tbh));
                clear_buffer_dirty(tbh);
@@ -1191,7 +1191,7 @@ static int ntfs_mft_bitmap_find_and_alloc_free_rec_nolock(ntfs_volume *vol,
                if (size) {
                        page = ntfs_map_page(mftbmp_mapping,
                                        ofs >> PAGE_CACHE_SHIFT);
-                       if (unlikely(IS_ERR(page))) {
+                       if (IS_ERR(page)) {
                                ntfs_error(vol->sb, "Failed to read mft "
                                                "bitmap, aborting.");
                                return PTR_ERR(page);
@@ -2118,7 +2118,7 @@ static int ntfs_mft_record_format(const ntfs_volume *vol, const s64 mft_no)
        }
        /* Read, map, and pin the page containing the mft record. */
        page = ntfs_map_page(mft_vi->i_mapping, index);
-       if (unlikely(IS_ERR(page))) {
+       if (IS_ERR(page)) {
                ntfs_error(vol->sb, "Failed to map page containing mft record "
                                "to format 0x%llx.", (long long)mft_no);
                return PTR_ERR(page);
@@ -2519,7 +2519,7 @@ mft_rec_already_initialized:
        ofs = (bit << vol->mft_record_size_bits) & ~PAGE_CACHE_MASK;
        /* Read, map, and pin the page containing the mft record. */
        page = ntfs_map_page(vol->mft_ino->i_mapping, index);
-       if (unlikely(IS_ERR(page))) {
+       if (IS_ERR(page)) {
                ntfs_error(vol->sb, "Failed to map page containing allocated "
                                "mft record 0x%llx.", (long long)bit);
                err = PTR_ERR(page);