dm-crypt.c has calls to dm_submit_bio_remap to submit a bio asynchronously to the underlying layer device. I have a requirement for synchronous submission of a bio. When I used submit_bio_wait, the call just hangs forever. If I set REQ_SYNC in bio->bi_opf and set both bio->bi_private and bio->bi_end_io to NULL (indicating no callback), and then use dm_submit_bio_remap , I get an OOPS with null pointer dereference. Can you help me with a proper way to submit the bio synchronously inside dm-crypt.c?