Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'akpm' (fixes from Andrew Morton)

Merge fixes from Andrew Morton:
"5 fixes"

* emailed patches from Andrew Morton <akpm@linux-foundation.org>:
mm: page_alloc: fix zone allocation fairness on UP
perf: fix perf bug in fork()
MAINTAINERS: change git URL for mpc5xxx tree
mm: memcontrol: do not iterate uninitialized memcgs
ocfs2/dlm: should put mle when goto kill in dlm_assert_master_handler

+45 -13
+1 -1
MAINTAINERS
··· 5484 5484 LINUX FOR POWERPC EMBEDDED MPC5XXX 5485 5485 M: Anatolij Gustschin <agust@denx.de> 5486 5486 L: linuxppc-dev@lists.ozlabs.org 5487 - T: git git://git.denx.de/linux-2.6-agust.git 5487 + T: git git://git.denx.de/linux-denx-agust.git 5488 5488 S: Maintained 5489 5489 F: arch/powerpc/platforms/512x/ 5490 5490 F: arch/powerpc/platforms/52xx/
+4
fs/ocfs2/dlm/dlmmaster.c
··· 2039 2039 "and killing the other node now! This node is OK and can continue.\n"); 2040 2040 __dlm_print_one_lock_resource(res); 2041 2041 spin_unlock(&res->spinlock); 2042 + spin_lock(&dlm->master_lock); 2043 + if (mle) 2044 + __dlm_put_mle(mle); 2045 + spin_unlock(&dlm->master_lock); 2042 2046 spin_unlock(&dlm->spinlock); 2043 2047 *ret_data = (void *)res; 2044 2048 dlm_put(dlm);
+3 -1
kernel/events/core.c
··· 7948 7948 7949 7949 for_each_task_context_nr(ctxn) { 7950 7950 ret = perf_event_init_context(child, ctxn); 7951 - if (ret) 7951 + if (ret) { 7952 + perf_event_free_task(child); 7952 7953 return ret; 7954 + } 7953 7955 } 7954 7956 7955 7957 return 0;
+3 -2
kernel/fork.c
··· 1360 1360 goto bad_fork_cleanup_policy; 1361 1361 retval = audit_alloc(p); 1362 1362 if (retval) 1363 - goto bad_fork_cleanup_policy; 1363 + goto bad_fork_cleanup_perf; 1364 1364 /* copy all the process information */ 1365 1365 shm_init_task(p); 1366 1366 retval = copy_semundo(clone_flags, p); ··· 1566 1566 exit_sem(p); 1567 1567 bad_fork_cleanup_audit: 1568 1568 audit_free(p); 1569 - bad_fork_cleanup_policy: 1569 + bad_fork_cleanup_perf: 1570 1570 perf_event_free_task(p); 1571 + bad_fork_cleanup_policy: 1571 1572 #ifdef CONFIG_NUMA 1572 1573 mpol_put(p->mempolicy); 1573 1574 bad_fork_cleanup_threadgroup_lock:
+31 -5
mm/memcontrol.c
··· 292 292 /* vmpressure notifications */ 293 293 struct vmpressure vmpressure; 294 294 295 + /* css_online() has been completed */ 296 + int initialized; 297 + 295 298 /* 296 299 * the counter to account for mem+swap usage. 297 300 */ ··· 1102 1099 * skipping css reference should be safe. 1103 1100 */ 1104 1101 if (next_css) { 1105 - if ((next_css == &root->css) || 1106 - ((next_css->flags & CSS_ONLINE) && 1107 - css_tryget_online(next_css))) 1108 - return mem_cgroup_from_css(next_css); 1102 + struct mem_cgroup *memcg = mem_cgroup_from_css(next_css); 1103 + 1104 + if (next_css == &root->css) 1105 + return memcg; 1106 + 1107 + if (css_tryget_online(next_css)) { 1108 + /* 1109 + * Make sure the memcg is initialized: 1110 + * mem_cgroup_css_online() orders the the 1111 + * initialization against setting the flag. 1112 + */ 1113 + if (smp_load_acquire(&memcg->initialized)) 1114 + return memcg; 1115 + css_put(next_css); 1116 + } 1109 1117 1110 1118 prev_css = next_css; 1111 1119 goto skip_node; ··· 5563 5549 { 5564 5550 struct mem_cgroup *memcg = mem_cgroup_from_css(css); 5565 5551 struct mem_cgroup *parent = mem_cgroup_from_css(css->parent); 5552 + int ret; 5566 5553 5567 5554 if (css->id > MEM_CGROUP_ID_MAX) 5568 5555 return -ENOSPC; ··· 5600 5585 } 5601 5586 mutex_unlock(&memcg_create_mutex); 5602 5587 5603 - return memcg_init_kmem(memcg, &memory_cgrp_subsys); 5588 + ret = memcg_init_kmem(memcg, &memory_cgrp_subsys); 5589 + if (ret) 5590 + return ret; 5591 + 5592 + /* 5593 + * Make sure the memcg is initialized: mem_cgroup_iter() 5594 + * orders reading memcg->initialized against its callers 5595 + * reading the memcg members. 5596 + */ 5597 + smp_store_release(&memcg->initialized, 1); 5598 + 5599 + return 0; 5604 5600 } 5605 5601 5606 5602 /*
+3 -4
mm/page_alloc.c
··· 1612 1612 } 1613 1613 1614 1614 __mod_zone_page_state(zone, NR_ALLOC_BATCH, -(1 << order)); 1615 - if (zone_page_state(zone, NR_ALLOC_BATCH) == 0 && 1615 + if (atomic_long_read(&zone->vm_stat[NR_ALLOC_BATCH]) <= 0 && 1616 1616 !zone_is_fair_depleted(zone)) 1617 1617 zone_set_flag(zone, ZONE_FAIR_DEPLETED); 1618 1618 ··· 5701 5701 zone->watermark[WMARK_HIGH] = min_wmark_pages(zone) + (tmp >> 1); 5702 5702 5703 5703 __mod_zone_page_state(zone, NR_ALLOC_BATCH, 5704 - high_wmark_pages(zone) - 5705 - low_wmark_pages(zone) - 5706 - zone_page_state(zone, NR_ALLOC_BATCH)); 5704 + high_wmark_pages(zone) - low_wmark_pages(zone) - 5705 + atomic_long_read(&zone->vm_stat[NR_ALLOC_BATCH])); 5707 5706 5708 5707 setup_zone_migrate_reserve(zone); 5709 5708 spin_unlock_irqrestore(&zone->lock, flags);