Skip to content

Minimal HUK implementation without full CAAM driver#3160

Closed
Emantor wants to merge 10 commits intoOP-TEE:masterfrom
Emantor:topic/caam_huk
Closed

Minimal HUK implementation without full CAAM driver#3160
Emantor wants to merge 10 commits intoOP-TEE:masterfrom
Emantor:topic/caam_huk

Conversation

@Emantor
Copy link
Copy Markdown
Contributor

@Emantor Emantor commented Jul 31, 2019

This PR implements a minimal implementation to retrieve a Master Key Verification Blob (MKVB) from the CAAM inside of i.MX processors for use as a Hardware Unique Key (HUK). In contrast to the full CAAM implementation offered by NXP, this only implements the necessary bits to retrieve MKVB once, does not allocate job rings to the secure world and has no conflicts with the linux kernel CAAM driver, since the CAAM is not accessed after the MKVB is retrieved.
Things I'm not sure about:

  • Access through the structs to the registers:
    I followed the style implemented by @bryanodonoghue, it may be more readable to switch to a normal #define based register access model

Related:
#2892 - initial i.MX HUK issue
#3149 - full NXP CAAM driver

@Emantor Emantor force-pushed the topic/caam_huk branch 2 times, most recently from e182156 to fe8393e Compare July 31, 2019 07:32
Copy link
Copy Markdown
Contributor

@jforissier jforissier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewing "imx: enable CAAM clocks before accessing registers"

Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.h Outdated
Copy link
Copy Markdown
Contributor

@jforissier jforissier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor comments on "imx_caam: implement tee_otp_get_hw_unique_key".

Please add parentheses to function name in commit subject: tee_otp_get_hw_unique_key()

Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
@Emantor
Copy link
Copy Markdown
Contributor Author

Emantor commented Jul 31, 2019

I have a rebased version against the recent master commits and will squash the review commits and suggested changes from @jforissier at the same time on the next push.

Copy link
Copy Markdown
Contributor

@etienne-lms etienne-lms left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minor comments for "imx: enable CAAM clocks before accessing registers".

Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Copy link
Copy Markdown
Contributor

@etienne-lms etienne-lms left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Acked-by: Etienne Carriere <[email protected]> with minor comment.

Comment thread core/arch/arm/plat-imx/imx_caam.h Outdated
Copy link
Copy Markdown
Contributor

@etienne-lms etienne-lms left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

comment for commit "plat-imx: register definitions for CAAM".

Comment thread core/arch/arm/plat-imx/imx_caam.h Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.h Outdated
Copy link
Copy Markdown
Contributor

@etienne-lms etienne-lms left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

comments on commit "imx_caam: implement tee_otp_get_hw_unique_key"

Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/imx_caam.c Outdated
Copy link
Copy Markdown
Contributor

@etienne-lms etienne-lms left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For commit "imx_caam: add functions for jr init and reset":
Can remove following sentence from commit message: "Will be used by the tee_otp_get_hw_unique key implementation in the next commit."

Emantor added 4 commits August 1, 2019 15:15
The CAAM clocks need to be enabled, otherwise access to the CAAM might
result in a bus stall.

Signed-off-by: Rouven Czerwinski <[email protected]>
Add __attribute__((packed)) to the CAAM struct definitions to ensure the
compiler does not insert padding into the structures.

Signed-off-by: Rouven Czerwinski <[email protected]>
Register Definitions in the same style as used by the jobring allocation
code, by extending the structure definitions and inserting padding if
the registers are undocumented.

Signed-off-by: Rouven Czerwinski <[email protected]>
Minimal implementation for tee_otp_get_hw_unique_key using the Master
Key Verification Blob (MKVB) produced by the CAAM. Only the first 16
bytes are copied into the hw unique key structure, since the MKVB is 32
bytes long.

Signed-off-by: Rouven Czerwinski <[email protected]>
@Emantor Emantor marked this pull request as ready for review August 1, 2019 13:17
@Emantor
Copy link
Copy Markdown
Contributor Author

Emantor commented Aug 1, 2019

I have rebased against latest master and changed to stack allocation. With the alignement within the structure to 64 bytes we should always flush and invalidate the intended date, without hitting stack data above or below. I also tried to incorporated all of the review comments, Thanks @jforissier, @etienne-lms, @jenswi-linaro & @bryanodonoghue. @etienne-lms I did not apply your Ack since I think the code has changed enough to require another review.

