The patch titled Subject: memcg-simplify-lru-handling-by-new-rule-memcg-return-eintr-at-bypassing-try_charge-fix has been added to the -mm tree. Its filename is memcg-simplify-lru-handling-by-new-rule-memcg-return-eintr-at-bypassing-try_charge-fix.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/SubmitChecklist when testing your code *** See http://userweb.kernel.org/~akpm/stuff/added-to-mm.txt to find out what to do about this The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/ ------------------------------------------------------ From: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> Subject: memcg-simplify-lru-handling-by-new-rule-memcg-return-eintr-at-bypassing-try_charge-fix clean up code comment Cc: Hugh Dickins <hughd@xxxxxxxxxx> Cc: Johannes Weiner <hannes@xxxxxxxxxxx> Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@xxxxxxxxxxxxxx> Cc: Michal Hocko <mhocko@xxxxxxx> Cc: Miklos Szeredi <mszeredi@xxxxxxx> Cc: Ying Han <yinghan@xxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- mm/memcontrol.c | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff -puN mm/memcontrol.c~memcg-simplify-lru-handling-by-new-rule-memcg-return-eintr-at-bypassing-try_charge-fix mm/memcontrol.c --- a/mm/memcontrol.c~memcg-simplify-lru-handling-by-new-rule-memcg-return-eintr-at-bypassing-try_charge-fix +++ a/mm/memcontrol.c @@ -2192,20 +2192,19 @@ static int mem_cgroup_do_charge(struct m * 3. call memory reclaim if necessary. * * In some special case, if the task is fatal, fatal_signal_pending() or - * TIF_MEMDIE, this functoion returns -EINTR with filling *ptr as - * root_mem_cgroup. There are 2 reasons for this. 1st is that - * fatal threads should quit as soon as possible without any hazards. - * 2nd is that all page should have valid pc->mem_cgroup if it will be - * used. If mm is NULL and the caller doesn't pass valid memcg pointer, - * that's treated as charge to root_mem_cgroup. + * has TIF_MEMDIE, this function returns -EINTR while writing root_mem_cgroup + * to *ptr. There are two reasons for this. 1: fatal threads should quit as soon + * as possible without any hazards. 2: all pages should have a valid + * pc->mem_cgroup. If mm is NULL and the caller doesn't pass a valid memcg + * pointer, that is treated as a charge to root_mem_cgroup. * - * So, try_charge will return - * 0 ... at success. filling *ptr with a valid memcg pointer. + * So __mem_cgroup_try_charge() will return + * 0 ... on success, filling *ptr with a valid memcg pointer. * -ENOMEM ... charge failure because of resource limits. * -EINTR ... if thread is fatal. *ptr is filled with root_mem_cgroup. * - * Unlike exported interface, "oom" parameter is added. if oom==true, - * oom-killer can be invoked. + * Unlike the exported interface, an "oom" parameter is added. if oom==true, + * the oom-killer can be invoked. */ static int __mem_cgroup_try_charge(struct mm_struct *mm, gfp_t gfp_mask, _ Subject: Subject: memcg-simplify-lru-handling-by-new-rule-memcg-return-eintr-at-bypassing-try_charge-fix Patches currently in -mm which might be from akpm@xxxxxxxxxxxxxxxxxxxx are origin.patch revert-procfs-do-not-confuse-jiffies-with-cputime64_t.patch linux-next.patch linux-next-git-rejects.patch i-need-old-gcc.patch arch-alpha-kernel-systblss-remove-debug-check.patch arch-x86-platform-iris-irisc-register-a-platform-device-and-a-platform-driver.patch x86-olpc-xo15-sci-enable-lid-close-wakeup-control-through-sysfs-fix.patch mm-vmallocc-eliminate-extra-loop-in-pcpu_get_vm_areas-error-path-fix.patch drivers-platform-x86-sony-laptopc-fix-scancodes-checkpatch-fixes.patch drivers-platform-x86-sony-laptopc-fix-scancodes-v2-checkpatch-fixes.patch slub-document-setting-min-order-with-debug_guardpage_minorder-0-checkpatch-fixes.patch mm.patch mm-add-extra-free-kbytes-tunable-update-checkpatch-fixes.patch mm-reduce-the-amount-of-work-done-when-updating-min_free_kbytes-checkpatch-fixes.patch mm-hugetlbc-fix-virtual-address-handling-in-hugetlb-fault-fix.patch mm-more-intensive-memory-corruption-debug-fix.patch mm-exclude-reserved-pages-from-dirtyable-memory-fix.patch mm-simplify-find_vma_prev-fix.patch mm-hugetlb-fix-pgoff-computation-when-unmapping-page-from-vma-fix.patch frv-duplicate-output_buffer-of-e03-checkpatch-fixes.patch hpet-factor-timer-allocate-from-open.patch treewide-convert-uses-of-attrib_noreturn-to-__noreturn-checkpatch-fixes.patch leds-add-driver-for-tca6507-led-controller.patch checkpatch-improve-memset-and-min-max-with-cast-checking-fix.patch checkpatch-catch-all-occurances-of-type-and-cast-spacing-errors-per-line-checkpatch-fixes.patch drivers-rtc-rtc-mxcc-fix-setting-time-for-mx1-soc-fix.patch drivers-rtc-rtc-mxcc-make-alarm-work-fix.patch rtc-ab8500-add-calibration-attribute-to-ab8500-rtc-checkpatch-fixes.patch rtc-ab8500-add-calibration-attribute-to-ab8500-rtc-v3-checkpatch-fixes.patch mm-vmscan-distinguish-between-memcg-triggering-reclaim-and-memcg-being-scanned-checkpatch-fixes.patch memcg-make-mem_cgroup_split_huge_fixup-more-efficient-fix.patch memcg-clear-pc-mem_cgorup-if-necessary-fix.patch memcg-clear-pc-mem_cgorup-if-necessary-fix-2-fix.patch memcg-simplify-lru-handling-by-new-rule-fix.patch memcg-simplify-lru-handling-by-new-rule-memcg-return-eintr-at-bypassing-try_charge-fix.patch procfs-introduce-the-proc-pid-map_files-directory-checkpatch-fixes.patch workqueue-make-alloc_workqueue-take-printf-fmt-and-args-for-name-fix.patch kexec-remove-kmsg_dump_kexec.patch panic-dont-print-redundant-backtraces-on-oops-fix.patch scatterlist-new-helper-functions.patch scatterlist-new-helper-functions-update-fix.patch memstick-add-support-for-legacy-memorysticks-fix.patch dio-optimize-cache-misses-in-the-submission-path-v2-checkpatch-fixes.patch selftests-new-very-basic-kernel-selftests-directory.patch c-r-procfs-add-start_data-end_data-start_brk-members-to-proc-pid-stat-v4-fix.patch c-r-prctl-add-pr_set_mm-codes-to-set-up-mm_struct-entries-fix.patch fixed-use-of-rounddown_pow_of_two-in-ramoops.patch notify_change-check-that-i_mutex-is-held.patch journal_add_journal_head-debug.patch mutex-subsystem-synchro-test-module-fix.patch slab-leaks3-default-y.patch put_bh-debug.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html