+ lib-genallocc-fix-the-end-addr-check-in-addr_in_gen_pool.patch added to -mm tree

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

 



The patch titled
     Subject: lib/genalloc.c: fix the end addr check in addr_in_gen_pool()
has been added to the -mm tree.  Its filename is
     lib-genallocc-fix-the-end-addr-check-in-addr_in_gen_pool.patch

This patch should soon appear at
    http://ozlabs.org/~akpm/mmots/broken-out/lib-genallocc-fix-the-end-addr-check-in-addr_in_gen_pool.patch
and later at
    http://ozlabs.org/~akpm/mmotm/broken-out/lib-genallocc-fix-the-end-addr-check-in-addr_in_gen_pool.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 ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Toshi Kikuchi <toshik@xxxxxxxxxxxx>
Subject: lib/genalloc.c: fix the end addr check in addr_in_gen_pool()

Since chunk->end_addr is (chunk->start_addr + size - 1), the end address
to compare should be (start + size - 1).

Signed-off-by: Toshi Kikuchi <toshik@xxxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 lib/genalloc.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -puN lib/genalloc.c~lib-genallocc-fix-the-end-addr-check-in-addr_in_gen_pool lib/genalloc.c
--- a/lib/genalloc.c~lib-genallocc-fix-the-end-addr-check-in-addr_in_gen_pool
+++ a/lib/genalloc.c
@@ -415,7 +415,7 @@ bool addr_in_gen_pool(struct gen_pool *p
 			size_t size)
 {
 	bool found = false;
-	unsigned long end = start + size;
+	unsigned long end = start + size - 1;
 	struct gen_pool_chunk *chunk;
 
 	rcu_read_lock();
_

Patches currently in -mm which might be from toshik@xxxxxxxxxxxx are

lib-genallocc-fix-the-end-addr-check-in-addr_in_gen_pool.patch
linux-next.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