HomeFreeBSD

MFC r352196, r352333, r352342, r353653

Description

MFC r352196, r352333, r352342, r353653

r352196:
In am335x_dmtpps, use a spin mutex to interlock between PPS capture and PPS
ioctl(2) handling. This allows doing the pps_event() work in the polling
routine, instead of using a taskqueue task to do that work.

Also, add PNPINFO, and switch to using make_dev_s() to create the cdev.

Using a spin mutex and calling pps_event() from the polling function works
around the situation which requires more than 2 sets of timecounter
timehands in a single-core system to get reliable PPS capture. That problem
would happen when a single-core system is idle in cpu_idle() then gets woken
up with an event timer event which was scheduled to handle a hardclock tick.
That processing path would end up calling tc_windup 3 or 4 times between
when the tc polling function was called and when the taskqueue task would
eventually run, and with only two sets of timehands, the th_generation count
would always be too old to allow the captured PPS data to be used.

r352333:
Include <lock.h>, required to use spinlocks in this code.

r352342:
Make the ti_sysc device quiet. It's an internal utility pseudo-device
that makes the upstream FDT data work right, so we don't need to see a
couple dozen instances of it spam the dmesg at boot time unless it's a
verbose boot.

r353653:
Update some comments; no functional changes. Some historical old comments
in this driver indicate that the SD_CAPA register is write-once and after
being set one time the values in it cannot be changed. That turns out not
to be the case -- the values written to it survive a reset, but they can
be rewritten/changed at any time.

Details

Provenance
ianAuthored on
Parents
rS355491: Remove the next and prev fields from vm_map_entry, to save a bit of
Branches
Unknown
Tags
Unknown