diff options
author | Xiaomeng Tong <xiam0nd.tong@gmail.com> | 2022-03-14 15:29:21 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2022-03-18 16:35:01 +0300 |
commit | b31c41339f4f8a833cb9dc509f87aab6a159ffe4 (patch) | |
tree | d7c026b19d3de366b23647c0150a687d550faadb /sound/synth | |
parent | f58c252e30cf74f68b0054293adc03b5923b9f0e (diff) | |
download | linux-b31c41339f4f8a833cb9dc509f87aab6a159ffe4.tar.xz |
vt_ioctl: fix potential spectre v1 in VT_DISALLOCATE
In VT_ACTIVATE an almost identical code path has been patched
with array_index_nospec. In the VT_DISALLOCATE path, the arg is
the user input from a system call argument and lately used as a index
for vc_cons[index].d access, which can be reached through path like
vt_disallocate->vc_busy or vt_disallocate->vc_deallocate.
For consistency both code paths should have the same mitigations
applied. Also, the code style is adjusted as suggested by Jiri.
Reviewed-by: Jiri Slaby <jirislaby@kernel.org>
Signed-off-by: Xiaomeng Tong <xiam0nd.tong@gmail.com>
Link: https://lore.kernel.org/r/20220314122921.31223-1-xiam0nd.tong@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'sound/synth')
0 files changed, 0 insertions, 0 deletions