The patch titled Subject: fs/proc/proc_sysctl.c: remove redundant link check in proc_sys_link_fill_cache() has been added to the -mm tree. Its filename is fs-sysctl-remove-redundant-link-check-in-proc_sys_link_fill_cache.patch This patch should soon appear at http://ozlabs.org/~akpm/mmots/broken-out/fs-sysctl-remove-redundant-link-check-in-proc_sys_link_fill_cache.patch and later at http://ozlabs.org/~akpm/mmotm/broken-out/fs-sysctl-remove-redundant-link-check-in-proc_sys_link_fill_cache.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 *** The -mm tree is included into linux-next and is updated there every 3-4 working days ------------------------------------------------------ From: Danilo Krummrich <danilokrummrich@xxxxxxxxxxxxx> Subject: fs/proc/proc_sysctl.c: remove redundant link check in proc_sys_link_fill_cache() proc_sys_link_fill_cache() does not need to check whether we're called for a link - it's already done by scan(). Link: http://lkml.kernel.org/r/20180228013506.4915-2-danilokrummrich@xxxxxxxxxxxxx Signed-off-by: Danilo Krummrich <danilokrummrich@xxxxxxxxxxxxx> Acked-by: Kees Cook <keescook@xxxxxxxxxxxx> Cc: Alexey Dobriyan <adobriyan@xxxxxxxxx> Cc: "Eric W. Biederman" <ebiederm@xxxxxxxxxxxx> Cc: "Luis R . Rodriguez" <mcgrof@xxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- fs/proc/proc_sysctl.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff -puN fs/proc/proc_sysctl.c~fs-sysctl-remove-redundant-link-check-in-proc_sys_link_fill_cache fs/proc/proc_sysctl.c --- a/fs/proc/proc_sysctl.c~fs-sysctl-remove-redundant-link-check-in-proc_sys_link_fill_cache +++ a/fs/proc/proc_sysctl.c @@ -712,12 +712,9 @@ static bool proc_sys_link_fill_cache(str if (IS_ERR(head)) return false; - if (S_ISLNK(table->mode)) { - /* It is not an error if we can not follow the link ignore it */ - int err = sysctl_follow_link(&head, &table); - if (err) - goto out; - } + /* It is not an error if we can not follow the link ignore it */ + if (sysctl_follow_link(&head, &table)) + goto out; ret = proc_sys_fill_cache(file, ctx, head, table); out: _ Patches currently in -mm which might be from danilokrummrich@xxxxxxxxxxxxx are fs-sysctl-fix-potential-page-fault-while-unregistering-sysctl-table.patch fs-sysctl-remove-redundant-link-check-in-proc_sys_link_fill_cache.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