summaryrefslogtreecommitdiff
path: root/src/mainboard/google
diff options
context:
space:
mode:
authorRex-BC Chen <rex-bc.chen@mediatek.com>2021-06-03 11:41:07 +0800
committerHung-Te Lin <hungte@chromium.org>2021-06-05 13:04:43 +0000
commit9e3e0f560b3c6c3714473685d3b3866baf4f400d (patch)
tree52f498aeb389331b25c37b2deb163d9b01ff82ec /src/mainboard/google
parentfb1858539f7451317730fda785600c81ec44dfd2 (diff)
mb/google/cherry: Initialize SPM
This patch adds support for SPM. This adds 43ms to the boot time. TEST=program counter of SPM is correct value after booting up. Signed-off-by: Dawei Chien <dawei.chien@mediatek.com> Signed-off-by: Edward-JW Yang <edward-jw.yang@mediatek.corp-partner.google.com> Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com> Change-Id: I5f17f6d51fc9ad2d23c71c3c5cd29fdc777dc071 Reviewed-on: https://review.coreboot.org/c/coreboot/+/55154 Reviewed-by: Yu-Ping Wu <yupingso@google.com> Reviewed-by: Rex-BC Chen <rex-bc.chen@mediatek.corp-partner.google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/mainboard/google')
-rw-r--r--src/mainboard/google/cherry/mainboard.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mainboard/google/cherry/mainboard.c b/src/mainboard/google/cherry/mainboard.c
index 2607a2dfb4..04f4293308 100644
--- a/src/mainboard/google/cherry/mainboard.c
+++ b/src/mainboard/google/cherry/mainboard.c
@@ -11,6 +11,7 @@
#include <soc/i2c.h>
#include <soc/mt6360.h>
#include <soc/regulator.h>
+#include <soc/spm.h>
#include <soc/usb.h>
#include "gpio.h"
@@ -124,6 +125,9 @@ static void mainboard_init(struct device *dev)
configure_sdcard();
setup_usb_host();
+ if (spm_init())
+ printk(BIOS_ERR, "spm init failed, system suspend may not work\n");
+
register_reset_to_bl31();
}