soc/apollolake: Generate DMAR table

Generate DMAR table if VTd feature is enabled.

Test=Booted into Linux on mc_apl2 and verified the DMAR table contents.
In addition turned off Vtd and verified that no DMAR table is generated
at all.

Change-Id: Ie3683a2f3578c141c691b2268e32f27ba2e772fa
Signed-off-by: Werner Zeh <werner.zeh@siemens.com>
Reviewed-on: https://review.coreboot.org/c/30990
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
This commit is contained in:
Werner Zeh 2018-12-14 13:26:04 +01:00 committed by Patrick Georgi
commit 90cc7e24b0
4 changed files with 100 additions and 3 deletions

View file

@ -2,6 +2,7 @@
* This file is part of the coreboot project.
*
* Copyright (C) 2017-2018 Intel Corporation.
* Copyright (C) 2019 Siemens AG
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@ -19,8 +20,10 @@
#include <stddef.h>
#include <stdint.h>
#define PCH_P2SB_E0 0xe0
#define P2SB_E0_MASKLOCK (1 << 1)
#define PCH_P2SB_E0 0xe0
#define P2SB_E0_MASKLOCK (1 << 1)
#define PCH_P2SB_IBDF 0x6c
#define PCH_P2SB_HBDF 0x70
enum {
P2SB_EP_MASK_0_REG,

View file

@ -33,6 +33,7 @@
#define MCHBAR8(x) (*(volatile u8 *)(MCH_BASE_ADDRESS + x))
#define MCHBAR16(x) (*(volatile u16 *)(MCH_BASE_ADDRESS + x))
#define MCHBAR32(x) (*(volatile u32 *)(MCH_BASE_ADDRESS + x))
#define MCHBAR64(x) (*(volatile u64 *)(MCH_BASE_ADDRESS + x))
/* Perform System Agent Initialization during Bootblock phase */
void bootblock_systemagent_early_init(void);