+ vfs-check-bh-b_blocknr-only-if-bh_mapped-is-set.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     vfs: check bh->b_blocknr only if BH_Mapped is set
has been added to the -mm tree.  Its filename is
     vfs-check-bh-b_blocknr-only-if-bh_mapped-is-set.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/SubmitChecklist when testing your code ***

See http://userweb.kernel.org/~akpm/stuff/added-to-mm.txt to find
out what to do about this

The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/

------------------------------------------------------
Subject: vfs: check bh->b_blocknr only if BH_Mapped is set
From: Nikanth Karthikesan <knikanth@xxxxxxx>

Check bh->b_blocknr only if BH_Mapped is set.

Signed-off-by: Nikanth Karthikesan <knikanth@xxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 fs/buffer.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff -puN fs/buffer.c~vfs-check-bh-b_blocknr-only-if-bh_mapped-is-set fs/buffer.c
--- a/fs/buffer.c~vfs-check-bh-b_blocknr-only-if-bh_mapped-is-set
+++ a/fs/buffer.c
@@ -344,13 +344,13 @@ __find_get_block_slow(struct block_devic
 	head = page_buffers(page);
 	bh = head;
 	do {
-		if (bh->b_blocknr == block) {
+		if (!buffer_mapped(bh))
+			all_mapped = 0;
+		else if (bh->b_blocknr == block) {
 			ret = bh;
 			get_bh(bh);
 			goto out_unlock;
 		}
-		if (!buffer_mapped(bh))
-			all_mapped = 0;
 		bh = bh->b_this_page;
 	} while (bh != head);
 
_

Patches currently in -mm which might be from knikanth@xxxxxxx are

vfs-check-bh-b_blocknr-only-if-bh_mapped-is-set.patch

--
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux