.. | .. |
---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only |
---|
1 | 2 | /* |
---|
2 | 3 | * Copyright (C) 2011 Richard Weinberger <richrd@nod.at> |
---|
3 | | - * |
---|
4 | | - * This program is free software; you can redistribute it and/or modify |
---|
5 | | - * it under the terms of the GNU General Public License version 2 as |
---|
6 | | - * published by the Free Software Foundation. |
---|
7 | 4 | */ |
---|
8 | 5 | |
---|
9 | 6 | #include <linux/slab.h> |
---|
.. | .. |
---|
61 | 58 | if (!vdso_enabled) |
---|
62 | 59 | return 0; |
---|
63 | 60 | |
---|
64 | | - if (down_write_killable(&mm->mmap_sem)) |
---|
| 61 | + if (mmap_write_lock_killable(mm)) |
---|
65 | 62 | return -EINTR; |
---|
66 | 63 | |
---|
67 | 64 | err = install_special_mapping(mm, um_vdso_addr, PAGE_SIZE, |
---|
.. | .. |
---|
69 | 66 | VM_MAYREAD|VM_MAYWRITE|VM_MAYEXEC, |
---|
70 | 67 | vdsop); |
---|
71 | 68 | |
---|
72 | | - up_write(&mm->mmap_sem); |
---|
| 69 | + mmap_write_unlock(mm); |
---|
73 | 70 | |
---|
74 | 71 | return err; |
---|
75 | 72 | } |
---|