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

[Bug] Build breaks on Zephyr RTOS v3.4.0 #229

Closed
entire opened this issue Jul 6, 2023 · 6 comments · Fixed by #230
Closed

[Bug] Build breaks on Zephyr RTOS v3.4.0 #229

entire opened this issue Jul 6, 2023 · 6 comments · Fixed by #230
Labels

Comments

@entire
Copy link

entire commented Jul 6, 2023

Describe the bug

Seems like there was a change that breaks zenoh-pico/src/system/zephyr/network.c in the network interface APIs, since Zephyr v3.4.0 (https://docs.zephyrproject.org/latest/releases/release-notes-3.4.html) it now takes additional, struct net_if * iface parameter:

:c:func:net_if_ipv4_maddr_join
:c:func:net_if_ipv4_maddr_leave
:c:func:net_if_ipv6_maddr_join
:c:func:net_if_ipv6_maddr_leave

It works with Zephyr RTOS v3.3.0 before the change was made.

To reproduce

System info

  • MacOS 13.3.1 Ventura (Mac M1)
  • Zephyr RTOS v3.4.0
  • Zenoh-pico 0.7.2
@entire entire added the bug Something isn't working label Jul 6, 2023
@cguimaraes
Copy link
Member

Thanks for reporting it.
At this point, we shall support:

  • Zephyr 2(.7.0+) as the LTS release
  • Zephyr 3.3.0 and below
  • Zephyr 3.4.0 and above

@entire Do you know if there is any Zephyr environment variable that can be used at compile time to identify the version?

@cguimaraes cguimaraes added platfoms and removed bug Something isn't working labels Jul 6, 2023
@bryceschober
Copy link
Contributor

@cguimaraes See https://docs.zephyrproject.org/latest/doxygen/html/kernel__version_8h.html

@bryceschober
Copy link
Contributor

@cguimaraes It looks like the low-level "interface" is to #include "versio.h", whose contents are generated by (and documented in) the version.cmake file (2.7, 3.3-main).

@cguimaraes
Copy link
Member

Thank you @bryceschober for the input. It was very helpful to improve the Zephyr version detection within Zenoh-Pico.

There is a partial fix for this issue, until the new Zephyr multicast API is integrated: #230

@entire if this is a blocking point for you but you do not need Zenoh multicast transport, you might want to set Z_LINK_UDP_MULTICAST to 0.

@cguimaraes
Copy link
Member

#230 contains now a complete fix for it.
Missing proper testing before merging.

@entire could you help us testing it on your setup?

cguimaraes added a commit that referenced this issue Jul 26, 2023
* Improve Zephyr version detection

* Support the new Zephyr multicast API

* Reuse ifa variable
@entire
Copy link
Author

entire commented Aug 23, 2023

seems to work, thanks! @cguimaraes

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

Successfully merging a pull request may close this issue.

3 participants