Subject: Re: dm_setup_md_queue table_device UAF / concurrent table load

Hi Mikulas,

Thanks for the suggested fix. We verified it on Linux 6.6.144 with KASAN
against our minimized PoC (concurrent DM_TABLE_LOAD racing
dm_setup_md_queue's unlocked table_devices walk).

Results:
  - unpatched: KASAN slab-use-after-free in dm_setup_md_queue (often with
    a follow-on fault around bd_link_disk_holder)
  - with your change (extend table_devices_lock over the list walk):
    no KASAN UAF for a 5-minute PoC window

Self-contained test package (patch + poc.c + A/B scripts + captured logs):

  dm-setup-md-queue-patch-test.tar.gz

Re-run with Docker (see README.md inside the tarball):

  docker build -t dm-setup-md-queue-patch-test -f Dockerfile .
  mkdir -p artifacts
  docker run --rm --privileged --device=/dev/kvm --network=host \
    -v "$PWD/artifacts:/artifacts" -e OUTPUT_DIR=/artifacts \
    dm-setup-md-queue-patch-test

Happy to test follow-ups if needed.

Thanks,
