Watch
1
0
Fork
You've already forked hp-envy-27-p014-hda
0

evidence: publish HP ENVY HDA records

Source-Sha: df779aa3e2cdb4774c0012b2f4f44791307634c6
Policy-Sha: 4c7fb444a162068e847747dd5a03c057631225e8eb05e44d0e358eae6c4e4266
Tree-Digest: 1c9cc7ba9fa0cdc70bcfa82d4eda9a4dbec0a391b9106858d0f69b944ac7cdb7
This commit is contained in:
Casey Tunturi 2026-09-14 13:44:54 -04:00
commit 4ce9e03773
44 changed files with 51208 additions and 0 deletions

View file

@ -0,0 +1,60 @@
Running as unit: hp27-reset-L-probe-20260911.service
Baseline before test
2026-09-11T08:45:55-04:00
04 00 00 00 14 00 00 00 03 00 00 00 47 4e 55 00
b6 ce b1 92 17 b7 7e 67 0e 93 a0 10 d5 a2 6b 56
9d 08 ac 26
0 [PCH ]: HDA-Intel - HDA Intel PCH
HDA Intel PCH at 0xdf320000 irq 134
00-00: CX20753/4 Analog : CX20753/4 Analog : playback 1 : capture 1
00-03: HDMI 0 : HDMI 0 : playback 1
00-07: HDMI 1 : HDMI 1 : playback 1
00-08: HDMI 2 : HDMI 2 : playback 1
Codec: Conexant CX20753/4
Address: 0
AFG Function Id: 0x1 (unsol 1)
Vendor Id: 0x14f15111
Subsystem Id: 0x14f10101
Revision Id: 0x100100
Codec: Intel Skylake HDMI
Address: 2
AFG Function Id: 0x1 (unsol 0)
Vendor Id: 0x80862809
Subsystem Id: 0x80860101
Revision Id: 0x100000
on
Loading L standard-reset experiment
2026-09-11T08:46:34-04:00
04 00 00 00 14 00 00 00 03 00 00 00 47 4e 55 00
c8 45 2c 05 6a f2 70 3f 4f 09 ae 19 a6 11 a7 51
6c 57 ca 64
0 [PCH ]: HDA-Intel - HDA Intel PCH
HDA Intel PCH at 0xdf320000 irq 134
00-03: HDMI 0 : HDMI 0 : playback 1
00-07: HDMI 1 : HDMI 1 : playback 1
00-08: HDMI 2 : HDMI 2 : playback 1
Codec: Intel Skylake HDMI
Address: 2
AFG Function Id: 0x1 (unsol 0)
Vendor Id: 0x80862809
Subsystem Id: 0x80860101
Revision Id: 0x100000
on
Sep 11 08:46:26 fedora kernel: snd_hda_intel 0000:00:1f.3: bound 0000:00:02.0 (ops intel_audio_component_bind_ops [i915])
Sep 11 08:46:26 fedora kernel: snd_hda_intel 0000:00:1f.3: hp27-L: reset=0 pm_prepared=0 status=0x0 stopped=0x0 after=0x4 mask=0x4->0x4 gctl=0x1
Sep 11 08:46:26 fedora kernel: input: HDA Intel PCH HDMI/DP,pcm=3 as /devices/pci0000:00/0000:00:1f.3/sound/card0/input54
Sep 11 08:46:26 fedora kernel: input: HDA Intel PCH HDMI/DP,pcm=7 as /devices/pci0000:00/0000:00:1f.3/sound/card0/input55
Sep 11 08:46:26 fedora kernel: input: HDA Intel PCH HDMI/DP,pcm=8 as /devices/pci0000:00/0000:00:1f.3/sound/card0/input56
Sep 11 08:46:34 fedora kernel: snd_hda_intel 0000:00:1f.3: spurious response 0x233:0x2, last cmd=0x201f0500
Sep 11 08:46:34 fedora kernel: snd_hda_intel 0000:00:1f.3: spurious response 0x233:0x2, last cmd=0x201f0500
Sep 11 08:46:35 fedora kernel: snd_hda_intel 0000:00:1f.3: azx_get_response timeout, switching to polling mode: last cmd=0x201f0500
Sep 11 08:46:36 fedora kernel: snd_hda_intel 0000:00:1f.3: No response from codec, disabling MSI: last cmd=0x201f0500
Sep 11 08:46:37 fedora kernel: snd_hda_intel 0000:00:1f.3: azx_get_response timeout, switching to single_cmd mode: last cmd=0x201f0500
Restoring verified K module
rmmod: ERROR: Module snd_hda_intel is in use
RECOVERY FAILED: driver still in use
Finished with result: exit-code
Main processes terminated with: code=exited, status=90/n/a
Service runtime: 42.536s
CPU time consumed: 226ms
Memory peak: 3.6M (swap: 0B)

View file

@ -0,0 +1,80 @@
#!/usr/bin/env bash
set -euo pipefail
baseline=/lib/modules/7.1.4-100.fc43.x86_64/updates/snd-hda-intel.ko
candidate=/lib/modules/hp27-experiment-L-wkJWVQET/snd-hda-intel.ko
expected=d7683f3e64a65614b53dd658343e6e80bfe76a5efd268cc87fbc2e69b7ba6115
audio_uid=$(id -u TARGET_USER)
removed=0
userctl() { runuser -u TARGET_USER -- env XDG_RUNTIME_DIR="/run/user/$audio_uid" systemctl --user "$@"; }
services=(pipewire.service pipewire.socket wireplumber.service pipewire-pulse.service pipewire-pulse.socket)
snapshot() {
date --iso-8601=seconds
od -An -tx1 /sys/module/snd_hda_intel/notes/.note.gnu.build-id
cat /proc/asound/cards /proc/asound/pcm
for codec in /proc/asound/card*/codec*; do
if test -f "$codec"; then head -n 6 "$codec"; fi
done
cat /sys/bus/pci/devices/0000:00:1f.3/power/control
}
unload_controller() { if test -e /sys/bus/pci/drivers/snd_hda_intel/0000:00:1f.3; then printf "%s" 0000:00:1f.3 > /sys/bus/pci/drivers/snd_hda_intel/unbind; fi; rmmod snd_hda_intel; }
recover() {
result=$?
trap - EXIT HUP INT TERM
set +e
if test "$removed" = 0; then
systemctl start alsa-state.service
userctl start "${services[@]}"
echo 'K was not unloaded; audio services restored'
exit "$result"
fi
echo 'Restoring verified K module'
if test -d /sys/module/snd_hda_intel; then
if ! unload_controller; then
echo 'RECOVERY FAILED: driver still in use'
systemctl start alsa-state.service
userctl start "${services[@]}"
exit 90
fi
fi
if ! modprobe snd_hda_intel; then
echo 'RECOVERY FAILED: K could not load'
systemctl start alsa-state.service
userctl start "${services[@]}"
exit 91
fi
sleep 5
snapshot
systemctl start alsa-state.service
userctl start "${services[@]}"
if ! grep -q 'Codec: Conexant CX20753/4' /proc/asound/card*/codec\#0; then
echo 'RECOVERY FAILED: Conexant absent'
exit 92
fi
echo 'K restored; Conexant enumerated; audio services restarted'
exit "$result"
}
test "$(id -u)" = 0
test "$(uname -r)" = 7.1.4-100.fc43.x86_64
test "$(cat /sys/bus/pci/devices/0000:00:1f.3/vendor)" = 0x8086
test "$(cat /sys/bus/pci/devices/0000:00:1f.3/device)" = 0xa170
test "$(cat /sys/bus/pci/devices/0000:00:1f.3/subsystem_vendor)" = 0x103c
test "$(cat /sys/bus/pci/devices/0000:00:1f.3/subsystem_device)" = 0x2b3e
test "$(sha256sum "$baseline" | cut -d ' ' -f 1)" = "$expected"
test "$(sha256sum /lib/modules/7.1.4-100.fc43.x86_64/updates/snd-hda-intel.ko | cut -d ' ' -f 1)" = "$expected"
test -s "$candidate"
test "$(modinfo -F vermagic "$candidate")" = "$(modinfo -F vermagic "$baseline")"
echo 'Baseline before test'
snapshot
trap recover EXIT
trap 'exit 129' HUP
trap 'exit 130' INT
trap 'exit 143' TERM
userctl stop "${services[@]}"
systemctl stop alsa-state.service
unload_controller
removed=1
echo 'Loading L standard-reset experiment'
insmod "$candidate"
sleep 8
snapshot
journalctl -b -k --since '-1 minute' --no-pager

View file

@ -0,0 +1,15 @@
2026-09-11T08:48:26-04:00
00-00: CX20753/4 Analog : CX20753/4 Analog : playback 1 : capture 1
00-03: HDMI 0 : HDMI 0 : playback 1
00-07: HDMI 1 : HDMI 1 : playback 1
00-08: HDMI 2 : HDMI 2 : playback 1
04 00 00 00 14 00 00 00 03 00 00 00 47 4e 55 00
b6 ce b1 92 17 b7 7e 67 0e 93 a0 10 d5 a2 6b 56
9d 08 ac 26
active
active
active
active
active
active
d7683f3e64a65614b53dd658343e6e80bfe76a5efd268cc87fbc2e69b7ba6115 /lib/modules/7.1.4-100.fc43.x86_64/updates/snd-hda-intel.ko

View file

@ -0,0 +1,56 @@
--- intel.c
+++ intel.c
@@ -998,31 +998,22 @@
-static u16 hp_envy_27_reset_link(struct azx *chip)
-{
- struct hdac_bus *bus = azx_bus(chip);
- u32 gctl;
- u16 statests;
- int timeout;
-
- snd_hdac_bus_stop_chip(bus);
-
- gctl = snd_hdac_chip_readl(bus, GCTL);
- snd_hdac_chip_writel(bus, GCTL, gctl & ~AZX_GCTL_RESET);
- for (timeout = 250; timeout; timeout--) {
- if (!(snd_hdac_chip_readl(bus, GCTL) & AZX_GCTL_RESET))
- break;
- udelay(1);
- }
-
- gctl = snd_hdac_chip_readl(bus, GCTL);
- snd_hdac_chip_writel(bus, GCTL, gctl | AZX_GCTL_RESET);
- for (timeout = 250; timeout; timeout--) {
- if (snd_hdac_chip_readl(bus, GCTL) & AZX_GCTL_RESET)
- break;
- udelay(1);
- }
-
- statests = snd_hdac_chip_readw(bus, STATESTS);
- bus->codec_mask |= statests;
- snd_hdac_bus_init_chip(bus, false);
-
- return statests;
-}
+static u16 hp_envy_27_reset_link(struct azx *chip)
+{
+ struct hdac_bus *bus = azx_bus(chip);
+ u16 before, stopped, statests;
+ unsigned long mask = bus->codec_mask;
+ int err;
+
+ before = snd_hdac_chip_readw(bus, STATESTS);
+ snd_hdac_bus_stop_chip(bus);
+ stopped = snd_hdac_chip_readw(bus, STATESTS);
+
+ err = snd_hdac_bus_reset_link(bus, true);
+ statests = snd_hdac_chip_readw(bus, STATESTS);
+ bus->codec_mask |= statests;
+ dev_info(chip->card->dev,
+ "hp27-L: reset=%d pm_prepared=%u status=%#x stopped=%#x after=%#x mask=%#lx->%#lx gctl=%#x\n",
+ err, chip->pm_prepared, before, stopped, statests,
+ mask, bus->codec_mask, snd_hdac_chip_readl(bus, GCTL));
+ snd_hdac_bus_init_chip(bus, false);
+
+ return err ? 0 : statests;
+}