Messages in this thread Patch in this message | | | From | KOSAKI Motohiro <> | Subject | Re: Linux 2.6.31-rc7 | Date | Wed, 26 Aug 2009 14:06:50 +0900 (JST) |
| |
> On Sat, Aug 22, 2009 at 03:26, Linus > Torvalds<torvalds@linux-foundation.org> wrote: > > KOSAKI Motohiro (1): > > mm: revert "oom: move oom_adj value" > > drivers/staging/android/lowmemorykiller.c: In function 'lowmem_shrink': > drivers/staging/android/lowmemorykiller.c:108: error: 'struct > mm_struct' has no member named 'oom_adj' > > I guess this one must be reverted as well? > > commit a6a9f81ccc9f5c86ccc22bbed1960a57d0316e8b > Author: David Rientjes <rientjes@google.com> > Date: Tue Jun 16 16:42:53 2009 -0700 > > Staging: android: lowmemorykiller.c: fix it for "oom: move oom_adj value fro > > I'm about to merge "oom: move oom_adj value from task_struct to > mm_struct", and this fixup is needed to repair linux-next's > drivers/staging/android/lowmemorykiller.c. >
Thank you for very kindly bug report. Unfortunatelly I didn't notice this ugly crap driver.
Yes, you are right. it should be reverted too.
Linus, can you please consider to apply following revert patch?
============================================ Subject: [PATCH] Revert android: lowmemorykiller.c: fix it for "oom: move oom_adj value from task_struct to mm_struct"
commit 0753ba01 (mm: revert "oom: move oom_adj value") reverted some regression patch. but it didn't revert one strange oom retrieved driver patch.
Then, it made build error on this android driver.
This reverts commit a6a9f81ccc9f5c86ccc22bbed1960a57d0316e8b too and fixes the build error.
Reported-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> --- drivers/staging/android/lowmemorykiller.c | 8 +++----- 1 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/drivers/staging/android/lowmemorykiller.c b/drivers/staging/android/lowmemorykiller.c index f934393..fe72240 100644 --- a/drivers/staging/android/lowmemorykiller.c +++ b/drivers/staging/android/lowmemorykiller.c @@ -96,21 +96,19 @@ static int lowmem_shrink(int nr_to_scan, gfp_t gfp_mask) read_lock(&tasklist_lock); for_each_process(p) { - struct mm_struct *mm; int oom_adj; task_lock(p); - mm = p->mm; - if (!mm) { + if (!p->mm) { task_unlock(p); continue; } - oom_adj = mm->oom_adj; + oom_adj = p->oomkilladj; if (oom_adj < min_adj) { task_unlock(p); continue; } - tasksize = get_mm_rss(mm); + tasksize = get_mm_rss(p->mm); task_unlock(p); if (tasksize <= 0) continue; -- 1.6.2.5
-- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |