On Wed, 19 Jun 2019 at 13:01, Milan Broz <gmazyland@xxxxxxxxx> wrote: > > On 19/06/2019 11:14, Ard Biesheuvel wrote: > > Apologies, this was a rebase error on my part. > > > > Could you please apply the hunk below and try again? > > > > diff --git a/crypto/essiv.c b/crypto/essiv.c > > index 029a65afb4d7..5dc2e592077e 100644 > > --- a/crypto/essiv.c > > +++ b/crypto/essiv.c > > @@ -243,6 +243,8 @@ static int essiv_aead_encrypt(struct aead_request *req) > > static int essiv_skcipher_decrypt(struct skcipher_request *req) > > { > > struct essiv_skcipher_request_ctx *rctx = skcipher_request_ctx(req); > > + > > + essiv_skcipher_prepare_subreq(req); > > return crypto_skcipher_decrypt(&rctx->blockcipher_req); > > } > > That helps, but now the null cipher is broken... > (We use it for debugging and during reencryption from non-encrypted device) > I guess that would be the cipher parsing change in the first patch. I'll have a look. > Try > cryptsetup open --type plain -c null /dev/sdd test -q > or > dmsetup create test --table " 0 417792 crypt cipher_null-ecb - 0 /dev/sdd 0" > > (or just run full cryptsetup testsuite) > Is that your mode-test script? I saw some errors about the null cipher, but tbh, it looked completely unrelated to me, so i skipped those for the moment. But now, it looks like it is related after all. > kernel: BUG: kernel NULL pointer dereference, address: 00000000 > kernel: #PF: supervisor read access in kernel mode > kernel: #PF: error_code(0x0000) - not-present page > kernel: *pde = 00000000 > kernel: Oops: 0000 [#1] PREEMPT SMP > kernel: CPU: 2 PID: 2261 Comm: cryptsetup Not tainted 5.2.0-rc5+ #521 > kernel: Hardware name: VMware, Inc. VMware Virtual Platform/440BX Desktop Reference Platform, BIOS 6.00 04/13/2018 > kernel: EIP: strcmp+0x9/0x20 > kernel: Code: 00 55 89 c1 89 e5 57 89 c7 56 89 d6 ac aa 84 c0 75 fa 5e 89 c8 5f 5d c3 8d b4 26 00 00 00 00 66 90 55 89 e5 57 89 d7 56 89 c6 <ac> ae 75 08 84 c0 75 f8 31 c0 eb 04 19 c0 0c 01 5e 5f 5d c3 8d 76 > kernel: EAX: 00000000 EBX: ef51016c ECX: 0000000c EDX: f78e585e > kernel: ESI: 00000000 EDI: f78e585e EBP: f238dcb0 ESP: f238dca8 > kernel: DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068 EFLAGS: 00210282 > kernel: CR0: 80050033 CR2: 00000000 CR3: 30a28000 CR4: 00140690 > kernel: Call Trace: > kernel: crypt_ctr+0x473/0xf4e [dm_crypt] > kernel: dm_table_add_target+0x15f/0x340 [dm_mod] > kernel: table_load+0xe9/0x280 [dm_mod] > kernel: ? retrieve_status+0x200/0x200 [dm_mod] > kernel: ctl_ioctl+0x1c8/0x400 [dm_mod] > kernel: ? retrieve_status+0x200/0x200 [dm_mod] > kernel: ? ctl_ioctl+0x400/0x400 [dm_mod] > kernel: dm_ctl_ioctl+0x8/0x10 [dm_mod] > kernel: do_vfs_ioctl+0x3dd/0x790 > kernel: ? trace_hardirqs_on+0x4a/0xf0 > kernel: ? ksys_old_semctl+0x27/0x30 > kernel: ksys_ioctl+0x2e/0x60 > kernel: ? mpihelp_add_n+0x39/0x50 > kernel: sys_ioctl+0x11/0x20 > kernel: do_int80_syscall_32+0x4b/0x1a0 > kernel: ? mpihelp_add_n+0x39/0x50 > kernel: entry_INT80_32+0xcf/0xcf > kernel: EIP: 0xb7f5bbf2 > kernel: Code: de 01 00 05 ed 73 02 00 83 ec 14 8d 80 0c ac ff ff 50 6a 02 e8 5f 12 01 00 c7 04 24 7f 00 00 00 e8 ce cd 01 00 66 90 90 cd 80 <c3> 8d b6 00 00 00 00 8d bc 27 00 00 00 00 8b 1c 24 c3 8d b6 00 00 > kernel: EAX: ffffffda EBX: 00000005 ECX: c138fd09 EDX: 00511080 > kernel: ESI: b7b83d40 EDI: b7b785af EBP: 0050dda0 ESP: bf9e1c34 > kernel: DS: 007b ES: 007b FS: 0000 GS: 0033 SS: 007b EFLAGS: 00200286 > kernel: ? mpihelp_add_n+0x39/0x50 > kernel: Modules linked in: dm_crypt loop dm_mod pktcdvd crc32_pclmul crc32c_intel aesni_intel aes_i586 crypto_simd cryptd ata_piix > kernel: CR2: 0000000000000000 > kernel: ---[ end trace 0d32231f952fd372 ]--- > > m. -- dm-devel mailing list dm-devel@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/dm-devel