Skip to content

Commit

Permalink
upl: fix parsing of DT property
Browse files Browse the repository at this point in the history
When calling decode_addr_size() we must pass the size of the device-tree
property and not sizeof(void *).

Fixes: 90469da ("upl: Add support for reading a upl handoff")
Addresses-Coverity-ID: 510459 Wrong sizeof argument
Signed-off-by: Heinrich Schuchardt <[email protected]>
  • Loading branch information
xypron authored and trini committed Nov 15, 2024
1 parent 504f36e commit b891826
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion boot/upl_read.c
Original file line number Diff line number Diff line change
Expand Up @@ -520,7 +520,7 @@ static int decode_upl_graphics(struct upl *upl, ofnode node)
return log_msg_ret("reg", -EINVAL);
}

len = decode_addr_size(upl, buf, sizeof(buf), &gra->reg);
len = decode_addr_size(upl, buf, size, &gra->reg);
if (len < 0)
return log_msg_ret("buf", len);

Expand Down

0 comments on commit b891826

Please sign in to comment.