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

stm32h7\stm32_fdcan_sock: reserve space for timeval struct in the int… #7194

Merged
merged 1 commit into from Sep 26, 2022

Conversation

rajvindervirk
Copy link
Contributor

…ermediate storage of tx and rx CAN frames when timestamp is enabled

Summary

When CONFIG_NET_TIMESTAMP is enabled, can_callback() concatenates a timestamp timeval to the receive frame in the rx_pool buffer. stm32h7 does not reserve space for the extra timeval structure in the rx_pool when timestamp is enabled.

Impact

This causes a buffer overflow in the receive buffer (rx_pool).

Testing

Tested functionality on STM32H7 board with both CAN instances initialized and buffer overflow is fixed after the change.

…ermediate storage of tx and rx CAN frames when timestamp is enabled
@acassis
Copy link
Contributor

acassis commented Sep 26, 2022

Great finding @rajvindervirk

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

None yet

2 participants