Copy link
Copy Markdown
Contributor

@etienne-lms etienne-lms left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for commits "plat-imx: pack caam structs", imx: enable CAAM clocks before accessing registers:

for commit "imx_caam: implement tee_otp_get_hw_unique_key": see comments.

Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c Outdated
Address the review comments from @etienne-lms.

Signed-off-by: Rouven Czerwinski <[email protected]>
@cneveux
Copy link
Copy Markdown
Contributor

cneveux commented Aug 2, 2019

@Emantor

I understand that you want to have the HUK generated with the CAAM but I don't see the interest of bypassing all the work we, NXP, are doing to enable the CAAM driver. In your PR you have to enable the CAAM anyway to use the Job Ring. In plus you have missed a condition that is really needed to be full secure. This is the selection of the master key.

In the driver we want to add and that has been improved and validated on all i.MX devices (taking care of all boot modes). We are doing the same in a more generic way.

Could you explain us what is the added value of your implementation that is a kind of copy of what has been submitted in the PR #3149?

@Emantor
Copy link
Copy Markdown
Contributor Author

Emantor commented Aug 2, 2019

I understand that you want to have the HUK generated with the CAAM but I don't see the interest of bypassing all the work we, NXP, are doing to enable the CAAM driver. In your PR you have to enable the CAAM anyway to use the Job Ring.

I am interested in generating the MKVB for use as a HUK. I am not interested in a CAAM driver implementation, since I don't see the use case for it. The CAAM driver adds a lot of code which increases the TCB for my secure OS. For our use cases a full CAAM driver within OP-TEE is not needed, since we don't require hardware acceleration for the crypto primitives.

In plus you have missed a condition that is really needed to be full secure. This is the selection of the master key.

According to the documentation at hand, the OTPMK is used as the default Master Key CAAM input.
I am well aware that the OTPMK is not available on not HAB-enabled devices and a test key is used.
I'd argue that it does not make much sense to deploy devices without HAB and with OP-TEE.

In the driver we want to add and that has been improved and validated on all i.MX devices (taking care of all boot modes). We are doing the same in a more generic way.
Which is also currently incompatible to the mainline kernel due to possible clock problems. If somebody i.e. decides to add power management to the Linux CAAM driver, OP-TEE will be stuck when trying to access the CAAM. I agree that a solution to the problem exists which is to move the clocks into the secure world. However this requires discussions with the upstream kernel maintainers on how this implementation is going to work.
Could you explain us what is the added value of your implementation that is a kind of copy of what has been submitted in the PR #3149?

  • It adds the required minimum amount of code to derive a HUK for OP-TEE on bootup without requiring a switch of the full crypto implementations to a hardware devices.
  • It allows usage of all CAAM jobrings within Linux
  • The CAAM is not touched after OP-TEE initialization, which eliminates all problems stemming from OP-TEE requiring the CAAM clock to stay enabled.
  • This code can later be refactored to take advantage of the NXP implementations provided in the full CAAM driver.

@ricardosalveti
Copy link
Copy Markdown
Contributor

I also share similar concerns and needs with @Emantor, so I'm also interested at having just the minimum to derive a HUK instead of having the full CAAM support in place.

@Emantor
Copy link
Copy Markdown
Contributor Author

Emantor commented Aug 2, 2019

@dmcilvaney this may also be relevant to your interests for the Microsoft IOT devices.

@cneveux
Copy link
Copy Markdown
Contributor

cneveux commented Aug 5, 2019

@ricardosalveti, @Emantor
Well, thinks is that your are not taking care of all devices and all devices boot mode.
You can not hardcode the number of Job Rings, number is function of device type. You can not assume that JR#0 is always available for the OPTEE at boot time. This is function of the boot mode if there is a previous SW doing the authentication of booting OSes first.
Next we (NXP) are doing the implementation of the CAAM driver to satisfy everybody. This driver is working since long time and this is why we are upstreaming it now. The driver is not so complex and no heavy, the driver is doing the minimum if you don't enable the other crypto algorithm.
What @Emantor did, is just copying the work I submitted and re-write it. If you want to keep this version feel free to keep in your own source tree but please let us push our work that is expected by many customers (directly or not).

Thanks for you understanding.

@Emantor
Copy link
Copy Markdown
Contributor Author

Emantor commented Aug 5, 2019

