]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
jbd2: remove the second argument of k[un]map_atomic()
authorCong Wang <amwang@redhat.com>
Fri, 25 Nov 2011 15:14:31 +0000 (23:14 +0800)
committerCong Wang <amwang@redhat.com>
Fri, 2 Dec 2011 03:12:57 +0000 (11:12 +0800)
fs/jbd2/commit.c
fs/jbd2/journal.c
fs/jbd2/transaction.c

index 68d704db787f108350f9cc47fd506628685399c7..5b272bc87dbfdc763c8fdb1805c1ada5f53ed43a 100644 (file)
@@ -286,10 +286,10 @@ static __u32 jbd2_checksum_data(__u32 crc32_sum, struct buffer_head *bh)
        char *addr;
        __u32 checksum;
 
-       addr = kmap_atomic(page, KM_USER0);
+       addr = kmap_atomic(page);
        checksum = crc32_be(crc32_sum,
                (void *)(addr + offset_in_page(bh->b_data)), bh->b_size);
-       kunmap_atomic(addr, KM_USER0);
+       kunmap_atomic(addr);
 
        return checksum;
 }
index 0fa0123151d3117c5d3678c1bc36bf7b5bb00cd4..f251d6aec3ba35c80218cead4ca3938b8e9957f6 100644 (file)
@@ -345,7 +345,7 @@ repeat:
                new_offset = offset_in_page(jh2bh(jh_in)->b_data);
        }
 
-       mapped_data = kmap_atomic(new_page, KM_USER0);
+       mapped_data = kmap_atomic(new_page);
        /*
         * Fire data frozen trigger if data already wasn't frozen.  Do this
         * before checking for escaping, as the trigger may modify the magic
@@ -364,7 +364,7 @@ repeat:
                need_copy_out = 1;
                do_escape = 1;
        }
-       kunmap_atomic(mapped_data, KM_USER0);
+       kunmap_atomic(mapped_data);
 
        /*
         * Do we need to do a data copy?
@@ -385,9 +385,9 @@ repeat:
                }
 
                jh_in->b_frozen_data = tmp;
-               mapped_data = kmap_atomic(new_page, KM_USER0);
+               mapped_data = kmap_atomic(new_page);
                memcpy(tmp, mapped_data + new_offset, jh2bh(jh_in)->b_size);
-               kunmap_atomic(mapped_data, KM_USER0);
+               kunmap_atomic(mapped_data);
 
                new_page = virt_to_page(tmp);
                new_offset = offset_in_page(tmp);
@@ -406,9 +406,9 @@ repeat:
         * copying, we can finally do so.
         */
        if (do_escape) {
-               mapped_data = kmap_atomic(new_page, KM_USER0);
+               mapped_data = kmap_atomic(new_page);
                *((unsigned int *)(mapped_data + new_offset)) = 0;
-               kunmap_atomic(mapped_data, KM_USER0);
+               kunmap_atomic(mapped_data);
        }
 
        set_bh_page(new_bh, new_page, new_offset);
index a0e41a4c080e9b2d3a51f5b4c6404cb8b8bc9c2b..5d8de98a07be7a07235de115913b4c99be69ff47 100644 (file)
@@ -782,12 +782,12 @@ done:
                            "Possible IO failure.\n");
                page = jh2bh(jh)->b_page;
                offset = offset_in_page(jh2bh(jh)->b_data);
-               source = kmap_atomic(page, KM_USER0);
+               source = kmap_atomic(page);
                /* Fire data frozen trigger just before we copy the data */
                jbd2_buffer_frozen_trigger(jh, source + offset,
                                           jh->b_triggers);
                memcpy(jh->b_frozen_data, source+offset, jh2bh(jh)->b_size);
-               kunmap_atomic(source, KM_USER0);
+               kunmap_atomic(source);
 
                /*
                 * Now that the frozen data is saved off, we need to store