freebsd-dev/sys/sparc64/include
Konstantin Belousov aea810386d Implement mechanism to export some kernel timekeeping data to
usermode, using shared page.  The structures and functions have vdso
prefix, to indicate the intended location of the code in some future.

The versioned per-algorithm data is exported in the format of struct
vdso_timehands, which mostly repeats the content of in-kernel struct
timehands. Usermode reading of the structure can be lockless.
Compatibility export for 32bit processes on 64bit host is also
provided. Kernel also provides usermode with indication about
currently used timecounter, so that libc can fall back to syscall if
configured timecounter is unknown to usermode code.

The shared data updates are initiated both from the tc_windup(), where
a fast task is queued to do the update, and from sysctl handlers which
change timecounter. A manual override switch
kern.timecounter.fast_gettime allows to turn off the mechanism.

Only x86 architectures export the real algorithm data, and there, only
for tsc timecounter. HPET counters page could be exported as well, but
I prefer to not further glue the kernel and libc ABI there until
proper vdso-based solution is developed.

Minimal stubs neccessary for non-x86 architectures to still compile
are provided.

Discussed with:	bde
Reviewed by:	jhb
Tested by:	flo
MFC after:	1 month
2012-06-22 07:06:40 +00:00
..
_align.h
_bus.h
_inttypes.h Sync licenses and the corresponding RCS IDs with NetBSD, mainly switching 2011-03-12 14:33:32 +00:00
_limits.h Fix types of some values in machine/_limits.h. 2011-01-08 11:13:34 +00:00
_stdint.h Sync licenses and the corresponding RCS IDs with NetBSD, mainly switching 2011-03-12 14:33:32 +00:00
_types.h Replace __signed by signed. 2011-12-13 13:38:03 +00:00
asi.h Add support for SPARC64 V (and where it already makes sense for other 2010-05-02 19:38:17 +00:00
asm.h Add macros for alternate entry points. 2010-09-15 21:11:29 +00:00
asmacros.h - Use atomic operations rather than sched_lock for safely assigning pm_active 2011-10-06 11:01:31 +00:00
atomic.h Revert r225889 a bit. While it's correct that in total store order there's 2011-12-03 13:51:57 +00:00
bus_common.h
bus_dma.h - Change contigmalloc() to use the vm_paddr_t type instead of an unsigned 2012-03-01 19:58:34 +00:00
bus_private.h Make sparc64 compatible with NEW_PCIB and enable it: 2011-10-02 23:22:38 +00:00
bus.h Make sparc64 compatible with NEW_PCIB and enable it: 2011-10-02 23:22:38 +00:00
cache.h - For Cheetah- and Zeus-class CPUs don't flush all unlocked entries from 2011-07-02 11:14:54 +00:00
ccr.h
clock.h Now that we have a working OF_printf() since r230631 and a OF_panic() 2012-01-27 23:21:54 +00:00
cmt.h
cpu.h Mark cpu_{halt,reset}() as __dead2 as appropriate. 2012-01-27 22:04:43 +00:00
cpufunc.h Correct spelling in comments. 2011-04-22 09:31:40 +00:00
db_machdep.h
dcr.h Correct the DCR_IPE macro to refer to the right bit. Also improve the 2010-04-10 11:13:51 +00:00
elf.h Reserve AT_TIMEKEEP auxv entry for providing usermode the pointer to 2012-06-22 06:38:31 +00:00
endian.h Add casts to __uint16_t to the __bswap16() macros on all arches which 2012-03-09 20:34:31 +00:00
exec.h
fireplane.h
float.h Add C11 macros describing subnormal numbers to float.h. 2012-01-23 06:36:41 +00:00
floatingpoint.h
fp.h
frame.h
fsr.h
gdb_machdep.h
idprom.h
ieee.h
ieeefp.h People porting FreeBSD to new architectures ought not have to 2011-10-21 06:41:46 +00:00
in_cksum.h MFp4 bz_ipv6_fast: 2012-05-24 22:00:48 +00:00
instr.h
intr_machdep.h Fix mismerge in r235231. 2012-05-10 15:23:20 +00:00
iommureg.h Fix typos - remove duplicate "the". 2011-02-21 09:01:34 +00:00
iommuvar.h Sync licenses and the corresponding RCS IDs with NetBSD, mainly switching 2011-03-12 14:33:32 +00:00
jbus.h
kdb.h
kerneldump.h
ktr.h Adapt CATR() to r222813. This is somewhat tricky as we can't afford using 2011-06-07 17:33:39 +00:00
limits.h
lsu.h Update for UltraSPARC-IV{,+} and SPARC64 V, VI, VII and VIIIfx CPUs. 2010-04-11 15:35:17 +00:00
mcntl.h Add support for SPARC64 V (and where it already makes sense for other 2010-05-02 19:38:17 +00:00
md_var.h For sparc64 also adjust the geometry of da(4) driven disks to not overflow 2011-11-27 15:43:40 +00:00
memdev.h Add reader/writer lock around mem_range_attr_get() and mem_range_attr_set(). 2011-01-17 22:58:28 +00:00
metadata.h
nexusvar.h
ofw_machdep.h - Now that we have a working OF_printf() since r230631, use it for 2012-01-27 22:35:53 +00:00
ofw_mem.h
ofw_nexus.h Sync licenses and the corresponding RCS IDs with NetBSD, mainly switching 2011-03-12 14:33:32 +00:00
param.h Merge from r224217: 2011-07-20 18:51:18 +00:00
pcb.h Add a convenience macro for the returns_twice attribute, and apply it to 2012-04-29 11:04:31 +00:00
pcpu.h Define curthread as an inline function that loads the thread pointer 2011-11-15 20:17:18 +00:00
pmap.h The page flag PGA_WRITEABLE is set and cleared exclusively by the pmap 2012-06-16 18:56:19 +00:00
pmc_mdep.h
proc.h Remove unused define. 2011-10-07 16:09:44 +00:00
profile.h
pstate.h
ptrace.h
reg.h
reloc.h
resource.h
runq.h
sc_machdep.h
setjmp.h
sf_buf.h
sigframe.h
signal.h
smp.h Don't include curcpu in the mask which is used as the IPI cookie as we 2011-06-15 22:41:55 +00:00
stack.h
stdarg.h
sysarch.h
tick.h - Wrap exchanging td_intr_frame and calling the event timer callback in 2010-10-19 19:44:05 +00:00
tlb.h - For Cheetah- and Zeus-class CPUs don't flush all unlocked entries from 2011-07-02 11:14:54 +00:00
trap.h
tsb.h On machines where we don't need to lock the kernel TSB into the dTLB and 2011-06-21 20:48:14 +00:00
tstate.h
tte.h - Add TTE and context register bits for the additional page sizes supported 2010-03-17 20:23:14 +00:00
ucontext.h
upa.h
utrap.h
varargs.h Remove the advertising clause from the UCB license according to the 2011-03-13 13:42:43 +00:00
vdso.h Implement mechanism to export some kernel timekeeping data to 2012-06-22 07:06:40 +00:00
ver.h Add macros for the VER.impl of SPARC64 II to VIIIfx. 2010-03-17 21:00:39 +00:00
vm.h
vmparam.h For machines where the kernel address space is unrestricted increase 2012-01-27 22:25:46 +00:00
watch.h
wstate.h - The firmware of Sun Fire V1280 has a misfeature of setting %wstate to 2010-03-21 13:09:54 +00:00