summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorDavid Gwynne <dlg@cvs.openbsd.org>2021-01-19 21:53:00 +0000
committerDavid Gwynne <dlg@cvs.openbsd.org>2021-01-19 21:53:00 +0000
commit5429a3d616d59ecd403f9173a39015f21cc20d43 (patch)
treec3207330efead5f7fa4ff7b3a2ca798e67eef4d7 /sys
parent4262d0531a70ba12b5409aa3977914577a832b41 (diff)
blacklist com on m3000s. our com code causes faults somehow.
console i/o still happens using ofw routines, which is Good Enough(tm) for now. having a working machine means i can better test changes now though. ok deraadt@
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/sparc64/dev/com_ebus.c21
1 files changed, 20 insertions, 1 deletions
diff --git a/sys/arch/sparc64/dev/com_ebus.c b/sys/arch/sparc64/dev/com_ebus.c
index 4a0e1eb7908..ed5585c45e2 100644
--- a/sys/arch/sparc64/dev/com_ebus.c
+++ b/sys/arch/sparc64/dev/com_ebus.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: com_ebus.c,v 1.23 2019/12/05 12:46:54 mpi Exp $ */
+/* $OpenBSD: com_ebus.c,v 1.24 2021/01/19 21:52:59 dlg Exp $ */
/* $NetBSD: com_ebus.c,v 1.6 2001/07/24 19:27:10 eeh Exp $ */
/*
@@ -65,6 +65,21 @@ static char *com_names[] = {
NULL
};
+static inline int
+com_match_ikkaku(void)
+{
+ char model[80];
+ int i;
+
+ i = OF_getproplen(findroot(), "model");
+ if (i == 0)
+ return (0);
+ if (OF_getprop(findroot(), "model", model, sizeof(model)) != i)
+ return (0);
+
+ return (strcmp(model, "IKKAKU") == 0);
+}
+
int
com_ebus_match(struct device *parent, void *match, void *aux)
{
@@ -78,6 +93,10 @@ com_ebus_match(struct device *parent, void *match, void *aux)
if (strcmp(ea->ea_name, "serial") == 0) {
char compat[80];
+ /* blacklist com on m3000s because it causes hardware faults */
+ if (com_match_ikkaku())
+ return (0);
+
/* Could be anything. */
if ((i = OF_getproplen(ea->ea_node, "compatible")) &&
OF_getprop(ea->ea_node, "compatible", compat,