Skip to content

Commit

Permalink
remoteproc: do cache invalidation before reading rsc_table status
Browse files Browse the repository at this point in the history
Do a cache invalidation before reading the resource table's status
since this ca be in a cacheable region.

Signed-off-by: Iuliana Prodan <[email protected]>
  • Loading branch information
iuliana-prodan committed Jul 12, 2023
1 parent 7f90610 commit 146f72b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/remoteproc/remoteproc_virtio.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ static unsigned char rproc_virtio_get_status(struct virtio_device *vdev)
rpvdev = metal_container_of(vdev, struct remoteproc_virtio, vdev);
vdev_rsc = rpvdev->vdev_rsc;
io = rpvdev->vdev_rsc_io;
metal_cache_invalidate(vdev_rsc, sizeof(vdev_rsc));
status = metal_io_read8(io,
metal_io_virt_to_offset(io, &vdev_rsc->status));
return status;
Expand Down

0 comments on commit 146f72b

Please sign in to comment.