Skip to content

introduce sg_pcopy_from_buffer() and sg_pcopy_to_buffer()

Akinobu Mita linux-crypto linux-scsi lkml 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest4 patches 2 repliesIn review
  2. v24 patches 3 repliesSuperseded
  3. v13 patches 4 repliesSuperseded

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4lib/scatterlist: factor out sg_miter_get_next_page() from sg_miter_next()lib/scatterlist.c+24 -150 replies
2/4lib/scatterlist: introduce sg_pcopy_from_buffer() and sg_pcopy_to_buffer()include/linux/scatterlist.h lib/scatterlist.c+88 -51 reply
3/4crypto: talitos: use sg_pcopy_to_buffer()drivers/crypto/talitos.c+1 -590 replies
4/4scsi_debug: fix do_device_access() with wrap around rangedrivers/scsi/scsi_debug.c+37 -111 reply

Reviews trailers per patch

3 of 4 patches have a Reviewed-by or Acked-by.

PatchTejun HeoDouglas Gilbert
1/4A-b
2/4A-b
3/4
4/4A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH v3 0/4] introduce sg_pcopy_from_buffer() and sg_pcopy_to_buffer()

This patch set introduces sg_pcopy_from_buffer() and sg_pcopy_to_buffer(), which copy data between a linear buffer and an SG list.

The only difference between sg_pcopy_{from,to}_buffer() and sg_copy_{from,to}_buffer() is an additional argument that specifies the number of bytes to skip the SG list before copying.

The main reason for introducing these functions is to fix a problem in scsi_debug module. And there is a local function in crypto/talitos module, which can be replaced by sg_pcopy_to_buffer().

* Changes from v2
- Add Acked-by line
- Rename sg_miter_seek() to sg_miter_skip()
- Remove the restriction on when sg_miter_skip() can be called

* Changes from v1
- Separate the change that factors out sg_miter_get_next_page() from the patch "introduce sg_pcopy_from_buffer() and sg_pcopy_to_buffer()"
- Add function comment for internal function sg_miter_seek()
- Simplify the assignment of sdb->resid in fill_from_dev_buffer() in scsi_debug

Akinobu Mita (4):
lib/scatterlist: factor out sg_miter_get_next_page() from

    sg_miter_next()

lib/scatterlist: introduce sg_pcopy_from_buffer() and
sg_pcopy_to_buffer()
crypto: talitos: use sg_pcopy_to_buffer()
scsi_debug: fix do_device_access() with wrap around range

 drivers/crypto/talitos.c    |  60 +--------------------
 drivers/scsi/scsi_debug.c   |  48 +++++++++++++----
 include/linux/scatterlist.h |   5 ++
 lib/scatterlist.c           | 127 +++++++++++++++++++++++++++++++++++++-------
 4 files changed, 150 insertions(+), 90 deletions(-)
Cc Tejun Heo <[email protected]>
Cc Imre Deak <[email protected]>
Cc Herbert Xu <[email protected]>
Cc "David S. Miller" <[email protected]>
Cc "James E.J. Bottomley" <[email protected]>
Cc Douglas Gilbert <[email protected]>
Signature · 1 line
1.8.1.4