]> sourceware.org Git - lvm2.git/commit
_create_and_load_v4: propagate ioctl errors back to caller 3/head 1034541995
authorLennart Poettering <lennart@poettering.net>
Wed, 11 Oct 2023 13:35:33 +0000 (15:35 +0200)
committerLennart Poettering <lennart@poettering.net>
Wed, 11 Oct 2023 13:35:33 +0000 (15:35 +0200)
commit25ef7a7b1a876f491bd361369423d7309358f6c1
treeead42121382144a09bf6b0825788f0fa02b7f478
parent63b469c1609fe5d3395b7757eebaf35a4a77ea7a
_create_and_load_v4: propagate ioctl errors back to caller

When setting up dm-verity devices with signed root hashes it is very
useful to have a recognizable error code when a key is not present in
the kernel keyring. Turns out the kernel actually returns ENOKEY in that
case, but this gets lost in libdevmapper.

This fixes this: in _create_and_load_v4() it copies the error code from
the ioctl from the sub-tasks back to the main task field on failure.

This is not enough to make libcryptsetup actually propagate the ENOKEY
correctly, that also needs a patch to libcryptsetup, but this is part of
the puzzle.
libdm/ioctl/libdm-iface.c
This page took 0.035071 seconds and 5 git commands to generate.