From e42cd379ded4f31487b863d84db11c8c24e22a76 Mon Sep 17 00:00:00 2001 From: Randall Spangler Date: Thu, 9 Feb 2012 11:00:11 -0800 Subject: Print repeated port 80 writes, for coreboot/uboot debugging Signed-off-by: Randall Spangler BUG=chrome-os-partner:7972 TEST=boot main processor; look for repeated sequential port 80 writes Change-Id: I07b247130945296ce73177a342e0b2cf5645f4fb --- common/port80.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'common/port80.c') diff --git a/common/port80.c b/common/port80.c index 6349975b75..114f1cf520 100644 --- a/common/port80.c +++ b/common/port80.c @@ -5,6 +5,7 @@ /* Port 80 module for Chrome EC */ +#include "board.h" #include "console.h" #include "port80.h" #include "uart.h" @@ -20,10 +21,12 @@ static int last_data = -1; /* Last data written to port 80 */ void port_80_write(int data) { +#ifndef CONFIG_PORT80_PRINT_DUPLICATES /* Ignore duplicate writes, since the linux kernel writes to port 80 * as a delay mechanism during boot. */ if (data == last_data) return; +#endif /* TODO: post to SWI and print from there? This currently * prints from inside the LPC interrupt itself. */ -- cgit v1.2.1