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: supress broken rpmsg_init_ept API #220

Closed
arnopo opened this issue Oct 5, 2020 · 2 comments · Fixed by #221
Closed

rpmsg: supress broken rpmsg_init_ept API #220

arnopo opened this issue Oct 5, 2020 · 2 comments · Fixed by #221
Assignees

Comments

@arnopo
Copy link
Collaborator

arnopo commented Oct 5, 2020

The rpmsg_init_ept does not seem to be usable by application but is used internally. The proposal is to mark this API deprecated API and in at least two full release, to remove this API as the standard API to use is rpmsg_create_ept.
In parallel, the online function must be moved to rpmsg_internal.h

Issue entered in reference to :

@arnopo
Copy link
Collaborator Author

arnopo commented Oct 5, 2020

Hi @ed,
Proposal is to use similar mechanism as one used in zephyr (https://docs.zephyrproject.org/latest/development_process/api_lifecycle.html)
Introducing the deprecated attribute ( supported by gcc and IAR) allows to continue to use the API, but with a warning at compilation time:
warning: ‘rpmsg_init_ept’ is deprecated [-Wdeprecated-declarations]

To deprecate a function we just need to update the function declaration in the API header:

-static inline void rpmsg_init_ept(struct rpmsg_endpoint *ept,
+__deprecated static inline void rpmsg_init_ept(struct rpmsg_endpoint *ept,

and the "-Wno-deprecated-declarations" compilation option can disable the warning on need.

What is your feeling about this solution?
i plan to send associated PR tomorrow if this looks good to you.

@edmooring
Copy link
Contributor

Hi @arnopo,
This seems to me to be a good solution.

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 a pull request may close this issue.

2 participants