Hi @MichalPrincNXP, from what i see in code i would say that env_init_counter<0 is dead code and rest of code can be rewrtiten to bool logic. Recently i got a knowledge that for global bool knowledge should be used something like https://www.freertos.org/event-groups-API.html.
I may create PR with suggested code if you agree with me.
I am talking about rpmsg_env_freertos.c file.