-
Notifications
You must be signed in to change notification settings - Fork 7.3k
net: ip: Frequent 4G/5G switching triggers rs_timeout infinite loop, causing WDT exception #77325
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
Comments
Hi @AndyKauo! We appreciate you submitting your first issue for our open-source project. 🌟 Even though I'm a bot, I can assure you that the whole community is genuinely grateful for your time and effort. 🤖💙 |
Could you please send a PR having this solution as it is a more general one. |
Thank you for your feedback and for accepting my suggestion. I would love to submit a pull request with the proposed changes. However, due to firewall restrictions on my company's network, I am currently unable to create a PR. I will need to wait until the weekend to upload the changes from home. |
Hi @jukkar @rlubos #define Z_GENLIST_APPEND(__lname, __nname) \
static inline void \
sys_ ## __lname ## _append(sys_ ## __lname ## _t *list, \
sys_ ## __nname ## _t *node) \
{ \
z_ ## __nname ## _next_set(node, NULL); \
\
if (sys_ ## __lname ## _peek_tail(list) == NULL) { \
z_ ## __lname ## _tail_set(list, node); \
z_ ## __lname ## _head_set(list, node); \
+ } else if (sys_ ## __lname ## _peek_tail(list) != node) { \
z_ ## __nname ## _next_set( \
sys_ ## __lname ## _peek_tail(list), \
node); \
z_ ## __lname ## _tail_set(list, node); \
} \
} |
Can't you submit the PR using HTTP endpoint in github i.e., having https://github.com./zephyrproject-rtos/zephyr.git as a git remote repo address? You can access github web UI so that URL should work ok. As a last resort, we can certainly help, but it would be really good if you could do this yourself. |
Is your enhancement proposal related to a problem? Please describe.
The process of frequently switching between 4G and 5G triggers network interface up and down events, as well as initiates the RSRA flow of IPv6. When the network interface goes up, the function net_if_start_rs() appends
rs_node
to the list using sys_slist_append. However, it may add the same node to the linked list multiple times (rs_node = rs_node.next
), becauseZ_GENLIST_APPEND
does not check if the samers_node
is already added, resulting in an infinite loop in rs_timeout() innet_if.c
.Links to relevant code:
net_if_start_rs()
net_if.c: L1489sys_slist_append
innet_if_start_rs()
net_if.c: L1510Z_GENLIST_APPEND
list_gen.h: L95rs_timeout()
net_if.c: L1464Describe the solution you'd like
There are two solutions as follows:
net_if_stop_rs(iface)
at the end. This ensures the corresponding node is removed.The text was updated successfully, but these errors were encountered: