RE: [EXT] Re: [PATCH v2 00/15] Add CAAM driver model support

2021-09-27 Thread Gaurav Jain
Hi Tim

> -Original Message-
> From: Tim Harvey 
> Sent: Friday, September 24, 2021 4:32 AM
> To: Gaurav Jain ; Peng Fan 
> Cc: u-boot ; Stefano Babic ; Fabio
> Estevam ; Simon Glass ; Priyanka
> Jain ; Ye Li ; Horia Geanta
> ; Ji Luo ; Franck Lenormand
> ; Silvano Di Ninno ;
> Sahil Malhotra ; Pankaj Gupta
> ; Varun Sethi ; dl-uboot-imx
> ; Shengzhou Liu ; Mingkai Hu
> ; Rajesh Bhagat ; Meenakshi
> Aggarwal ; Wasim Khan
> ; Alison Wang ; Pramod
> Kumar ; Andy Tang ;
> Adrian Alonso ; Vladimir Oltean 
> Subject: [EXT] Re: [PATCH v2 00/15] Add CAAM driver model support
> 
> Caution: EXT Email
> 
> On Fri, Sep 3, 2021 at 12:04 AM Gaurav Jain  wrote:
> >
> > This patchset adds the support for following:
> > 1) CAAM Driver model for all i.MX, layerscape, PPC platforms.
> > 2) Added crypto node in device tree files.
> > 3) CAAM support for blob key encryption key(bkek), random number
> generation.
> > 4) fixed hwrng performance issue in kernel.
> >
> > i.MX platforms:
> > i.MX6, i.MX7, i.MX7ULP, i.MX8MM/MN/MP/MQ, i.MX8QM/QXP
> >
> > Layerscape platforms:
> > LS1021, LS1012, LS1028, LS1043, LS1046, LS1088, LS2088, LX2160, LX2162
> >
> > Powerpc platforms:
> > P3041, P4080, P5040, P2041, T1024, T1042, T2080, T4240
> >
> > Gaurav Jain (14):
> >   crypto/fsl: Add support for CAAM Job ring driver model
> >   crypto/fsl: Add CAAM support for bkek, random number generation
> >   i.MX8M: crypto: updated device tree for supporting DM in SPL
> >   crypto/fsl: i.MX8M: Enable Job ring driver model in SPL and U-Boot.
> >   i.MX6: Enable Job ring driver model in U-Boot.
> >   i.MX7: Enable Job ring driver model in U-Boot.
> >   i.MX7ULP: Enable Job ring driver model in U-Boot.
> >   i.MX8: Add crypto node in device tree
> >   crypto/fsl: i.MX8: Enable Job ring driver model in SPL and U-Boot.
> >   Layerscape: Add crypto node in device tree
> >   Layerscape: Enable Job ring driver model in U-Boot.
> >   PPC: Add crypto node in device tree
> >   PPC: Enable Job ring driver model in U-Boot
> >   update CAAM MAINTAINER
> >
> > Ye Li (1):
> >   crypto/fsl: Fix kick_trng
> >
> 
> Gaurav,
> 
> I am interested in seeing support added to provide a command to blob/deblob
> data using CAAM. Peng submitted previously a patch
> 'crypto: caam: Add fsl caam driver' [1] which was not merged because it was
> adding a new CAAM driver instead of adding functionality to the existing one.
> Peng's patch added driver support and added a 'caam'
> command to allow 'caam genblob' and 'caam decap'.
> 
> If that is what you are trying to do in this series I see you add a function
> derive_blob_kek but it appears to be not used anywhere. Were you going to also
> add a command or add this to the 'dek_blob' command?
> 

This patch series is modifying the existing CAAM driver to caam driver model.
And is common caam implementation for all i.MX, Layerscape and powerpc.

We already have blob encap/decap support added in cmd/blob.c
After this patch series, We are also planning to add more feature for blob and 
command for derive_blob_kek later.

Regards
Gaurav Jain

> Best regards,
> 
> Tim
> 
> [1]
> https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fpatchwo
> rk.ozlabs.org%2Fproject%2Fuboot%2Fpatch%2F20210325093036.3270101-32-
> peng.fan%40oss.nxp.com%2F&data=04%7C01%7Cgaurav.jain%40nxp.com
> %7C7952867f2b414e4a6c8508d97ee62e2b%7C686ea1d3bc2b4c6fa92cd99c5c3
> 01635%7C0%7C0%7C637680349347068156%7CUnknown%7CTWFpbGZsb3d8ey
> JWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C
> 1000&sdata=AhEHy7E192SGEPn8zhnDM0GbVsKqwXL2EvKTDoV1T1Q%3D&
> amp;reserved=0


Re: [PATCH v2 00/15] Add CAAM driver model support

