Repository navigation
Commit 4229fb1
c/r: prctl: less paranoid prctl_set_mm_exe_file()
"no other files mapped" requirement from my previous patch (c/r: prctl:
update prctl_set_mm_exe_file() after mm->num_exe_file_vmas removal) is too
paranoid, it forbids operation even if there mapped one shared-anon vma.
Let's check that current mm->exe_file already unmapped, in this case
exe_file symlink already outdated and its changing is reasonable.
Plus, this patch fixes exit code in case operation success.
Signed-off-by: Konstantin Khlebnikov <khlebnikov@openvz.org>
Reported-by: Cyrill Gorcunov <gorcunov@openvz.org>
Tested-by: Cyrill Gorcunov <gorcunov@openvz.org>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Matt Helsley <matthltc@us.ibm.com>
Cc: Kees Cook <keescook@chromium.org>
Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Pavel Emelyanov <xemul@parallels.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>1 parent a4e08d0 commit 4229fb1
1 file changed
Lines changed: 10 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1788 | 1788 | | |
1789 | 1789 | | |
1790 | 1790 | | |
1791 | | - | |
1792 | 1791 | | |
1793 | 1792 | | |
1794 | 1793 | | |
| |||
1816 | 1815 | | |
1817 | 1816 | | |
1818 | 1817 | | |
1819 | | - | |
| 1818 | + | |
1820 | 1819 | | |
1821 | 1820 | | |
1822 | | - | |
1823 | | - | |
1824 | | - | |
1825 | | - | |
| 1821 | + | |
| 1822 | + | |
| 1823 | + | |
| 1824 | + | |
| 1825 | + | |
| 1826 | + | |
| 1827 | + | |
| 1828 | + | |
1826 | 1829 | | |
1827 | 1830 | | |
1828 | 1831 | | |
| |||
1835 | 1838 | | |
1836 | 1839 | | |
1837 | 1840 | | |
| 1841 | + | |
1838 | 1842 | | |
1839 | 1843 | | |
1840 | 1844 | | |
| |||
0 commit comments