NetBSD/sys
xtraeme 1b3709ecde Add a new sensor type to sysmon_envsys(9): ENVSYS_GSTRING.
ENVSYS_GSTRING (aka Generic String) uses the genstr member in
the envsys_data_t struct to add a generic string that envstat(8)
will show as value or state.

It's like the ENVSYS_DRIVER, but doesn't use value_cur. Below
is the dictionary created on these sensors:

<dict>
	<key>description</key>
	<string>acpibat0 charge state</string>
	<key>generic-state-string</key>
	<string>NORMAL</string>
	<key>monitoring-supported</key>
	<false/>
	<key>state</key>
	<string>valid</string>
	<key>type</key>
	<string>Generic string</string>
</dict>

Note that it's limited to 32 chars, but we can grow it if needed.

envstat(8) will print ENVSYS_GSTRING sensors as:

$ envstat -dacpibat0 -s"acpibat0 charge state"
  acpibat0 charge state:     NORMAL
$
2007-09-02 19:36:59 +00:00
..
altq Merge some of the less invasive changes from the vmlocking branch: 2007-07-09 20:51:58 +00:00
arch look for an ATY,RefCLK property and pass it to the console device if found. 2007-09-02 18:45:36 +00:00
coda * nuke the nameidata parameter from VFS_MOUNT(). Nobody on tech-kern 2007-07-31 21:14:15 +00:00
compat Constify: LLADDR() -> CLLADDR(). 2007-08-29 22:33:42 +00:00
conf subr_prf_bitmask.c -> subr_prf2.c 2007-08-15 20:34:48 +00:00
contrib/dev/ath Make ath(4) work again on sparc64 (and other big-endian machines). 2007-08-28 00:12:46 +00:00
crypto Added missing const-qualifiers. 2007-01-22 01:38:33 +00:00
ddb include cdefs.h before opt_xxx.h 2007-07-19 21:54:51 +00:00
dev Add a new sensor type to sysmon_envsys(9): ENVSYS_GSTRING. 2007-09-02 19:36:59 +00:00
dist reduce diff. 2007-08-07 10:02:40 +00:00
fs Add a third type of fh option, passthrough, where the kernel does 2007-08-23 14:36:46 +00:00
gdbscripts adapt to mnt_vnodelist being TAILQ 2006-11-04 20:33:17 +00:00
ipkdb Remove more duplicate headers. 2007-01-29 01:52:43 +00:00
kern Convert the sysmon watchdog framework to use mutex(9) rather than 2007-09-02 00:41:24 +00:00
lib Do the panicstr check only if _KERNEL. 2007-08-03 13:06:00 +00:00
lkm Update to catch some problems that I just fixed in the framework. The 2007-07-22 18:24:48 +00:00
miscfs Make bioops a pointer and point it to the softdeps struct in softdep 2007-09-01 23:40:21 +00:00
net Delete unused variable. 2007-09-02 07:03:22 +00:00
net80211 Add a sockaddr_storage member to "struct ifreq" maintaining backwards 2007-05-29 21:32:27 +00:00
netatalk Use ifreq_setaddr(), ifreq_getaddr(), sockaddr_in_init(), and 2007-09-01 04:32:50 +00:00
netbt not necessary to cast to (void *) (from caddr_t removal) 2007-07-19 20:48:51 +00:00
netinet m_copym(..., 0, M_COPYALL, ...) -> m_copypacket(..., ...). 2007-09-02 07:18:55 +00:00
netinet6 Use sockaddr_in6_init(). 2007-08-31 21:40:41 +00:00
netipsec Merge some of the less invasive changes from the vmlocking branch: 2007-07-09 20:51:58 +00:00
netisdn Merge some of the less invasive changes from the vmlocking branch: 2007-07-09 20:51:58 +00:00
netiso Use malloc(9) for sockaddrs instead of pool(9), and remove dom_sa_pool 2007-08-30 02:17:34 +00:00
netkey Merge some of the less invasive changes from the vmlocking branch: 2007-07-09 20:51:58 +00:00
netnatm Eliminate address family-specific route caches (struct route, struct 2007-05-02 20:40:22 +00:00
netsmb Don't exit an unheld mutex. 2007-07-10 21:05:03 +00:00
nfs Use sockaddr_in_init() and ifreq_setaddr() to initialize a sockaddr_in 2007-08-31 22:02:58 +00:00
opencrypto Merge some of the less invasive changes from the vmlocking branch: 2007-07-09 20:51:58 +00:00
rump "proper" return value handling 2007-09-02 13:55:27 +00:00
secmodel Merge some of the less invasive changes from the vmlocking branch: 2007-07-09 20:51:58 +00:00
stand
sys Add a new sensor type to sysmon_envsys(9): ENVSYS_GSTRING. 2007-09-02 19:36:59 +00:00
ufs Make bioops a pointer and point it to the softdeps struct in softdep 2007-09-01 23:40:21 +00:00
uvm Make bioops a pointer and point it to the softdeps struct in softdep 2007-09-01 23:40:21 +00:00
Makefile don't descend to crypto. 2006-10-29 19:08:53 +00:00