2021-09-23 Thread Tim Harvey
On Fri, Sep 3, 2021 at 12:04 AM Gaurav Jain  wrote:
>
> This patchset adds the support for following:
> 1) CAAM Driver model for all i.MX, layerscape, PPC platforms.
> 2) Added crypto node in device tree files.
> 3) CAAM support for blob key encryption key(bkek), random number generation.
> 4) fixed hwrng performance issue in kernel.
>
> i.MX platforms:
> i.MX6, i.MX7, i.MX7ULP, i.MX8MM/MN/MP/MQ, i.MX8QM/QXP
>
> Layerscape platforms:
> LS1021, LS1012, LS1028, LS1043, LS1046, LS1088, LS2088, LX2160, LX2162
>
> Powerpc platforms:
> P3041, P4080, P5040, P2041, T1024, T1042, T2080, T4240
>
> Gaurav Jain (14):
>   crypto/fsl: Add support for CAAM Job ring driver model
>   crypto/fsl: Add CAAM support for bkek, random number generation
>   i.MX8M: crypto: updated device tree for supporting DM in SPL
>   crypto/fsl: i.MX8M: Enable Job ring driver model in SPL and U-Boot.
>   i.MX6: Enable Job ring driver model in U-Boot.
>   i.MX7: Enable Job ring driver model in U-Boot.
>   i.MX7ULP: Enable Job ring driver model in U-Boot.
>   i.MX8: Add crypto node in device tree
>   crypto/fsl: i.MX8: Enable Job ring driver model in SPL and U-Boot.
>   Layerscape: Add crypto node in device tree
>   Layerscape: Enable Job ring driver model in U-Boot.
>   PPC: Add crypto node in device tree
>   PPC: Enable Job ring driver model in U-Boot
>   update CAAM MAINTAINER
>
> Ye Li (1):
>   crypto/fsl: Fix kick_trng
>

Gaurav,

I am interested in seeing support added to provide a command to
blob/deblob data using CAAM. Peng submitted previously a patch
'crypto: caam: Add fsl caam driver' [1] which was not merged because
it was adding a new CAAM driver instead of adding functionality to the
existing one. Peng's patch added driver support and added a 'caam'
command to allow 'caam genblob' and 'caam decap'.

If that is what you are trying to do in this series I see you add a
function derive_blob_kek but it appears to be not used anywhere. Were
you going to also add a command or add this to the 'dek_blob' command?

Best regards,

Tim

[1] 
https://patchwork.ozlabs.org/project/uboot/patch/20210325093036.3270101-32-peng@oss.nxp.com/


[PATCH v2 00/15] Add CAAM driver model support

2021-09-03 Thread Gaurav Jain
This patchset adds the support for following:
1) CAAM Driver model for all i.MX, layerscape, PPC platforms.
2) Added crypto node in device tree files.
3) CAAM support for blob key encryption key(bkek), random number generation.
4) fixed hwrng performance issue in kernel.

i.MX platforms:
i.MX6, i.MX7, i.MX7ULP, i.MX8MM/MN/MP/MQ, i.MX8QM/QXP

Layerscape platforms:
LS1021, LS1012, LS1028, LS1043, LS1046, LS1088, LS2088, LX2160, LX2162

Powerpc platforms:
P3041, P4080, P5040, P2041, T1024, T1042, T2080, T4240

Gaurav Jain (14):
  crypto/fsl: Add support for CAAM Job ring driver model
  crypto/fsl: Add CAAM support for bkek, random number generation
  i.MX8M: crypto: updated device tree for supporting DM in SPL
  crypto/fsl: i.MX8M: Enable Job ring driver model in SPL and U-Boot.
  i.MX6: Enable Job ring driver model in U-Boot.
  i.MX7: Enable Job ring driver model in U-Boot.
  i.MX7ULP: Enable Job ring driver model in U-Boot.
  i.MX8: Add crypto node in device tree
  crypto/fsl: i.MX8: Enable Job ring driver model in SPL and U-Boot.
  Layerscape: Add crypto node in device tree
  Layerscape: Enable Job ring driver model in U-Boot.
  PPC: Add crypto node in device tree
  PPC: Enable Job ring driver model in U-Boot
  update CAAM MAINTAINER

