Use the native helper to handle existing nodes and driver device-file parameters, including stale UVM major numbers. Create the reverse-link directory before the module add handlers, keep GPU minor enumeration, and do not recreate nodes on remove events. Backport the independently prepared helper fix for concurrent device creation.
Assisted-by: OpenAI Codex (gpt-6.1-sol)
v4l2loopback allocates two buffers by default, which is not enough for
GStreamer to keep writing while a consumer holds one. The sink runs out,
fails to allocate, and ends the pipeline:
v4l2bufferpool <v4l2sink:pool0:sink> failed to allocate buffer
basesrc <appsrc> error: Internal data stream error.
V4L2_RELAYD output_pipeline_bus_call: Internal data stream error.
v4l2-relayd exits and gets restarted, so on an IPU6 laptop the sensor
powers off and on again every few seconds, camera indicator light and
all. Pass a buffer count when creating the device and make it
configurable per instance.
Tested on a ThinkPad X1 Yoga Gen 8 (OV2740 behind IPU6, ipu6ep): with
eight buffers an active relay runs for minutes where it used to die
within seconds.
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
Some arguments to `lpadmin` might look like shell expressions,
triggering shellcheck warnings.
This was fixed earlier already, in
6bb5aa2d26 ,
but the fix got lost later, in
85e3dd1d48 .
E.g. this configuration:
hardware.printers.ensurePrinters = [
{
name = "test";
deviceUri = "ipp://somewhere";
location = "";
model = "everywhere";
}
];
Resulted in the following command being generated:
/nix/store/...-cups-2.4.19/bin/lpadmin -L -meverywhere -ptest -vipp://somewhere -E
Note the missing '' after -L which then caused /etc/cups/printers.conf to contain:
Info test
Location -meverywhere
DeviceURI ipp://somewhere
This bug was introduced in 1f4c50ab81 with the
change from the (now deprecated) toGNUCommandLineShell to toCommandLineShellGNU.
Assisted-by: pi (OpenAI gpt-5.5)
using the displaylink module currently fails with
`systemd.enableStrictShellChecks = true;`. there are two warnings:
- `read` without `-r` can technically mangle backslashes, as it acts as
an escape character by default. as far as we can tell, this shouldn't
cause problems, but it seems like a harmless and technically-correct
fix.
- `SUSPEND_RESULT` is unused. as far as i can tell, this indeed seems to
be the case, so this makes sense to remove.
Instead of keeping multiple interdependent systemd units, it's both
cleaner and more stable to just keep all provisioning as a direct part
of the cups unit. This gets rid of all the machinery around whether or
not the unit was socket activated as well, as the provisioning scripts
now will lazily run whenever cups is activated.
this adds support to CUPS classes in a style similar to the
`hardware.printers.ensurePrinters` option.
Classes in CUPS are groups of printers made by the user, usually in
order to group similar printers. When a job is sent to a class, the job
is attempted at each member printer until it succeeds. Classes can be
thought of as 'logical printers', in that they can behave like printers,
despite being an abstraction solely created by the print server.
Fixes a small issue where search.nixos.org shows a text block with `''`'s for the example snippet (which may confuse the user) and added a `;` to correct the example snippet's syntax.
OTD requires WAYLAND_DISPLAY or DISPLAY to be set,
otherwise it assumes x11 which, on a WAYLAND display configuration,
leads to segfaults on OTD start up. Enforce an ordering
so that we wait until the session has initted before doing
anything.
Upstream has both a check for these environment variables,
as well as enforces a RestartSec=3 to prevent immediate
restarts.
Additionally, it's theoretically possible for DISPLAY to
be set before WAYLAND_DISPLAY, causing segmentation faults
on wayland set ups, so add an explicit polling condition for
that in the ExecStartPre script.
Currently, you need to override `stdenv.hostPlatform` to request a
compressed kernel on AArch64, and the kernel configuration is split
between the central structured configuration and string snippets in
platform definitions. This has consequently made the latter bitrot
terribly. Since the platform‐specific logic is now very limited after
cleaning up the detritus, we can move it into the kernel derivation
and expose the relevant configuration there for anyone who wants to
customize it further or needs to read it out.
Co-authored-by: zowoq <59103226+zowoq@users.noreply.github.com>
This changes the NVIDIA NixOS module to use ICD libraries built from
source rather than relying on the pre-compiled bundled versions.
Additionally, this adds a necessary workaround for driver versions
below 595 to ensure proper compatibility.
For more context on the workaround, see the discussion at:
https://github.com/NixOS/nixpkgs/pull/497342#issuecomment-4034876793