Skip to content

Splitting sg chain allocation support from scsi

Jens Axboe linux-scsi 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 2 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2SG: Move functions to lib/scatterlist.c and add sg chaining allocator helpersinclude/linux/scatterlist.h lib/Makefile lib/scatterlist.c+267 -1010 replies
2/2SG: Convert SCSI to use scatterlist helpers for sg chainingdrivers/scsi/scsi_lib.c drivers/scsi/scsi_tgt_lib.c include/scsi/scsi_cmnd.h+23 -1242 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/2] Splitting sg chain allocation support from scsi

Hi,

Currently scsi_lib.c does its own sg chain allocation and freeing, as it was proof of concept. But other drivers may want to take advantage of that feature as well. These two patches add a lib/scatterlist.c and moves most of the linux/scatterlist.h big include into that, and adds helpers for allocating and initializing an sg list.

This adds a new kernel define SG_MAX_SINGLE_ALLOC that sets the boundary for when sg_alloc_table() will return a chained list, that used to be a scsi private thing.

The patch still needs a bit of cleaning up and documenting, but it's a start. Boots and works here.

Signature · 1 line
Jens Axboe