make SW_WATCHDOG dynamicEnable the hardclock-based watchdog previously conditional on theSW_WATCHDOG option whenever hardware watchdogs are not found, andwatchdogd attempts to enable the watchdog
make SW_WATCHDOG dynamicEnable the hardclock-based watchdog previously conditional on theSW_WATCHDOG option whenever hardware watchdogs are not found, andwatchdogd attempts to enable the watchdog. The SW_WATCHDOG optionstill causes the sofware watchdog to be enabled even if there is ahardware watchdog. This does not change the other software-basedwatchdog enabled by the --softtimeout option to watchdogd.Note that the code to reprime the watchdog during kernel core dumps isno longer conditional on SW_WATCHDOG. I think this was previously a bug.Reviewed by: imp alfred bjkMFC after: 1 weekRelnotes: yesDifferential Revision: https://reviews.freebsd.org/D13713
show more ...
sys/dev: further adoption of SPDX licensing ID tags.Mainly focus on files that use BSD 2-Clause license, however the tool Iwas using misidentified many licenses so this was mostly a manual - error
sys/dev: further adoption of SPDX licensing ID tags.Mainly focus on files that use BSD 2-Clause license, however the tool Iwas using misidentified many licenses so this was mostly a manual - errorprone - task.The Software Package Data Exchange (SPDX) group provides a specificationto make it easier for automated tools to detect and summarize well knownopensource licenses. We are gradually adopting the specification, notingthat the tags are considered only advisory and do not, in any way,superceed or replace the license texts.
Some cosmetic polishing for pre-timeouts.MFC after: 1 week
CALLOUT_MPSAFE has lost its meaning since r141428, i.e., for more than tenyears for head. However, it is continuously misused as the mpsafe argumentfor callout_init(9). Deprecate the flag and cle
CALLOUT_MPSAFE has lost its meaning since r141428, i.e., for more than tenyears for head. However, it is continuously misused as the mpsafe argumentfor callout_init(9). Deprecate the flag and clean up callout_init() callsto make them more consistent.Differential Revision: https://reviews.freebsd.org/D2613Reviewed by: jhbMFC after: 2 weeks
Add a missing include of an options header.watchdog.c does an #ifdef DDB but does not #include "opt_ddb.h".Fixing this turned up a missing include file.MFC after: 1 weekX-MFC-With: r261495, r27
Add a missing include of an options header.watchdog.c does an #ifdef DDB but does not #include "opt_ddb.h".Fixing this turned up a missing include file.MFC after: 1 weekX-MFC-With: r261495, r279410
Use right buffer to print to.PR: kern/176597Submitted by: Christoph Mallon <christoph mallon gmx de>MFC after: 2 weeks
Fix watchdog pretimeout.The original API calls for pow2ns, however the new APIs fromLinux call for seconds.We need to be able to convert to/from 2^Nns to seconds in bothuserland and kernel to f
Fix watchdog pretimeout.The original API calls for pow2ns, however the new APIs fromLinux call for seconds.We need to be able to convert to/from 2^Nns to seconds in bothuserland and kernel to fix this and properly compare units.
watchdogd(8) and watchdog(4) enhancements.The following support was added to watchdog(4):- Support to query the outstanding timeout.- Support to set a software pre-timeout function watchdog with
watchdogd(8) and watchdog(4) enhancements.The following support was added to watchdog(4):- Support to query the outstanding timeout.- Support to set a software pre-timeout function watchdog with an 'action'- Support to set a software only watchdog with a configurable 'action''action' can be a mask specifying a single operation or a combination of: log(9), printf(9), panic(9) and/or kdb_enter(9).Support the following in watchdogged:- Support to utilize the new additions to watchdog(4).- Support to warn if a watchdog script runs for too long.- Support for "dry run" where we do not actually arm the watchdog, but only report on our timing.Sponsored by: iXsystems, Inc.MFC after: 1 month
- Add the possibility to reuse the already last used timeout when patting the watchdog, via the watchdog(9) interface. For that, the WD_LASTVAL bitwise operation is used. It is mutually exclusi
- Add the possibility to reuse the already last used timeout when patting the watchdog, via the watchdog(9) interface. For that, the WD_LASTVAL bitwise operation is used. It is mutually exclusive with any explicit timout passing to the watchdogs. The last timeout can be returned via the wdog_kern_last_timeout() KPI.- Add the possibility to pat the watchdogs installed via the watchdog(9) interface from the kernel. In order to do that the new KPI wdog_kern_pat() is offered and it does accept normalized nanoseconds or WD_LASTVAL.- Avoid to pass WD_ACTIVE down in the watchdog handlers. All the control bit processing should over to the upper layer functions and not passed down to the handlers at all.These changes are intended to be used in order to fix up the watchdogtripping in situation when the userland is busted, but protection is stillwanted (examples: shutdown syncing / disk dumping).Sponsored by: Sandvine IncorporatedReviewed by: emaste, des, cognetMFC after: 2 weeks
Revisit the watchdogs: Resetting the error to EINVAL after failing to set thewatchdog might hide the succesful arming of an earlier one. Accept that onfailing to arm any watchdog (because of non-su
Revisit the watchdogs: Resetting the error to EINVAL after failing to set thewatchdog might hide the succesful arming of an earlier one. Accept that onfailing to arm any watchdog (because of non-supported timeouts) EOPNOTSUPP isreturned instead of the more appropriate EINVAL.MFC after: 3 days
Align the interfaces for the various watchdogs and make the interfacebehave as expected.Also:- Return an error if WD_PASSIVE is passed in to the ioctl as only WD_ACTIVE is implemented at the mo
Align the interfaces for the various watchdogs and make the interfacebehave as expected.Also:- Return an error if WD_PASSIVE is passed in to the ioctl as only WD_ACTIVE is implemented at the moment. See sys/watchdog.h for an explanation of the difference between WD_ACTIVE and WD_PASSIVE.- Remove the I_HAVE_TOTALLY_LOST_MY_SENSE_OF_HUMOR define. If you've lost your sense of humor, than don't add a define.Specific changes:i80321_wdog.c Don't roll your own passive watchdog tickle as this would defeat the purpose of an active (userland) watchdog tickle.ichwd.c / ipmi.c: WD_ACTIVE means active patting of the watchdog by a userland process, not whether the watchdog is active. See sys/watchdog.h.kern_clock.c: (software watchdog) Remove a check for WD_ACTIVE as this does not make sense here. This reverts r1.181.
Return zero when disabling watchdog, unless any of the drivers complain.
Do the dreaded s/dev_t/struct cdev */Bump __FreeBSD_version accordingly.
Add a generic watchdog facility which through a single device entryin /dev controls all available watchdog implementations.