linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/3] percpu: clean up of schunk->map[] assignment in pcpu_setup_first_chunk
@ 2015-07-20 14:55 Baoquan He
  2015-07-20 14:55 ` [PATCH 2/3] perpuc: check pcpu_first_chunk and pcpu_reserved_chunk to avoid handling them twice Baoquan He
                   ` (3 more replies)
  0 siblings, 4 replies; 20+ messages in thread
From: Baoquan He @ 2015-07-20 14:55 UTC (permalink / raw)
  To: tj, cl, linux-mm, linux-kernel; +Cc: Baoquan He

The original assignment is a little redundent.

Signed-off-by: Baoquan He <bhe@redhat.com>
---
 mm/percpu.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/mm/percpu.c b/mm/percpu.c
index 2dd7448..a63b4d8 100644
--- a/mm/percpu.c
+++ b/mm/percpu.c
@@ -1668,9 +1668,8 @@ int __init pcpu_setup_first_chunk(const struct pcpu_alloc_info *ai,
 	schunk->map[1] = ai->static_size;
 	schunk->map_used = 1;
 	if (schunk->free_size)
-		schunk->map[++schunk->map_used] = 1 | (ai->static_size + schunk->free_size);
-	else
-		schunk->map[1] |= 1;
+		schunk->map[++schunk->map_used] = ai->static_size + schunk->free_size;
+	schunk->map[schunk->map_used] |= 1;
 
 	/* init dynamic chunk if necessary */
 	if (dyn_size) {
-- 
1.9.3

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply related	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2015-07-23  1:56 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-20 14:55 [PATCH 1/3] percpu: clean up of schunk->map[] assignment in pcpu_setup_first_chunk Baoquan He
2015-07-20 14:55 ` [PATCH 2/3] perpuc: check pcpu_first_chunk and pcpu_reserved_chunk to avoid handling them twice Baoquan He
2015-07-21 15:28   ` Tejun Heo
2015-07-22  0:03     ` Baoquan He
2015-07-22 13:52       ` Tejun Heo
2015-07-22 14:29         ` Baoquan He
2015-07-22 14:37           ` Tejun Heo
2015-07-23  1:56             ` Baoquan He
2015-07-23  1:53   ` [PATCH v3 2/3] percpu: Add WARN_ON into percpu_init_late Baoquan He
2015-07-20 14:55 ` [PATCH 3/3] percpu: add macro PCPU_CHUNK_AREA_IN_USE Baoquan He
2015-07-20 15:35   ` Christoph Lameter
2015-07-22  0:25     ` Baoquan He
2015-07-21 15:30   ` Tejun Heo
2015-07-22  0:28     ` Baoquan He
2015-07-22 13:53       ` Tejun Heo
2015-07-23  1:55         ` Baoquan He
2015-07-23  1:50   ` [PATCH v2 3/3] percpu: add macro PCPU_MAP_BUSY Baoquan He
2015-07-20 15:32 ` [PATCH 1/3] percpu: clean up of schunk->map[] assignment in pcpu_setup_first_chunk Christoph Lameter
2015-07-21 15:33 ` Tejun Heo
2015-07-22  0:56   ` Baoquan He

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).