svn commit: r317191 - head/sys/dev/ofw
Olivier Houchard
cognet at FreeBSD.org
Thu Apr 20 13:56:08 UTC 2017
Author: cognet
Date: Thu Apr 20 13:56:06 2017
New Revision: 317191
URL: https://svnweb.freebsd.org/changeset/base/317191
Log:
ePAPR states that any non-boot CPU will come in "disabled" state. So we should
not consider a "disabled" cpu as a CPU we have to ignore, and we should use
them if they provide a "enable-method".
While I'm there, support "ok" as well as "okay", while ePAPR only accepts
"okay", linux accepts "ok" too so we can expect it to be used.
Reviewed by: andrew (partially)
Modified:
head/sys/dev/ofw/ofw_cpu.c
Modified: head/sys/dev/ofw/ofw_cpu.c
==============================================================================
--- head/sys/dev/ofw/ofw_cpu.c Thu Apr 20 13:46:55 2017 (r317190)
+++ head/sys/dev/ofw/ofw_cpu.c Thu Apr 20 13:56:06 2017 (r317191)
@@ -320,8 +320,10 @@ ofw_cpu_early_foreach(ofw_cpu_foreach_cb
if (only_runnable) {
status[0] = '\0';
OF_getprop(child, "status", status, sizeof(status));
- if (status[0] != '\0' && strcmp(status, "okay") != 0)
- continue;
+ if (status[0] != '\0' && strcmp(status, "okay") != 0 &&
+ strcmp(status, "ok") != 0 &&
+ !OF_hasprop(child, "enable-method"))
+ continue;
}
/*
More information about the svn-src-all
mailing list