Skip to content
Commit a8f7e08a authored by Peter Gonda's avatar Peter Gonda Committed by Borislav Petkov
Browse files

x86/sev-es: Fix SEV-ES OUT/IN immediate opcode vc handling

The IN and OUT instructions with port address as an immediate operand
only use an 8-bit immediate (imm8). The current VC handler uses the
entire 32-bit immediate value but these instructions only set the first
bytes.

Cast the operand to an u8 for that.

 [ bp: Massage commit message. ]

Fixes: 25189d08

 ("x86/sev-es: Add support for handling IOIO exceptions")
Signed-off-by: default avatarPeter Gonda <pgonda@google.com>
Signed-off-by: default avatarBorislav Petkov <bp@suse.de>
Acked-by: default avatarDavid Rientjes <rientjes@google.com>
Link: https://lkml.kernel.org/r/20210105163311.221490-1-pgonda@google.com
parent d1c5246e
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment