Commit 6d63ee6c authored by Marek Vasut's avatar Marek Vasut
Browse files

mxssb: No need to reinit sctx twice in sb_create_image



The variable was initialized and reinitialized twice as a remnant
of the rework, initialize it only once.
Signed-off-by: Marek Vasut's avatarMarek Vasut <marex@denx.de>
parent 98dba2c3
......@@ -380,12 +380,10 @@ static int sb_create_image(struct sb_image_ctx *ictx)
sb_aes_init(ictx, NULL);
sb_encrypt_sb_header(ictx);
/*
* SB sections header.
*/
uint8_t sb_section_header_cbc_mac[sizeof(struct sb_key_dictionary_key)];
struct sb_section_ctx *sctx = ictx->sect;
sb_encrypt_sb_sections_header(ictx, sb_section_header_cbc_mac);
......@@ -401,7 +399,7 @@ static int sb_create_image(struct sb_image_ctx *ictx)
*/
struct sb_cmd_ctx *cctx;
struct sb_command *ccmd;
sctx = ictx->sect;
struct sb_section_ctx *sctx = ictx->sect;
while (sctx) {
cctx = sctx->cmd;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment