Date: Sun, 28 Jan 2024 12:28:23 -0400 From: Quincy Mcrae <qgmcrae@yahoo.com> To: Andriy Gapon <avg@freebsd.org> Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: 4d1161f094dd - main - subr_bus: report DEVICE_SUSPEND failures Message-ID: <AB8F544B-D69E-4D9F-861D-B8B59FA7C7ED@yahoo.com> In-Reply-To: <202401281321.40SDLneL052092@gitrepo.freebsd.org> References: <202401281321.40SDLneL052092@gitrepo.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Good afternoon, Could you please unsubscribe me from the group? Quincy Sent from my iPhone > On Jan 28, 2024, at 9:21=E2=80=AFAM, Andriy Gapon <avg@freebsd.org> wrote:= >=20 > =EF=BB=BFThe branch main has been updated by avg: >=20 > URL: https://cgit.FreeBSD.org/src/commit/?id=3D4d1161f094dd90428847f7e5989= 767e9957055f4 >=20 > commit 4d1161f094dd90428847f7e5989767e9957055f4 > Author: Andriy Gapon <avg@FreeBSD.org> > AuthorDate: 2023-01-03 08:39:32 +0000 > Commit: Andriy Gapon <avg@FreeBSD.org> > CommitDate: 2024-01-28 13:21:09 +0000 >=20 > subr_bus: report DEVICE_SUSPEND failures >=20 > This greatly aids with diagnosing system suspend failures when > they are due to a device driver or hardware. > --- > sys/kern/subr_bus.c | 6 +++++- > 1 file changed, 5 insertions(+), 1 deletion(-) >=20 > diff --git a/sys/kern/subr_bus.c b/sys/kern/subr_bus.c > index 21c2835f2ae6..c06f3df0c9c9 100644 > --- a/sys/kern/subr_bus.c > +++ b/sys/kern/subr_bus.c > @@ -3463,8 +3463,12 @@ bus_generic_suspend_child(device_t dev, device_t ch= ild) >=20 > error =3D DEVICE_SUSPEND(child); >=20 > - if (error =3D=3D 0) > + if (error =3D=3D 0) { > child->flags |=3D DF_SUSPENDED; > + } else { > + printf("DEVICE_SUSPEND(%s) failed: %d\n", > + device_get_nameunit(child), error); > + } >=20 > return (error); > } >=20
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?AB8F544B-D69E-4D9F-861D-B8B59FA7C7ED>