diff options
author | Joerg Roedel <jroedel@suse.de> | 2023-06-21 17:42:42 +0200 |
---|---|---|
committer | Borislav Petkov (AMD) <bp@alien8.de> | 2023-10-09 15:47:57 +0200 |
commit | b9cb9c45583b911e0db71d09caa6b56469eb2bdf (patch) | |
tree | b8046c802a8613737f7603624dbfb6d7dbe48db4 /arch/x86/boot | |
parent | a37cd2a59d0cb270b1bba568fd3a3b8668b9d3ba (diff) | |
download | linux-stable-b9cb9c45583b911e0db71d09caa6b56469eb2bdf.tar.gz linux-stable-b9cb9c45583b911e0db71d09caa6b56469eb2bdf.tar.bz2 linux-stable-b9cb9c45583b911e0db71d09caa6b56469eb2bdf.zip |
x86/sev: Check IOBM for IOIO exceptions from user-space
Check the IO permission bitmap (if present) before emulating IOIO #VC
exceptions for user-space. These permissions are checked by hardware
already before the #VC is raised, but due to the VC-handler decoding
race it needs to be checked again in software.
Fixes: 25189d08e516 ("x86/sev-es: Add support for handling IOIO exceptions")
Reported-by: Tom Dohrmann <erbse.13@gmx.de>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Tested-by: Tom Dohrmann <erbse.13@gmx.de>
Cc: <stable@kernel.org>
Diffstat (limited to 'arch/x86/boot')
-rw-r--r-- | arch/x86/boot/compressed/sev.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/x86/boot/compressed/sev.c b/arch/x86/boot/compressed/sev.c index dc8c876fbd8f..afd91041ec3e 100644 --- a/arch/x86/boot/compressed/sev.c +++ b/arch/x86/boot/compressed/sev.c @@ -103,6 +103,11 @@ static enum es_result vc_read_mem(struct es_em_ctxt *ctxt, return ES_OK; } +static enum es_result vc_ioio_check(struct es_em_ctxt *ctxt, u16 port, size_t size) +{ + return ES_OK; +} + #undef __init #define __init |