Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rpmsg_virtio: Move get RX buffer into receive loop and returned buffer kick to common location #585

Merged
merged 2 commits into from
May 16, 2024

Conversation

glneo
Copy link
Contributor

@glneo glneo commented Apr 25, 2024

No description provided.

@arnopo arnopo requested review from edmooring, arnopo and tnmysh May 3, 2024 14:24
Copy link
Collaborator

@tnmysh tnmysh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should have
no functional change but prepares for a later bug fix.

As commit message says this is needed for bug fix, then this change can be squashed in same commit where actual bug is fixed.

@glneo
Copy link
Contributor Author

glneo commented May 7, 2024

Okay, the bug fix I have in mind has a few more dependencies so for now I'll remove that part of the commit message. The patch should stand on its own just the same.

After returning a buffer we kick the other side. This is done after both
call sites of the function that returns the buffer. Move this kick call
into that function to reduce code duplication and prevent it from not
being done after returning the buffer.

Signed-off-by: Andrew Davis <afd@ti.com>
Copy link
Collaborator

@arnopo arnopo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor remark else LGTM

lib/rpmsg/rpmsg_virtio.c Outdated Show resolved Hide resolved
This allows us to only need to call rpmsg_virtio_get_rx_buffer() once
at the start of the loop and is easier to comprehend.

Signed-off-by: Andrew Davis <afd@ti.com>
Copy link
Collaborator

@tnmysh tnmysh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@arnopo arnopo merged commit bf87228 into OpenAMP:main May 16, 2024
3 checks passed
@arnopo arnopo added this to the Release V2024.05 milestone May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants