mbox series

[v3,0/7] UFS Advanced RPMB

Message ID 20221201140437.549272-1-beanhuo@iokpp.de
Headers show
Series UFS Advanced RPMB | expand

Message

Bean Huo Dec. 1, 2022, 2:04 p.m. UTC
Hi,

This series of changes is to add support for UFS advanced RPMB
in ufs_bsg. The advanced RPMB application of user space is ufs_utils, the reference code is
https://github.com/beanhuo/ufs-utils-Micron/blob/ufs_arpmb/ufs_arpmb.c.

Changes to ufs_utils will be pushed to https://github.com/westerndigitalcorporation/ufs-utils
When ARPMB patch is merged into the kernel.


Changelog:

V2 -- V3:
    1. Add new patch 1/7
    2. Addresses several coding issues raised by Avri Altman.
    3. Add  __attribute__((__packed__)) for EHS struct in 7/7

V1 -- V2:
    1. Added RPMB request completion handling in patch 6/6

RFC -- V1:
    1. Split the patch and Remove RFC
    2. Add all 8 types of rpmb operations
    3. Fix one EHS copy error in ufshcd_advanced_rpmb_req_handler()
    4. Fix several issues raised by Avri in the RFC patch:
    https://patchwork.kernel.org/project/linux-scsi/patch/20221107131038.201724-3-beanhuo@iokpp.de/#25081912

Bean Huo (7):
  ufs: bsg: Let result in struct ufs_bsg_reply be signed int
  ufs: ufs_bsg: Remove unnecessary length checkup
  ufs: ufs_bsg: Cleanup ufs_bsg_request
  ufs: core: Split ufshcd_map_sg
  ufs: core: Advanced RPMB detection
  ufs: core: Pass EHS length into ufshcd_prepare_req_desc_hdr()
  ufs: core: Add advanced RPMB support in ufs_bsg

 drivers/ufs/core/ufs_bsg.c       | 137 +++++++++++++++---------
 drivers/ufs/core/ufshcd.c        | 178 +++++++++++++++++++++++++------
 include/uapi/scsi/scsi_bsg_ufs.h |  48 ++++++++-
 include/ufs/ufs.h                |  29 +++++
 include/ufs/ufshcd.h             |   6 +-
 include/ufs/ufshci.h             |   1 +
 6 files changed, 318 insertions(+), 81 deletions(-)

Comments

Martin K. Petersen Dec. 30, 2022, 9:05 p.m. UTC | #1
Bean,

> This series of changes is to add support for UFS advanced RPMB in
> ufs_bsg. The advanced RPMB application of user space is ufs_utils, the
> reference code is
> https://github.com/beanhuo/ufs-utils-Micron/blob/ufs_arpmb/ufs_arpmb.c.
>
> Changes to ufs_utils will be pushed to
> https://github.com/westerndigitalcorporation/ufs-utils When ARPMB
> patch is merged into the kernel.

Applied to 6.3/scsi-staging, thanks!