@ricardosalveti, @Emantor
Well, thinks is that your are not taking care of all devices and all devices boot mode.
You can not hardcode the number of Job Rings, number is function of device type. You can not assume that JR#0 is always available for the OPTEE at boot time. This is function of the boot mode if there is a previous SW doing the authentication of booting OSes first.

I tried to find some documentation on which job ring is actually used by the HAB, but all I could find were discussion on the LKML and U-Boot. Do you have more documentation internally that you could share?

To be clear: this HUK patch breaks the case where your boot chain is SPL->OP-TEE->U-Boot->kernel and U-Boot tries to use HAB to authenticate additional images. Are there similar restrictions on the other job rings? Is the simple solution to switch to job ring 2?

This is a bug in this PR and should consequently be fixed.

Next we (NXP) are doing the implementation of the CAAM driver to satisfy everybody. This driver is working since long time and this is why we are upstreaming it now. The driver is not so complex and no heavy, the driver is doing the minimum if you don't enable the other crypto algorithm.

With a diffstat of +13,804 −62 for the current CAAM HUK patch set I'd call this a lot more complex :-). Of course not all code paths are used, but getting the whole PR reviewed takes time. As an alternative for now I posted this PR.
It also requires currently undocumented device tree changes, i.e. secure-status: okay for the CAAM ctrl node and a job ring.
And your PR notes that it currently can't be used without other PRs which have not been posted yet and makes it quite hard to judge whether the HUK derivation works correctly. IMO the HUK PR can only be reviewed in conjunction with the SNVS patches.

What @Emantor did, is just copying the work I submitted and re-write it. If you want to keep this version feel free to keep in your own source tree but please let us push our work that is expected by many customers (directly or not).

I'm not restricting you ability to push your changes upstream in any way. I'm just proposing a solution for now which is easier to review and test and has no immediate impact on the kernel.

@Emantor
Copy link
Copy Markdown
Contributor Author

Emantor commented Aug 5, 2019

@MrVan any comments on this pull request? This requires your Reviewed-by because of the plat-imx changes.

In order to allow a SPL -> OP-TEE -> U-Boot -> HAB authenticate -> Linux
boot flow, use job ring two instead of one, since one might be used by
the HAB.

Signed-off-by: Rouven Czerwinski <[email protected]>
@Emantor
Copy link
Copy Markdown
Contributor Author

Emantor commented Aug 6, 2019

I pushed a patch which switches to using job ring two, which is the same ring used as by the full caam implementation for the CFG_CAAM_DT=n case.

Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c
Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/drivers/imx_caam.h
Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c
Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c Outdated
Address review comments from @etienne-lms.

Signed-off-by: Rouven Czerwinski <[email protected]>
@Emantor Emantor force-pushed the topic/caam_huk branch 2 times, most recently from a0ee937 to dcb7369 Compare August 7, 2019 05:57
Emantor added 2 commits August 7, 2019 08:40
Handle job ring reset timeouts by passing the return value.

Signed-off-by: Rouven Czerwinski <[email protected]>
Those were forgotten in the previous commits, fix them now.

Signed-off-by: Rouven Czerwinski <[email protected]>
Copy link
Copy Markdown
Contributor

@etienne-lms etienne-lms left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

comments for the 3 last fixup commits

Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c
Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c Outdated
Comment thread core/arch/arm/plat-imx/drivers/imx_caam.c Outdated
Fixes the leftover review comments from @etienne-lms.

Signed-off-by: Rouven Czerwinski <[email protected]>
@Emantor
Copy link
Copy Markdown
Contributor Author

Emantor commented Sep 5, 2019

@etienne-lms, @clementfaure any comments on this? This is a valid minimal implementation which does not require the whole CAAM stack as implemented by NXP, but can be refactored as the necessary NXP commits are added.

@etienne-lms
Copy link
Copy Markdown
Contributor

@Emantor, #3228 is not far from landing. Hence maybe consider refactoring on the P-R to plug HUK over the proposed CAAM support. Should find a way to use only features you need from it.

if (mkvb.jr.outring[0].status != 0)
ret = TEE_ERROR_SECURITY;
goto out;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing { } otherwise it always ends up going to 'goto out'.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this is already addressed in my local branch. I plan to rebase onto the CAAM work, but that might take a bit of refactoring to correctly disable the CAAM driver after HUK generation.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, thanks for the heads up.

