soc/intel/apl: Rework on CPU privilege level implementation
commit05865b8fbdef5df6cda4183eb66df5ef817cfe67
authorSubrata Banik <subratabanik@google.com>
Fri, 7 Jan 2022 13:01:18 +0000 (7 13:01 +0000)
committerSubrata Banik <subratabanik@google.com>
Tue, 11 Jan 2022 07:17:43 +0000 (11 07:17 +0000)
tree3ed9d8786f2ceaa115b56e898035d4e64fbdeb70
parent17c9cfe2125736e49d335efcc624b53d213444ef
soc/intel/apl: Rework on CPU privilege level implementation

This patch migrates common code API into SoC specific implementation
to drop CPU privilege level as the MSR is not consistent across
platforms.

For example: On APL/GLK, it's MSR 0x120 and CNL onwards it's MSR 0x151.

Also, include `soc/msr.h` in cpu.h to fix the compilation issue.

Signed-off-by: Subrata Banik <subratabanik@google.com>
Change-Id: I0b6f39509cc5457089cc15f28956833c36b567ad
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60898
Reviewed-by: EricR Lai <ericr_lai@compal.corp-partner.google.com>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
src/soc/intel/apollolake/chip.c
src/soc/intel/apollolake/include/soc/cpu.h
src/soc/intel/apollolake/include/soc/msr.h
src/soc/intel/common/block/cpu/cpulib.c
src/soc/intel/common/block/include/intelblocks/cpulib.h
src/soc/intel/common/block/include/intelblocks/msr.h