linux-block.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/3] Add inline encryption support
@ 2024-09-16  8:57 Md Sadre Alam
  2024-09-16  8:57 ` [PATCH v2 1/3] dm-inlinecrypt: " Md Sadre Alam
                   ` (2 more replies)
  0 siblings, 3 replies; 30+ messages in thread
From: Md Sadre Alam @ 2024-09-16  8:57 UTC (permalink / raw)
  To: axboe, song, yukuai3, agk, snitzer, mpatocka, adrian.hunter,
	quic_asutoshd, ritesh.list, ulf.hansson, andersson, konradybcio,
	kees, gustavoars, linux-block, linux-kernel, linux-raid, dm-devel,
	linux-mmc, linux-arm-msm, linux-hardening
  Cc: quic_srichara, quic_varada, quic_mdalam

QCOM SDCC controller having Inline Crypto Engine support
Inline Crypto Engine do encryption/decryption on fly.
dm-inlinecrypt driver will be use to do encryption/decryption
with Inline Crypto Engine. 

v2:
 * Added new driver dm-inlinecrypt
 * Dropped patch "md: dm-crypt: Set cc->iv_size to 4 bytes"
 * squash patch "blk-crypto: Add additional algo modes for Inline"
   encryption and patch "md: dm-crypt: Add additional algo modes for
   inline encryption" to the dm-inlinecrypt driver.
 * tested with dmsetup command as below
   dmsetup create test-crypt --table '0 251904 inline-crypt aes128-xts-
   plain a7f67ad520bd83b9725df6ebd76c3eeea7f67ad520bd83b9725df6ebd76c3eee 
   0 /dev/mmcblk0p27 0 1'

   dd if=/dev/urandom of=/tmp/data bs=1M count=1
   dd if=/tmp/data of=/dev/mapper/test-crypt bs=1M count=1
   dd of=/tmp/data1 if=/dev/mapper/test-crypt bs=1M count=1
   dd of=/tmp/data2 if=/dev/mmcblk0p27 bs=1M count=1
   md5sum /tmp/data*
   b45d728bfb499b6de9b12c98fbb652dd  /tmp/data
   b45d728bfb499b6de9b12c98fbb652dd  /tmp/data1
   bc4107e19cf6fc012c5b997bdd3f0de4  /tmp/data2
   dmsetup remove /dev/mapper/test-crypt

v1:
 * This series of patches add additional modes for inline encryption
   This series of patches depends on [1] Add inline encryption support for
   dm-crypt
   [1]: https://lore.kernel.org/all/b45d3b40-2587-04dc-9601-a9251dacf806@opensource.wdc.com/T/#ma01f08a941107217c93680fa25e96e8d406df790

 * These patches tested on IPQ9574 with eMMC ICE for raw partition
   encryption/decryption.

   e.g:

   dmsetup create test-crypt --table '0 251904 crypt aes128-xts-plain64
   a7f67ad520bd83b9725df6ebd76c3eeea7f67ad520bd83b9725df6ebd76c3eee 0
   /dev/mmcblk0p27 0 1 inline_crypt'

  dd if=/dev/urandom of=/tmp/data bs=1M count=1

  dd if=/tmp/data of=/dev/mapper/test-crypt bs=1M count=1

  dd of=/tmp/data1 if=/dev/mapper/test-crypt bs=1M count=1

  dd of=/tmp/data2 if=/dev/mmcblk0p27 bs=1M count=1

  md5sum /tmp/data*
  b45d728bfb499b6de9b12c98fbb652dd  /tmp/data
  b45d728bfb499b6de9b12c98fbb652dd  /tmp/data1
  bc4107e19cf6fc012c5b997bdd3f0de4  /tmp/data2

  dmsetup remove /dev/mapper/test-crypt


Md Sadre Alam (3):
  dm-inlinecrypt: Add inline encryption support
  mmc: cqhci: Add additional algo mode for inline encryption
  mmc: sdhci-msm: Add additional algo mode for inline encryption

 block/blk-crypto.c              |  21 +++
 drivers/md/Kconfig              |   8 +
 drivers/md/Makefile             |   1 +
 drivers/md/dm-inline-crypt.c    | 316 ++++++++++++++++++++++++++++++++
 drivers/mmc/host/cqhci-crypto.c |  12 ++
 drivers/mmc/host/sdhci-msm.c    |  10 +-
 drivers/soc/qcom/ice.c          |  65 ++++++-
 include/linux/blk-crypto.h      |   3 +
 8 files changed, 419 insertions(+), 17 deletions(-)
 create mode 100644 drivers/md/dm-inline-crypt.c

-- 
2.34.1


^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2024-10-29 11:09 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-16  8:57 [PATCH v2 0/3] Add inline encryption support Md Sadre Alam
2024-09-16  8:57 ` [PATCH v2 1/3] dm-inlinecrypt: " Md Sadre Alam
2024-09-17  5:05   ` kernel test robot
2024-09-17  6:38   ` kernel test robot
2024-09-18  5:08   ` kernel test robot
2024-09-21 18:55   ` Eric Biggers
2024-09-24  7:44     ` Christoph Hellwig
2024-09-24 22:04       ` Eric Biggers
2024-10-01  8:37         ` Christoph Hellwig
2024-10-18  3:26       ` Adrian Vovk
2024-10-18  5:22         ` Christoph Hellwig
     [not found]           ` <CAAdYy_mVy3uXPqWbjPzK_i8w7Okq73wKBQyc95TbnonE36rPgQ@mail.gmail.com>
2024-10-18  5:56             ` Christoph Hellwig
2024-10-18 15:03               ` Adrian Vovk
2024-10-23  6:57                 ` Christoph Hellwig
2024-10-24  2:52                   ` Adrian Vovk
2024-10-24  3:17                     ` Adrian Vovk
2024-10-24  6:14                     ` Christoph Hellwig
2024-10-24  7:52                       ` Adrian Vovk
2024-10-24  9:04                         ` Christoph Hellwig
2024-10-24 15:32                           ` Adrian Vovk
2024-10-24 15:59                             ` Christoph Hellwig
2024-10-24 16:23                               ` Adrian Vovk
2024-10-29 11:08                         ` Mikulas Patocka
2024-10-24  8:11                     ` Geoff Back
2024-10-24 15:28                       ` Adrian Vovk
2024-10-24 19:21                         ` John Stoffel
2024-10-24 20:45                           ` Adrian Vovk
2024-10-15 10:59   ` Mikulas Patocka
2024-09-16  8:57 ` [PATCH v2 2/3] mmc: cqhci: Add additional algo mode for inline encryption Md Sadre Alam
2024-09-16  8:57 ` [PATCH v2 3/3] mmc: sdhci-msm: " Md Sadre Alam

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).