mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* Fixup the page of buddy_higher address's calculation
@ 2012-08-23  8:40 Li Haifeng
  2012-08-23  9:50 ` Michal Hocko
  0 siblings, 1 reply; 8+ messages in thread
From: Li Haifeng @ 2012-08-23  8:40 UTC (permalink / raw)
  To: Andrew Morton, Michal Hocko, Mel Gorman, Minchan Kim,
	Johannes Weiner, linux-mm, linux-kernel

>From d7cd78f9d71a5c9ddeed02724558096f0bb4508a Mon Sep 17 00:00:00 2001
From: Haifeng Li <omycle@gmail.com>
Date: Thu, 23 Aug 2012 16:27:19 +0800
Subject: [PATCH] Fixup the page of buddy_higher address's calculation

Signed-off-by: Haifeng Li <omycle@gmail.com>
---
 mm/page_alloc.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/mm/page_alloc.c b/mm/page_alloc.c
index ddbc17d..5588f68 100644
--- a/mm/page_alloc.c
+++ b/mm/page_alloc.c
@@ -579,7 +579,7 @@ static inline void __free_one_page(struct page *page,
                combined_idx = buddy_idx & page_idx;
                higher_page = page + (combined_idx - page_idx);
                buddy_idx = __find_buddy_index(combined_idx, order + 1);
-               higher_buddy = page + (buddy_idx - combined_idx);
+               higher_buddy = page + (buddy_idx - page_idx);
                if (page_is_buddy(higher_page, higher_buddy, order + 1)) {
                        list_add_tail(&page->lru,
                                &zone->free_area[order].free_list[migratetype]);
--
1.7.5.4

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

end of thread, other threads:[~2012-08-24  9:44 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-08-23  8:40 Fixup the page of buddy_higher address's calculation Li Haifeng
2012-08-23  9:50 ` Michal Hocko
2012-08-23 10:21   ` Li Haifeng
     [not found]     ` <20120823123034.GA3793@shangw.(null)>
2012-08-23 13:58       ` Michal Hocko
2012-08-24  2:08         ` Li Haifeng
2012-08-24  8:06           ` Michal Hocko
2012-08-24  9:08             ` Li Haifeng
2012-08-24  9:44               ` Michal Hocko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome