intelgpu.php ended with an inline <script> without the CSP nonce, so the
browser refused to run it and logged a Content-Security-Policy violation
each time the view opened. The script bound the Back and Refresh buttons,
which views/js/intelgpu.js already does (loaded by xhtmlFooter()), the
same way the other views do it. Remove the inline copy rather than give it
a nonce: with a nonce both handlers would run on each click, and its
"enable Back when history.length > 1" would fight intelgpu.js, which
disables Back when there is no referrer.
No change in what the buttons do: the inline script never ran.
fixes#5244
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Under a threaded MPM (event/worker) Apache blocks signals in its worker
threads and children started by exec() inherit that mask. Where /bin/sh
is bash (Gentoo, Fedora/RHEL, Arch) the mask reaches intel_gpu_top, which
never sees the SIGTERM from "timeout 2", so exec() never returned, the
page never loaded and every visit left another intel_gpu_top running.
dash, Debian's /bin/sh, clears the mask, which is why it doesn't show
there.
- Run the sample with -n 2 where intel_gpu_top supports it, so it exits
by itself after one full period. Support is detected from -h, because
intel-gpu-tools 1.26/1.27 (Ubuntu 22.04, Debian 12) lack -n.
- Without -n, keep "timeout 2" but add -k 3, so a blocked SIGTERM is
followed by an unblockable SIGKILL. The samples printed before the kill
are still parsed; only when there are none does the view explain the
kill instead of showing a raw-output error.
- Give the -h and -L calls a SIGKILL timeout too.
- Report the driver bound to the Intel DRM device and the kernel version
instead of /sys/module/i915/version or modinfo, neither of which gives
a version for i915 or xe, and neither of which exists when the driver
is built in, so Driver always showed Unknown.
- Add dark theme styles for the view's cards, card headers, footer row
and progress bars, which kept Bootstrap's light backgrounds behind the
dark theme's light text.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>