mirror of
https://github.com/AsahiLinux/u-boot
synced 2025-02-16 14:08:45 +00:00
crypto: fsl: blob: Flush dcache range for destination address
The blob command is not working on i.MX7D, i.MX8MQ and i.MX8MM devices. Due to different cache management it's necessary to flush dcache range for destination address so data can be available in memory. Add necessary operations in blob_encap() and blob_decap() functions. Signed-off-by: Breno Lima <breno.lima@nxp.com> Reviewed-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com>
This commit is contained in:
parent
2c0dcc5de6
commit
a30798113c
1 changed files with 6 additions and 0 deletions
|
@ -65,6 +65,9 @@ int blob_decap(u8 *key_mod, u8 *src, u8 *dst, u32 len)
|
|||
flush_dcache_range((unsigned long)desc,
|
||||
(unsigned long)desc + size);
|
||||
|
||||
flush_dcache_range((unsigned long)dst,
|
||||
(unsigned long)dst + size);
|
||||
|
||||
ret = run_descriptor_jr(desc);
|
||||
|
||||
if (ret) {
|
||||
|
@ -130,6 +133,9 @@ int blob_encap(u8 *key_mod, u8 *src, u8 *dst, u32 len)
|
|||
flush_dcache_range((unsigned long)desc,
|
||||
(unsigned long)desc + size);
|
||||
|
||||
flush_dcache_range((unsigned long)dst,
|
||||
(unsigned long)dst + size);
|
||||
|
||||
ret = run_descriptor_jr(desc);
|
||||
|
||||
if (ret) {
|
||||
|
|
Loading…
Add table
Reference in a new issue