uint32_t reg_val = 0;
uint32_t timeout = 1000;

io_write32((vaddr_t)&ctrl->jrcfg[MKVB_JR].jrcr, 1);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be nice that raw value (1 here) at lines 50, 55, 59, ... are replaced with macros, i.e. CAAM_JRCR_xxx BIT(0), CAAM_JRINTR_STATE_MASK GENMASK_32(3, 2), ...


static TEE_Result caam_get_mkvb(uint8_t *dest)
{
struct imx_mkvb mkvb = { 0 };
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minor: prefer { }

return ret;
mkvb_retrieved = true;
}
memcpy(&hwkey->data, &stored_key, sizeof(hwkey->data));
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

prefer add empty line after if() { } block and before last return.

if (!caam)
return TEE_ERROR_GENERIC;

caam_enable_clocks();
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add an empty line below.

do {
reg_val = io_read32((vaddr_t)&ctrl->jrcfg[MKVB_JR].jrintr);
reg_val &= 0xc;
} while ((reg_val & 0x1) && --timeout);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 does not seems the expect value, since mask at line 58.

@github-actions
Copy link
Copy Markdown

This pull request has been marked as stale because it has been open (more than) 30 days with no activity. Remove the stale label or add a comment saying that you would like to have the label removed otherwise this pull request will automatically be closed in 5 days. Note, that you can always re-open a closed pull request at any time.

@github-actions github-actions Bot added the Stale label Jan 10, 2020
@github-actions github-actions Bot closed this Jan 20, 2020
ldts pushed a commit to ldts/optee_os that referenced this pull request Feb 11, 2020
From pull-request OP-TEE#3160

imx: enable CAAM clocks before accessing registers

The CAAM clocks need to be enabled, otherwise access to the CAAM might
result in a bus stall.

Signed-off-by: Rouven Czerwinski <[email protected]>

plat-imx: pack caam structs

Add __attribute__((packed)) to the CAAM struct definitions to ensure the
compiler does not insert padding into the structures.

Signed-off-by: Rouven Czerwinski <[email protected]>

plat-imx: register definitions for CAAM

Register Definitions in the same style as used by the jobring allocation
code, by extending the structure definitions and inserting padding if
the registers are undocumented.

Signed-off-by: Rouven Czerwinski <[email protected]>

imx_caam: implement tee_otp_get_hw_unique_key

Minimal implementation for tee_otp_get_hw_unique_key using the Master
Key Verification Blob (MKVB) produced by the CAAM. Only the first 16
bytes are copied into the hw unique key structure, since the MKVB is 32
bytes long.

Signed-off-by: Rouven Czerwinski <[email protected]>
Signed-off-by: Ricardo Salveti <[email protected]>
ldts pushed a commit to ldts/optee_os that referenced this pull request Feb 17, 2020
From pull-request OP-TEE#3160

imx: enable CAAM clocks before accessing registers

The CAAM clocks need to be enabled, otherwise access to the CAAM might
result in a bus stall.

Signed-off-by: Rouven Czerwinski <[email protected]>

plat-imx: pack caam structs

Add __attribute__((packed)) to the CAAM struct definitions to ensure the
compiler does not insert padding into the structures.

Signed-off-by: Rouven Czerwinski <[email protected]>

plat-imx: register definitions for CAAM

Register Definitions in the same style as used by the jobring allocation
code, by extending the structure definitions and inserting padding if
the registers are undocumented.

Signed-off-by: Rouven Czerwinski <[email protected]>

imx_caam: implement tee_otp_get_hw_unique_key

Minimal implementation for tee_otp_get_hw_unique_key using the Master
Key Verification Blob (MKVB) produced by the CAAM. Only the first 16
bytes are copied into the hw unique key structure, since the MKVB is 32
bytes long.

Signed-off-by: Rouven Czerwinski <[email protected]>
Signed-off-by: Ricardo Salveti <[email protected]>
ldts pushed a commit to ldts/optee_os that referenced this pull request Aug 25, 2020
From pull-request OP-TEE#3160

imx: enable CAAM clocks before accessing registers

The CAAM clocks need to be enabled, otherwise access to the CAAM might
result in a bus stall.

Signed-off-by: Rouven Czerwinski <[email protected]>

plat-imx: pack caam structs

Add __attribute__((packed)) to the CAAM struct definitions to ensure the
compiler does not insert padding into the structures.

Signed-off-by: Rouven Czerwinski <[email protected]>

plat-imx: register definitions for CAAM

Register Definitions in the same style as used by the jobring allocation
code, by extending the structure definitions and inserting padding if
the registers are undocumented.

Signed-off-by: Rouven Czerwinski <[email protected]>

imx_caam: implement tee_otp_get_hw_unique_key

Minimal implementation for tee_otp_get_hw_unique_key using the Master
Key Verification Blob (MKVB) produced by the CAAM. Only the first 16
bytes are copied into the hw unique key structure, since the MKVB is 32
bytes long.

Signed-off-by: Rouven Czerwinski <[email protected]>
Signed-off-by: Ricardo Salveti <[email protected]>
igoropaniuk pushed a commit to igoropaniuk/optee_os that referenced this pull request Feb 24, 2021
From pull-request OP-TEE#3160

imx: enable CAAM clocks before accessing registers

The CAAM clocks need to be enabled, otherwise access to the CAAM might
result in a bus stall.

Signed-off-by: Rouven Czerwinski <[email protected]>

plat-imx: pack caam structs

Add __attribute__((packed)) to the CAAM struct definitions to ensure the
compiler does not insert padding into the structures.

Signed-off-by: Rouven Czerwinski <[email protected]>

plat-imx: register definitions for CAAM

Register Definitions in the same style as used by the jobring allocation
code, by extending the structure definitions and inserting padding if
the registers are undocumented.

Signed-off-by: Rouven Czerwinski <[email protected]>

imx_caam: implement tee_otp_get_hw_unique_key

Minimal implementation for tee_otp_get_hw_unique_key using the Master
Key Verification Blob (MKVB) produced by the CAAM. Only the first 16
bytes are copied into the hw unique key structure, since the MKVB is 32
bytes long.

Signed-off-by: Rouven Czerwinski <[email protected]>
Signed-off-by: Ricardo Salveti <[email protected]>
MrCry0 pushed a commit to MrCry0/optee_os that referenced this pull request May 2, 2022
From pull-request OP-TEE#3160

imx: enable CAAM clocks before accessing registers

The CAAM clocks need to be enabled, otherwise access to the CAAM might
result in a bus stall.

Signed-off-by: Rouven Czerwinski <[email protected]>

plat-imx: pack caam structs

Add __attribute__((packed)) to the CAAM struct definitions to ensure the
compiler does not insert padding into the structures.

Signed-off-by: Rouven Czerwinski <[email protected]>

plat-imx: register definitions for CAAM

Register Definitions in the same style as used by the jobring allocation
code, by extending the structure definitions and inserting padding if
the registers are undocumented.

Signed-off-by: Rouven Czerwinski <[email protected]>

imx_caam: implement tee_otp_get_hw_unique_key

Minimal implementation for tee_otp_get_hw_unique_key using the Master
Key Verification Blob (MKVB) produced by the CAAM. Only the first 16
bytes are copied into the hw unique key structure, since the MKVB is 32
bytes long.

Signed-off-by: Rouven Czerwinski <[email protected]>
Signed-off-by: Ricardo Salveti <[email protected]>
vanmaegima pushed a commit to vanmaegima/optee_os that referenced this pull request Jun 7, 2022
From pull-request OP-TEE#3160

imx: enable CAAM clocks before accessing registers

The CAAM clocks need to be enabled, otherwise access to the CAAM might
result in a bus stall.

Signed-off-by: Rouven Czerwinski <[email protected]>

plat-imx: pack caam structs

Add __attribute__((packed)) to the CAAM struct definitions to ensure the
compiler does not insert padding into the structures.

Signed-off-by: Rouven Czerwinski <[email protected]>

plat-imx: register definitions for CAAM

Register Definitions in the same style as used by the jobring allocation
code, by extending the structure definitions and inserting padding if
the registers are undocumented.

Signed-off-by: Rouven Czerwinski <[email protected]>

imx_caam: implement tee_otp_get_hw_unique_key

Minimal implementation for tee_otp_get_hw_unique_key using the Master
Key Verification Blob (MKVB) produced by the CAAM. Only the first 16
bytes are copied into the hw unique key structure, since the MKVB is 32
bytes long.

Signed-off-by: Rouven Czerwinski <[email protected]>
Signed-off-by: Ricardo Salveti <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants