Thread (8 messages) 8 messages, 3 authors, 2021-03-16

Re: [PATCH 0/2] scsi: target: tcmu: Replace IDR and radix_tree with XArray

From: michael.christie@oracle.com
Date: 2021-02-26 04:00:27
Also in: target-devel

On 2/24/21 12:53 PM, Bodo Stroesser wrote:
This small series is based on Martin's for-next.

Future patches will need something like the - meanwhile removed -
radix_tree_for_each_contig macro.
Since general direction is to use xarray as replacement for
radix_tree and IDR, instead of re-introducing or open coding the
removed macro, with this series we switch over to xarray API.
Based on xarray a future patch easily can implement an analog
to radix_tree_for_each_contig.

Bodo Stroesser (2):
  scsi: target: tcmu: Replace IDR by XArray
  scsi: target: tcmu: Replace radix_tree with XArray

 drivers/target/target_core_user.c | 64 +++++++++++++++++++--------------------
 1 file changed, 31 insertions(+), 33 deletions(-)
Looks ok to me.

Reviewed-by: Mike Christie <michael.christie@oracle.com>

I think in a separate patch we need to change:

+		if (xa_store(&udev->data_blocks, dbi, page, GFP_KERNEL))
 			goto err_insert;

to GFP_NOIO. There were some users doing tcm loop  + tcmu and
were hitting issues when GFP_KERNEL lead to write backs back on
to the same tcmu device. We tried to change all the gfp flags but
we missed that one, because it was hidden in the radix tree's
xa_flags.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help