soc/intel/skl,cpu/intel: copy AES-NI locking to common cpu code

Copy the AES-NI locking function to common cpu code to be able to reuse
it.

This change only copies the code and adds the MSR header file. Any
further rework and later deduplication on the platforms code is done in
the follow-up changes.

Change-Id: I81ad5c0d4797b139435c57d3af0a95db94a5c15e
Signed-off-by: Michael Niewöhner <foss@mniewoehner.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46272
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
This commit is contained in:
Michael Niewöhner
2020-10-11 13:00:27 +02:00
committed by Nico Huber
parent e92c84050b
commit 8b4a9380b5
3 changed files with 37 additions and 0 deletions

View File

@ -0,0 +1,11 @@
#ifndef CPU_INTEL_MSR_H
#define CPU_INTEL_MSR_H
/*
* Common MSRs for Intel CPUs
*/
#define MSR_FEATURE_CONFIG 0x13c
#define AESNI_LOCK_BIT 0
#endif /* CPU_INTEL_MSR_H */