firmware: scmi: Fix clearing variable

The sess variable in open_channel was not entirely
cleared to zero at the start of this function.

This commit ensures that the entire struct is cleared.

Signed-off-by: Francois Berder <fberder@outlook.fr>
This commit is contained in:
Francois Berder 2023-10-10 19:44:32 +02:00 committed by Tom Rini
parent 8057d8a66f
commit 66abf2bba3

View File

@ -149,7 +149,7 @@ static int open_channel(struct udevice *dev, struct scmi_optee_channel *chan,
struct tee_param param[1] = { };
int ret;
memset(sess, 0, sizeof(sess));
memset(sess, 0, sizeof(*sess));
sess->tee = tee_find_device(NULL, NULL, NULL, NULL);
if (!sess->tee)