Yocto bitbake recipe for caam-keygen aka keyctl_caam

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Yocto bitbake recipe for caam-keygen aka keyctl_caam

1,921 Views
craigmcqueenir
Contributor IV

AN12714 "i.MX Encrypted Storage Using CAAM Secure Keys" refers to the "caam-keygen" user space application. I'm using Yocto with meta-freescale, and thought it would have a bitbake recipe for this tool. But it seems it doesn't.

The file SCR/SCR-5.15.32-2.0.0.txt does list package keyctl_caam.git, at git repo location https://source.codeaurora.org/external/imx/keyctl_caam. That's all it has, as far as I can tell.

Is there a Yocto bitbake recipe anywhere for the "caam-keygen" tool, aka keyctl_caam package?

 

Labels (1)
Tags (1)
0 Kudos
Reply
4 Replies

1,892 Views
craigmcqueenir
Contributor IV

Before @Harvey021's response, I wrote my own recipe as follows.

SUMMARY = "Key generation using NXP CAAM"
HOMEPAGE = "https://www.nxp.com/"

LICENSE = "BSD-3-Clause"
LIC_FILES_CHKSUM = "file://COPYING;md5=8636bd68fc00cc6a3809b7b58b45f982"

SRCBRANCH = "master"

SRC_URI = "git://source.codeaurora.org/external/imx/keyctl_caam;protocol=https;branch=${SRCBRANCH}"
PV = "5.15.5-1.0.0+git${SRCPV}"
PR = "r0"

S = "${WORKDIR}/git"
B = "${WORKDIR}/git"

SRCREV = "81dc06cdb9c4d0d4ba10459d85af9a8603774948"

TARGET_CC_ARCH += "${LDFLAGS}"

do_compile() {
    oe_runmake KEYBLOB_LOCATION=./ all
}

do_install () {
    install -d ${D}/${bindir}/
    install -m 0755 ${B}/caam-keygen ${D}${bindir}/
}

FILES:${PN} += "${bindir}"

 

0 Kudos
Reply

1,913 Views
Harvey021
NXP TechSupport
NXP TechSupport

Hi @craigmcqueenir 

I happened to be having bsp5.4.47 and can see them as below. 

recipes: 

./meta-imx/meta-bsp/recipes-security/smw/keyctl-caam_git.bb

packages: 

./build/tmp/deploy/images/imx8mmevk/keyctl_caam/caam-keygen
./build/tmp/deploy/images/imx8mmevk/keyctl_caam/caam-keygen.h
./build/tmp/deploy/images/imx8mmevk/keyctl_caam/caam-keygen.c
./build/tmp/deploy/images/imx8mmevk/keyctl_caam/caam-keygen_priv.h
./build/tmp/deploy/images/imx8mmevk/keyctl_caam/caam-keygen.o

 

Best regards

Harvey

1,892 Views
craigmcqueenir
Contributor IV

Thanks, it's good to know about meta-imx.

I've been using meta-freescale. It's not clear to me what is the provenance and scope of each of these Yocto layers.

0 Kudos
Reply

1,885 Views
Harvey021
NXP TechSupport
NXP TechSupport

Hi 

meta-freescale provides support for the base and for i.MX Arm reference boards.

meta-imx provides updates for meta-freescale, poky and others, and other sub-layers.

You can get more details from Yocto User Guide.

Best regards

Harvey

0 Kudos
Reply