mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 03:01:39 -04:00
Merge branch 'master' of /home/davem/src/GIT/linux-2.6/
Conflicts: drivers/firmware/iscsi_ibft.c
This commit is contained in:
commit
47871889c6
2090 changed files with 103844 additions and 44833 deletions
|
|
@ -195,7 +195,7 @@ config BOUNCE
|
|||
config NR_QUICK
|
||||
int
|
||||
depends on QUICKLIST
|
||||
default "2" if SUPERH || AVR32
|
||||
default "2" if AVR32
|
||||
default "1"
|
||||
|
||||
config VIRT_TO_BUS
|
||||
|
|
|
|||
36
mm/migrate.c
36
mm/migrate.c
|
|
@ -1002,33 +1002,27 @@ static int do_pages_stat(struct mm_struct *mm, unsigned long nr_pages,
|
|||
#define DO_PAGES_STAT_CHUNK_NR 16
|
||||
const void __user *chunk_pages[DO_PAGES_STAT_CHUNK_NR];
|
||||
int chunk_status[DO_PAGES_STAT_CHUNK_NR];
|
||||
unsigned long i, chunk_nr = DO_PAGES_STAT_CHUNK_NR;
|
||||
int err;
|
||||
|
||||
for (i = 0; i < nr_pages; i += chunk_nr) {
|
||||
if (chunk_nr > nr_pages - i)
|
||||
chunk_nr = nr_pages - i;
|
||||
while (nr_pages) {
|
||||
unsigned long chunk_nr;
|
||||
|
||||
err = copy_from_user(chunk_pages, &pages[i],
|
||||
chunk_nr * sizeof(*chunk_pages));
|
||||
if (err) {
|
||||
err = -EFAULT;
|
||||
goto out;
|
||||
}
|
||||
chunk_nr = nr_pages;
|
||||
if (chunk_nr > DO_PAGES_STAT_CHUNK_NR)
|
||||
chunk_nr = DO_PAGES_STAT_CHUNK_NR;
|
||||
|
||||
if (copy_from_user(chunk_pages, pages, chunk_nr * sizeof(*chunk_pages)))
|
||||
break;
|
||||
|
||||
do_pages_stat_array(mm, chunk_nr, chunk_pages, chunk_status);
|
||||
|
||||
err = copy_to_user(&status[i], chunk_status,
|
||||
chunk_nr * sizeof(*chunk_status));
|
||||
if (err) {
|
||||
err = -EFAULT;
|
||||
goto out;
|
||||
}
|
||||
}
|
||||
err = 0;
|
||||
if (copy_to_user(status, chunk_status, chunk_nr * sizeof(*status)))
|
||||
break;
|
||||
|
||||
out:
|
||||
return err;
|
||||
pages += chunk_nr;
|
||||
status += chunk_nr;
|
||||
nr_pages -= chunk_nr;
|
||||
}
|
||||
return nr_pages ? -EFAULT : 0;
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -459,6 +459,8 @@ static int oom_kill_process(struct task_struct *p, gfp_t gfp_mask, int order,
|
|||
list_for_each_entry(c, &p->children, sibling) {
|
||||
if (c->mm == p->mm)
|
||||
continue;
|
||||
if (mem && !task_in_mem_cgroup(c, mem))
|
||||
continue;
|
||||
if (!oom_kill_task(c))
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue