Date: Thu, 31 Aug 2023 00:04:30 +0000 From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 268393] system always reboots once from a powered off state Message-ID: <bug-268393-227-YCPzNVMjrt@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-268393-227@https.bugs.freebsd.org/bugzilla/> References: <bug-268393-227@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D268393 --- Comment #63 from Ivan Rozhuk <rozhuk.im@gmail.com> --- Why no one suggest patch like this? diff --git a/sys/dev/sound/pci/hda/hdac.c b/sys/dev/sound/pci/hda/hdac.c index 82b1baacfa9..f7be436aef6 100644 --- a/sys/dev/sound/pci/hda/hdac.c +++ b/sys/dev/sound/pci/hda/hdac.c @@ -956,6 +956,8 @@ hdac_rirb_flush(struct hdac_softc *sc) int ret; rirb_base =3D (struct hdac_rirb *)sc->rirb_dma.dma_vaddr; + if (rirb_base =3D=3D NULL) + return (0); rirbwp =3D HDAC_READ_1(&sc->mem, HDAC_RIRBWP); bus_dmamap_sync(sc->rirb_dma.dma_tag, sc->rirb_dma.dma_map, BUS_DMASYNC_POSTREAD); @@ -965,6 +967,8 @@ hdac_rirb_flush(struct hdac_softc *sc) sc->rirb_rp++; sc->rirb_rp %=3D sc->rirb_size; rirb =3D &rirb_base[sc->rirb_rp]; + if (rirb =3D=3D NULL) + break; resp =3D le32toh(rirb->response); resp_ex =3D le32toh(rirb->response_ex); cad =3D HDAC_RIRB_RESPONSE_EX_SDATA_IN(resp_ex); --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-268393-227-YCPzNVMjrt>