D15247: add rcorder(8) support to /etc/rc.resume

From: Eugene Grosbein <eugen_at_grosbein.net>
Date: Thu, 3 May 2018 23:03:07 +0700
Hi!

While dealing with https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=227866
I've found we have no easy way to insert custom "hooks" after
ACPI resume procedure other than devd(8).
And running devd itself may be undesirable for several reasons.

Manual editing of /etc/rc.resume is not desirable too
because it makes upgrades less smooth.

So, I'd like to add rcorder(8) support to /etc/rc.resume: https://reviews.freebsd.org/D15247
/etc/rc.resume will call "rcorder -k resume" and run rcNG scripts
containing "KEYWORD: resume" with single "resume" argument.

Working example is the port sysutils/cpupdate version g20180324_1
that defines extra_commands="resume" to reload CPU microcode cleared by suspend/resume sequence.

This change does nothing if system has no rcNG scripts with "KEYWORD: resume" inside.

I'm going to commit this in a week unless told not to for a reason.


Received on Thu May 03 2018 - 14:03:35 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:41:15 UTC