OSDN Git Service

dm: conditionally enable BIOSET_PERCPU_CACHE for dm_io bioset
authorMike Snitzer <snitzer@kernel.org>
Thu, 24 Mar 2022 18:36:47 +0000 (14:36 -0400)
committerMike Snitzer <snitzer@kernel.org>
Thu, 5 May 2022 21:31:33 +0000 (17:31 -0400)
commitcfc97abcbe0b1ffac441202fe330e697370ecbcc
treea85cd5742071111b85e8f6b0f0fb46ddc5a7bd91
parent069adbac2cd85ae00252da6c5576cbf9b9d9ba6e
dm: conditionally enable BIOSET_PERCPU_CACHE for dm_io bioset

A bioset's per-cpu alloc cache may have broader utility in the future
but for now constrain it to being tightly coupled to QUEUE_FLAG_POLL.

Also change dm_io_complete() to use bio_clear_polled() so that it
properly clears all associated bio state on requeue.

This commit improves DM's hipri bio polling (REQ_POLLED) perf by
7 - 20% depending on the system.

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
drivers/md/dm-table.c
drivers/md/dm.c
drivers/md/dm.h