Date: Wed, 23 Oct 2013 14:28:59 +0000 (UTC) From: Nathan Whitehorn <nwhitehorn@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r256973 - head/sys/powerpc/booke Message-ID: <201310231428.r9NESxii006946@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: nwhitehorn Date: Wed Oct 23 14:28:59 2013 New Revision: 256973 URL: http://svnweb.freebsd.org/changeset/base/256973 Log: If the device tree directly contains the timebase frequency, use it. This property is required by ePAPR, but maintain the fallback to bus-frequency for compatibility. MFC after: 2 weeks Modified: head/sys/powerpc/booke/platform_bare.c Modified: head/sys/powerpc/booke/platform_bare.c ============================================================================== --- head/sys/powerpc/booke/platform_bare.c Wed Oct 23 14:28:42 2013 (r256972) +++ head/sys/powerpc/booke/platform_bare.c Wed Oct 23 14:28:59 2013 (r256973) @@ -188,6 +188,10 @@ bare_timebase_freq(platform_t plat, stru if ((child = OF_child(cpus)) == 0) goto out; + if (OF_getprop(child, "timebase-frequency", (void *)&ticks, + sizeof(ticks)) == sizeof(ticks)) + goto out; + freq = 0; if (OF_getprop(child, "bus-frequency", (void *)&freq, sizeof(freq)) <= 0)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201310231428.r9NESxii006946>