Ye Li (1):
  crypto/fsl: Fix kick_trng

 MAINTAINERS   |   7 +
 arch/arm/Kconfig  |   9 +-
 arch/arm/cpu/armv7/ls102xa/Kconfig|   4 +
 arch/arm/cpu/armv7/ls102xa/cpu.c  |  16 +
 arch/arm/cpu/armv8/fsl-layerscape/Kconfig |  27 ++
 arch/arm/cpu/armv8/fsl-layerscape/cpu.c   |  10 +-
 arch/arm/dts/fsl-imx8dx.dtsi  |  61 ++-
 arch/arm/dts/fsl-imx8qm-mek-u-boot.dtsi   |  34 +-
 arch/arm/dts/fsl-imx8qm.dtsi  |  61 ++-
 arch/arm/dts/fsl-imx8qxp-mek-u-boot.dtsi  |  34 +-
 arch/arm/dts/fsl-ls1012a.dtsi |  46 +-
 arch/arm/dts/fsl-ls1028a.dtsi |  41 +-
 arch/arm/dts/fsl-ls1043a.dtsi |  45 +-
 arch/arm/dts/fsl-ls1046a.dtsi |  44 ++
 arch/arm/dts/fsl-ls1088a.dtsi |  39 ++
 arch/arm/dts/fsl-ls2080a.dtsi |  39 ++
 arch/arm/dts/fsl-lx2160a.dtsi |  41 +-
 arch/arm/dts/imx7ulp.dtsi |  24 +
 arch/arm/dts/imx8mm-evk-u-boot.dtsi   |  18 +-
 arch/arm/dts/imx8mm.dtsi  |   1 +
 arch/arm/dts/imx8mn-ddr4-evk-u-boot.dtsi  |  18 +-
 arch/arm/dts/imx8mn.dtsi  |   1 +
 arch/arm/dts/imx8mp-evk-u-boot.dtsi   |  18 +-
 arch/arm/dts/imx8mp.dtsi  |   1 +
 arch/arm/dts/imx8mq.dtsi  |   1 +
 arch/arm/dts/ls1021a.dtsi |  40 ++
 arch/arm/include/asm/arch-imx8/imx-regs.h |   5 +-
 arch/arm/include/asm/arch-imx8m/imx-regs.h|   1 +
 arch/arm/mach-imx/cmd_dek.c   |   1 +
 arch/arm/mach-imx/imx8/Kconfig|   9 +
 arch/arm/mach-imx/imx8/cpu.c  |  16 +-
 arch/arm/mach-imx/imx8m/Kconfig   |  23 +
 arch/arm/mach-imx/imx8m/soc.c |  10 +-
 arch/arm/mach-imx/mx6/Kconfig |   8 +
 arch/arm/mach-imx/mx6/soc.c   |  12 +-
 arch/arm/mach-imx/mx7/Kconfig |   3 +
 arch/arm/mach-imx/mx7/soc.c   |  11 +-
 arch/arm/mach-imx/mx7ulp/Kconfig  |   4 +
 arch/arm/mach-imx/mx7ulp/soc.c|  16 +
 arch/powerpc/cpu/mpc85xx/Kconfig  |  44 ++
 arch/powerpc/cpu/mpc85xx/cpu_init.c   |  17 +-
 arch/powerpc/dts/p2041si-post.dtsi|   1 +
 arch/powerpc/dts/p3041si-post.dtsi|   1 +
 arch/powerpc/dts/p4080si-post.dtsi|   1 +
 arch/powerpc/dts/p5040si-post.dtsi|   1 +
 arch/powerpc/dts/qoriq-sec4.0-0.dtsi  |  74 +++
 arch/powerpc/dts/qoriq-sec4.2-0.dtsi  |  83 
 arch/powerpc/dts/qoriq-sec5.2-0.dtsi  |  92 
 arch/powerpc/dts/t1023si-post.dtsi|   1 +
 arch/powerpc/dts/t1042si-post.dtsi|   1 +
 arch/powerpc/dts/t2080si-post.dtsi|   1 +
 arch/powerpc/dts/t4240si-post.dtsi|   1 +
 arch/powerpc/include/asm/u-boot-ppc.h |  13 +
 arch/powerpc/include/asm/u-boot.h |   1 +
 board/freescale/imx8mm_evk/spl.c  |   9 +-
 board/freescale/imx8mn_evk/spl.c  |   8 +-
 board/freescale/imx8mp_evk/spl.c  |  13 +-
 board/freescale/imx8mq_evk/spl.c  |   9 +-
 board/freescale/imx8qm_mek/spl.c  |   6 +-
 board/freescale/imx8qxp_mek/spl.c |   6 +-
 board/freescale/ls1012afrdm/ls1012afrdm.c |   7 +-
 board/freescale/ls1012aqds/ls1012aqds.c   |   6 +-
 board/freescale/ls1012ardb/ls1012ardb.c   |   6 +-
 board/freescale/ls1021aiot/ls1021aiot.c   |   6 +-
 board/freescale/ls1021aqds/ls1021aqds.c   |   6 +-
 board/freescale/ls1021atsn/ls1021atsn.c   |   7 +-
 board/freescale/ls1021atwr