Description of problem: mkinitrd should check if current kernel has CONFIG_SYSFS_DEPRECATED_V2 set, otherwise the created initrd image doesn't include necessary steps to setup a luks device, because the sysfs paths used in mkinitrd are hardcoded to the "old" path schema and so the needed steps to setup crypto handling (handle_dm) are not called.
(In reply to comment #0) > Description of problem: > > mkinitrd should check if current kernel has CONFIG_SYSFS_DEPRECATED_V2 set, > otherwise the created initrd image doesn't include necessary steps to setup a > luks device, because the sysfs paths used in mkinitrd are hardcoded to the > "old" path schema and so the needed steps to setup crypto handling (handle_dm) > are not called. I assume you mean 'are hardcoded to the "new" path schema' ? As by default the Fedora kernels do not have CONFIG_SYSFS_DEPRECATED_V2 set, so by default we expect the new paths. Can you come up with a patch which makes mkinitrd work with the paths which one gets when CONFIG_SYSFS_DEPRECATED_V2 is set? It does not need to adept itself automatically I just wonder what the code needs to look like in the CONFIG_SYSFS_DEPRECATED_V2 is set case. Thanks!
Created attachment 334436 [details] old sysfs style and crypto drive
Oops! Yes you are right! I inverted the logic. My self-compiled kernel did use the old sysfs style... - Just fixed that. Anyway the attached diff did the trick for me. Thanks and sorry for the noise.
Thanks for the patch, that was very helpful! This is fixed in mkinitrd-6.0.81, which should be in tomorrows rawhide.