mirror of
https://github.com/nlzy/turing-unlock.git
synced 2026-12-03 19:52:43 +07:00
[GH-ISSUE #21] debian: package ships only an initramfs-tools drop-in, so on a dracut backend the module silently never reaches the initramfs #16
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
nlzy/turing-unlock#16
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @haichongck on GitHub (Oct 28, 2026).
Original GitHub issue: https://github.com/nlzy/turing-unlock/issues/21
Problem
The Debian package builds and installs the module correctly, but the module never reaches the initramfs on dracut-based systems, so the unlock silently does nothing.
Two separate problems compound here.
1.
debian/rulesnever callsinstall-dracutpackaging/boot/dracut.confexists and theinstall-dracutMakefile target exists, butdebian/rulesonly runs:install-dracutis missing from that list, so no dracut drop-in is shipped in the.deb.2. The shipped drop-in path is read by nothing
The deb does install
/usr/share/initramfs-tools/modules.d/turing-unlock.conf, but on this system nothing reads that directory:And on Ubuntu 26.04
update-initramfsis already a dracut backend —update-initramfs -vprintsdracut[I]:lines — so/etc/initramfs-tools/modulesis dead as well:Observed behaviour
Everything reports success:
But the image contains none of it:
The only user-visible symptom is the absence of the module's log line — no error anywhere. A user would reasonably conclude their card is unsupported.
Workaround
Use the project's own dracut config, which is exactly the right content:
After this, dracut emits
rd.driver.pre=turing_unlockand the image picks up the module plus all six firmware blobs, because the module declares them viaMODULE_FIRMWARE:rd.driver.preis what makes the ordering correct:nvidia.kois itself pulled into the image byhooks/framebuffer-nvidia(copy_modules_dir_filter updates/dkms nvidia, whose innermanual_add_modulesadds it to the load list), so the unlock module has to be earlier or it hits-EBUSYonpdev->driver.Suggested fix
install-dracuttooverride_dh_auto_installindebian/rules, installing to/usr/lib/dracut/dracut.conf.d/.postinst(e.g. presence ofdracutin use, or which tool produced/boot/initrd.img-*) and only then rebuild.Also worth noting (minor, same install path)
dpkg-buildpackagefails on the build-dependency check becausedh-sequence-dkmsdoes not exist as a Debian package; the real provider isdh-dkms.Working around it with
apt install debhelper dh-dkms+dpkg-buildpackage -us -uc -dproduces a correct package with a properdh_dkmspostinst, so this looks like purely a packaging metadata issue.Environment
7.0.0-38-generic595.99.02(proprietary,nvidia-dkms-595), DKMS 3.2.2110-11ubuntu0.1(active backend behindupdate-initramfs)2.0.0,main @ 417f333, firmware610.43.0310de:1e07)With the drop-in in place, both cards unlock on every boot (compatibility report filed separately).
@gongdao123 commented on GitHub (Oct 28, 2026):
Can confirm, with a couple of details that may help the fix.
Environment: Ubuntu 26.04.1, kernel 7.0.0-38-generic, dracut 110-11ubuntu0.1, NVIDIA 595.99.02 open (Ubuntu's prebuilt
linux-modules-nvidia-595-open-7.0.0-38-generic, no nvidia-dkms), turing-unlock 2.0.0 @417f333, 2× RTX 2080 Ti 22 GB (10de:1e04, NV2).Here dracut is the only backend, not just the active one.
initramfs-toolsis not installed at all, onlyinitramfs-tools-core, andupdate-initramfsitself belongs to the dracut package:As far as I can tell, every Ubuntu 26.04 user of the
.debhits this. A stale/etc/initramfs-tools/initramfs.confis still lying around, which made it look like initramfs-tools at first glance.An easy tell: after installing the two debs, the regenerated initrd was the same size as before (60,395,171 → 60,393,199 bytes), even though
gsp_tu10x.binalone is 29 MB. With the drop-in it grew to 75,719,221 bytes.lsinitrdthen shows the module, the six firmware files, andetc/cmdline.d/20-force_drivers.conf=rd.driver.pre=turing_unlock, and both cards logTU102 FEAT UNLOCKED/unlockedat boot. With Ubuntu's prebuilt nvidia modules,nvidia*.kois not in the dracut image at all, so the ordering race does not come up in this setup;rd.driver.precovers both cases anyway.On the build-dependency note: I think that part is fine as it is.
dh-dkmsdeclaresProvides: dh-sequence-dkms(3.2.2-1ubuntu1 here), somake install-deb→apt-get build-dep <dir>installsdh-dkms, anddpkg-buildpackage -us -ucthen passes without-d.dpkg-checkbuilddepsonly complains when the build deps were installed some other way.Fix: the RPM spec already ships the dracut drop-in via
install-dracut, so the Debian side needs the same two lines. I tested this: the resultingturing-unlock-dkmscontains both/usr/lib/dracut/dracut.conf.d/turing-unlock.confand the initramfs-tools drop-in, anddh_missingis clean. The existingpostinst/postrmalready callupdate-initramfs, which is dracut's shim here, so they need no change. Each drop-in is ignored by the other generator, so shipping both unconditionally seems simplest.Happy to open a PR with this if that helps.
@haichongck commented on GitHub (Oct 28, 2026):
Thanks — and you're right about the build dependency, I'm withdrawing that part.
dh-dkmshere is also3.2.2-1ubuntu1and declaresProvides: dh-sequence-dkms, soapt-get build-depcovers it anddpkg-buildpackage -us -ucpasses without-d. My "missing metapackage" note was a wrong conclusion drawn fromdpkg-checkbuilddepsoutput, not a real defect.I checked your fix against the tree and it lines up exactly:
install-dracutexists atMakefile:81and installspackaging/boot/dracut.conf→/usr/lib/dracut/dracut.conf.d/turing-unlock.confforce_drivers+=" turing_unlock "dropped into/etc/dracut.conf.d/), which is a good sign the packaging simply never shipped what the RPM already doesdebian/rulesreally does end atinstall-dkms install-firmware install-initramfs-tools, anddebian/turing-unlock-dkms.installreally has nousr/lib/dracutMy environment matches yours item for item: dracut
110-11ubuntu0.1,initramfs-toolsuninstalled (un),initramfs-tools-core 0.151ubuntu1, anddpkg -S /usr/sbin/update-initramfs→dracut: /usr/sbin/update-initramfs. So the two reports are the same failure from the same packaging gap.Please do open the PR. Your two-line diff is right, and having it arrive with your own build evidence (
dh_missingclean, both drop-ins present in the result) is better than me writing it from the outside without having built the package.Two small data points for the maintainer:
10de:1e07(TU102 2080 Ti Rev. A) rather than your10de:1e04, so this is not variant-specific — both are affected, and unlock works once the drop-in is in place.rd.driver.prereasoning holds here too: with Ubuntu's prebuiltlinux-modules-nvidia-595-openthere is nonvidia*.koin the dracut image at all, so the ordering race cannot happen, butrd.driver.precovers the dkms case as well.