freebsd-dev/sys
Ian Lepore 86a5575402 Add basic cpu frequency control and temperature monitoring to imx6_anatop.
The temperature monitor device is enabled to sample the die temperature at
16hz.  The temperature is published via sysctl.  A callout routine at 10hz
monitors the temperature and throttles back the cpu if the temperature
goes over a user-settable throttle point (by default 10C less than the
critical high-point temperature for the chip).  The hardware is supposed
to be able to deliver an interrupt when the temperature exceeds a settable
limit, but the interrupt never arrives so for now a callout does the job.

At attach time we read the maximum cpu frequency the chip is allowed to run
at and the cpu is set to run at that speed.  It's reported at attach time.
A sysctl variable reports the current speed when queried.

New sysctl values:

  dev.imx6_anatop.0.cpu_mhz: 984
  dev.imx6_anatop.0.temperature: 37.9C
  dev.imx6_anatop.0.throttle_temperature: 95.0C

Steven Lawrance did the initial heavy lifting on this, but I changed
enough stuff that I'm the one to blame if anything breaks.

Submitted by:	Steven Lawrance <stl@koffein.net>
2014-02-21 06:00:06 +00:00
..
amd64 Simplify APIC mode switching from MMIO to x2APIC. In part this is done to 2014-02-20 01:48:25 +00:00
arm Add basic cpu frequency control and temperature monitoring to imx6_anatop. 2014-02-21 06:00:06 +00:00
boot Add basic cpu frequency control and temperature monitoring to imx6_anatop. 2014-02-21 06:00:06 +00:00
bsm Change the cap_rights_t type from uint64_t to a structure that we can extend 2013-09-05 00:09:56 +00:00
cam Make CTL block backend return proper error code for operations unsupposed 2014-02-06 03:54:58 +00:00
cddl MFV r261619: 2014-02-08 05:35:36 +00:00
compat The posix_madvise(3) and posix_fadvise(2) should return error on 2014-01-30 18:04:39 +00:00
conf o Remove at compile time the HASH_ALL code, that was never 2014-02-17 11:50:56 +00:00
contrib Retire the nve(4) driver; nfe(4) has been the default driver for NVIDIA 2014-02-16 12:22:43 +00:00
crypto fix broken style(9) in r258399 2013-11-23 00:28:18 +00:00
ddb
dev compile with NOINET 2014-02-20 04:56:55 +00:00
fs In sys/fs/nandfs/nandfs_vfsops.c, #if 0 an unused static function. 2014-02-15 11:42:56 +00:00
gdb
geom In g_eli_crypto_hmac_init(), zero out after using the ipad buffer, 2014-02-08 05:17:49 +00:00
gnu/fs/reiserfs
i386 After r261980, the local ptr variable in xbox_init() is no longer used, 2014-02-16 22:48:36 +00:00
ia64 In pmap_set_pte(), make sure to enforce ordering by inserting a memory 2014-01-20 18:37:35 +00:00
isa
kern Fix M_FILEDESC leak in fdgrowtable() introduced in r244510. 2014-02-17 00:00:39 +00:00
kgssapi
libkern Fix typo 2013-11-29 20:14:26 +00:00
mips Update MIPS bootinfo.h to reflect the actual MIPS boot2/loader boot-time 2014-02-19 09:19:09 +00:00
modules Retire the nve(4) driver; nfe(4) has been the default driver for NVIDIA 2014-02-16 12:22:43 +00:00
net V_irtualize rtsock refcounting, which reduces the chances for panics 2014-02-19 08:29:07 +00:00
net80211 Another round of removing historical mbuf(9) allocator flags. 2014-01-16 13:44:47 +00:00
netatalk The r48589 promised to remove implicit inclusion of if_var.h soon. Prepare 2013-10-26 17:58:36 +00:00
netgraph Be much more specific (and correct) about the device id matching. 2014-01-09 15:31:44 +00:00
netinet Remove redundant code and fix a style error. 2014-02-20 20:14:43 +00:00
netinet6 o Remove at compile time the HASH_ALL code, that was never 2014-02-17 11:50:56 +00:00
netipsec Initialize prot variable. 2013-11-11 13:19:55 +00:00
netipx The r48589 promised to remove implicit inclusion of if_var.h soon. Prepare 2013-10-26 17:58:36 +00:00
netnatm Provide includes that are needed in these files, and before were read 2013-10-26 18:18:50 +00:00
netpfil Revert r262196 2014-02-19 17:06:04 +00:00
netsmb Catch up with sb_timeo type change in r255138. This fixes 2013-11-08 08:44:09 +00:00
nfs Move most of NFS file handle affinity code out of the heavily congested 2013-12-30 20:23:15 +00:00
nfsclient For software builds, the NFS client does many small 2013-12-07 23:05:59 +00:00
nfsserver Fix RPC server threads file handle affinity to work better with ZFS. 2013-12-23 08:43:16 +00:00
nlm Intermittent crashes in the NLM (rpc.lockd) code during system 2013-09-06 23:14:31 +00:00
ofed Simplify filling sockaddr_dl structure for if_resolvemulti() 2014-01-18 23:24:51 +00:00
opencrypto Prevent races in accesses of the software crypto session array. 2014-01-28 22:02:29 +00:00
pc98 Don't waste a page of KVA for the boot-time memory test on x86. For amd64, 2014-02-11 22:02:40 +00:00
pci - Implement the RX EARLYOFF and RXDV GATED bits as done by RealTek's Linux 2014-02-05 23:13:40 +00:00
powerpc Correct the order of arguments to mtx_init(). 2014-02-14 11:18:15 +00:00
rpc Fix lock acquisition in case no request space available, missed in r260097. 2014-02-04 00:00:01 +00:00
security As constantly reported during kernel compilation, m_buflen is unsigned so 2013-12-25 20:10:17 +00:00
sparc64 Add support for managing PCI bus numbers. As with BARs and PCI-PCI bridge 2014-02-12 04:30:37 +00:00
sys Add more __BEGIN_DECLS / __END_DECLS to <sys/capability.h>. 2014-02-18 14:54:56 +00:00
teken Fix typo. 2014-02-06 13:28:06 +00:00
tools dtrace sdt: remove the ugly sname parameter of SDT_PROBE_DEFINE 2013-11-26 08:46:27 +00:00
ufs Fine tune filesystem block allocations under low free-space 2013-12-30 17:04:24 +00:00
vm After r251709, avoid a clang 3.4 warning about an unused static const 2014-02-14 17:47:18 +00:00
x86 Add support for managing PCI bus numbers. As with BARs and PCI-PCI bridge 2014-02-12 04:30:37 +00:00
xdr
xen Remove redundant redeclaration of gdtset in sys/xen/xen-os.h, to silence 2013-10-18 17:06:13 +00:00
Makefile Add netpfil to CSCOPEDIRS. 2013-12-30 08:36:17 +00:00