Browse Source

fix(k3): increment while reading trail bytes

The trail bytes from the secure proxy driver were being overwritten,
increase the count each time to not overwrite the existing data and not
get the end data corrupted from secure proxy.

Fixes: d76fdd33e0 ("ti: k3: drivers: Add Secure Proxy driver")

Change-Id: I8e23f8b6959da886d6ab43049746f78765ae1766
Signed-off-by: Manorit Chawdhry <m-chawdhry@ti.com>
pull/1999/merge
Manorit Chawdhry 10 months ago
parent
commit
0bdaf5c804
  1. 2
      plat/ti/k3/common/drivers/sec_proxy/sec_proxy.c

2
plat/ti/k3/common/drivers/sec_proxy/sec_proxy.c

@ -320,7 +320,7 @@ int k3_sec_proxy_recv(enum k3_sec_proxy_chan_id id, struct k3_sec_proxy_msg *msg
i = msg->len - trail_bytes;
while (trail_bytes--) {
msg->buf[i] = data_trail & 0xff;
msg->buf[i++] = data_trail & 0xff;
data_trail >>= 8;
}
}

Loading…
Cancel
Save