diff options
| author | Marios Pomonis <pomonis@google.com> | 2019-12-11 12:47:43 -0800 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-02-14 16:30:00 -0500 |
| commit | 784258aaf66a4018dc277ecfa9f82e551e5abc49 (patch) | |
| tree | e1e9d0b6a9187e3631a9c553794263e19f3d6228 /kernel/workqueue.c | |
| parent | 5372b007fa8a4930163c7aa997750f6288540ba6 (diff) | |
KVM: x86: Refactor picdev_write() to prevent Spectre-v1/L1TF attacks
[ Upstream commit 14e32321f3606e4b0970200b6e5e47ee6f1e6410 ]
This fixes a Spectre-v1/L1TF vulnerability in picdev_write().
It replaces index computations based on the (attacked-controlled) port
number with constants through a minor refactoring.
Fixes: 85f455f7ddbe ("KVM: Add support for in-kernel PIC emulation")
Signed-off-by: Nick Finco <nifi@google.com>
Signed-off-by: Marios Pomonis <pomonis@google.com>
Reviewed-by: Andrew Honig <ahonig@google.com>
Cc: stable@vger.kernel.org
Reviewed-by: Jim Mattson <jmattson@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'kernel/workqueue.c')
0 files changed, 0 insertions, 0 deletions
