summaryrefslogtreecommitdiff
path: root/util/comm-lpc.c
diff options
context:
space:
mode:
authorMike Frysinger <vapier@chromium.org>2015-04-16 01:31:20 -0400
committerChromeOS Commit Bot <chromeos-commit-bot@chromium.org>2015-04-17 01:47:34 +0000
commitf55a7e5774447dd1dcdb03ce4cc2d62f613b0eda (patch)
tree56fcbd4ed0f4700a79804c43c623f7daae118cad /util/comm-lpc.c
parenta5b3bb0f979e7734c409d34fb3dc350d287d139d (diff)
downloadchrome-ec-f55a7e5774447dd1dcdb03ce4cc2d62f613b0eda.tar.gz
clean up x86 i/o checks
Rather than hardcode a specific mips toolchain, do a build-time test to see if the target is x86 based. BUG=chromium:443783 TEST=link still includes comm-lpc TEST=arm64 omits comm-lpc BRANCH=none Change-Id: I0253df6cbe89bee231ec643dd6bb3498eb040708 Reviewed-on: https://chromium-review.googlesource.com/265793 Reviewed-by: Gwendal Grignou <gwendal@chromium.org> Commit-Queue: Mike Frysinger <vapier@chromium.org> Tested-by: Mike Frysinger <vapier@chromium.org>
Diffstat (limited to 'util/comm-lpc.c')
-rw-r--r--util/comm-lpc.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/util/comm-lpc.c b/util/comm-lpc.c
index e7c5a25b55..54f16b3ffc 100644
--- a/util/comm-lpc.c
+++ b/util/comm-lpc.c
@@ -3,6 +3,9 @@
* found in the LICENSE file.
*/
+/* The I/O asm funcs exist only on x86. */
+#if defined(__i386__) || defined(__x86_64__)
+
#include <stdint.h>
#include <stdio.h>
#include <sys/io.h>
@@ -309,3 +312,5 @@ int comm_init_lpc(void)
ec_readmem = ec_readmem_lpc;
return 0;
}
+
+#endif