arch/x86/include/cpu: introduce CPU_TABLE_END CPU table terminator

Instead of having a magic entry in the CPU device ID table list to tell
find_cpu_driver that it has reached the end of the list, introduce and
use CPU_TABLE_END. Since the vendor entry in the CPU device ID struct is
compared against X86_VENDOR_INVALID which is 0, use X86_VENDOR_INVALID
instead of the 0 in the CPU_TABLE_END definition.

TEST=Timeless build for Mandolin results in identical image.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Suggested-by: Angel Pons <th3fanbus@gmail.com>
Change-Id: I0cae6d65b2265cf5ebf90fe1a9d885d0c489eb92
Reviewed-on: https://review.coreboot.org/c/coreboot/+/72888
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Fred Reitberger <reitbergerfred@gmail.com>
This commit is contained in:
Felix Held
2023-02-08 11:39:16 +01:00
parent 24f3dc8a17
commit 1e78165cdc
31 changed files with 32 additions and 32 deletions

View File

@ -13,7 +13,7 @@ static struct device_operations cpu_dev_ops = {
static const struct cpu_device_id cpu_table[] = {
{ X86_VENDOR_ANY, 0, 0 },
{ 0, 0, 0 },
CPU_TABLE_END
};
static const struct cpu_driver driver __cpu_driver = {