aboutsummaryrefslogtreecommitdiffstats
path: root/mm
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2014-05-27 11:38:08 -0400
committerTakashi Iwai <tiwai@suse.de>2014-05-27 11:38:08 -0400
commita58bdba749b36069ec372da9c9fd16017b6c0b47 (patch)
tree95c79448427425d1c05712a7c7fb98ed42e41539 /mm
parent00a6d7b6762c27d441e9ac8faff36384bc0fc180 (diff)
parent51fa31d462f32e1ffdf957802dcab1dc20d2f243 (diff)
Merge branch 'topic/firewire' into for-next
This is a merge of big firewire audio stack updates by Takashi Sakamoto.
Diffstat (limited to 'mm')
-rw-r--r--mm/Kconfig15
-rw-r--r--mm/kmemleak.c4
-rw-r--r--mm/mremap.c9
-rw-r--r--mm/percpu.c2
4 files changed, 26 insertions, 4 deletions
diff --git a/mm/Kconfig b/mm/Kconfig
index ebe5880c29d6..1b5a95f0fa01 100644
--- a/mm/Kconfig
+++ b/mm/Kconfig
@@ -581,3 +581,18 @@ config PGTABLE_MAPPING
581 581
582config GENERIC_EARLY_IOREMAP 582config GENERIC_EARLY_IOREMAP
583 bool 583 bool
584
585config MAX_STACK_SIZE_MB
586 int "Maximum user stack size for 32-bit processes (MB)"
587 default 80
588 range 8 256 if METAG
589 range 8 2048
590 depends on STACK_GROWSUP && (!64BIT || COMPAT)
591 help
592 This is the maximum stack size in Megabytes in the VM layout of 32-bit
593 user processes when the stack grows upwards (currently only on parisc
594 and metag arch). The stack will be located at the highest memory
595 address minus the given value, unless the RLIMIT_STACK hard limit is
596 changed to a smaller value in which case that is used.
597
598 A sane initial value is 80 MB.
diff --git a/mm/kmemleak.c b/mm/kmemleak.c
index 91d67eaee050..8d2fcdfeff7f 100644
--- a/mm/kmemleak.c
+++ b/mm/kmemleak.c
@@ -1775,10 +1775,9 @@ void __init kmemleak_init(void)
1775 int i; 1775 int i;
1776 unsigned long flags; 1776 unsigned long flags;
1777 1777
1778 kmemleak_early_log = 0;
1779
1780#ifdef CONFIG_DEBUG_KMEMLEAK_DEFAULT_OFF 1778#ifdef CONFIG_DEBUG_KMEMLEAK_DEFAULT_OFF
1781 if (!kmemleak_skip_disable) { 1779 if (!kmemleak_skip_disable) {
1780 kmemleak_early_log = 0;
1782 kmemleak_disable(); 1781 kmemleak_disable();
1783 return; 1782 return;
1784 } 1783 }
@@ -1796,6 +1795,7 @@ void __init kmemleak_init(void)
1796 1795
1797 /* the kernel is still in UP mode, so disabling the IRQs is enough */ 1796 /* the kernel is still in UP mode, so disabling the IRQs is enough */
1798 local_irq_save(flags); 1797 local_irq_save(flags);
1798 kmemleak_early_log = 0;
1799 if (kmemleak_error) { 1799 if (kmemleak_error) {
1800 local_irq_restore(flags); 1800 local_irq_restore(flags);
1801 return; 1801 return;
diff --git a/mm/mremap.c b/mm/mremap.c
index 0843feb66f3d..05f1180e9f21 100644
--- a/mm/mremap.c
+++ b/mm/mremap.c
@@ -194,10 +194,17 @@ unsigned long move_page_tables(struct vm_area_struct *vma,
194 break; 194 break;
195 if (pmd_trans_huge(*old_pmd)) { 195 if (pmd_trans_huge(*old_pmd)) {
196 int err = 0; 196 int err = 0;
197 if (extent == HPAGE_PMD_SIZE) 197 if (extent == HPAGE_PMD_SIZE) {
198 VM_BUG_ON(vma->vm_file || !vma->anon_vma);
199 /* See comment in move_ptes() */
200 if (need_rmap_locks)
201 anon_vma_lock_write(vma->anon_vma);
198 err = move_huge_pmd(vma, new_vma, old_addr, 202 err = move_huge_pmd(vma, new_vma, old_addr,
199 new_addr, old_end, 203 new_addr, old_end,
200 old_pmd, new_pmd); 204 old_pmd, new_pmd);
205 if (need_rmap_locks)
206 anon_vma_unlock_write(vma->anon_vma);
207 }
201 if (err > 0) { 208 if (err > 0) {
202 need_flush = true; 209 need_flush = true;
203 continue; 210 continue;
diff --git a/mm/percpu.c b/mm/percpu.c
index 63e24fb4387b..2ddf9a990dbd 100644
--- a/mm/percpu.c
+++ b/mm/percpu.c
@@ -610,7 +610,7 @@ static struct pcpu_chunk *pcpu_alloc_chunk(void)
610 chunk->map = pcpu_mem_zalloc(PCPU_DFL_MAP_ALLOC * 610 chunk->map = pcpu_mem_zalloc(PCPU_DFL_MAP_ALLOC *
611 sizeof(chunk->map[0])); 611 sizeof(chunk->map[0]));
612 if (!chunk->map) { 612 if (!chunk->map) {
613 kfree(chunk); 613 pcpu_mem_free(chunk, pcpu_chunk_struct_size);
614 return NULL; 614 return NULL;
615 } 615 }
616 616