FreeRTOS / FreeRTOS-Kernel

FreeRTOS kernel files only, submoduled into https://github.com/FreeRTOS/FreeRTOS and various other repos.
https://www.FreeRTOS.org
MIT License
2.76k stars 1.12k forks source link

[Feature Request] Add portMEMORY_BARRIER definition for Renesas RX MCU #854

Closed YuichiNakadaSX closed 11 months ago

YuichiNakadaSX commented 1 year ago

We have confirmed that the demo does not work correctly when optimizing with the compiler on Renesas RX MCU. The PortMEMORY_BARRIER definition must be added to portmacro.h.

Confirmed phenomenon

The demo does not work correctly under the following conditions:

When it runs the demo, it loops infinitely in xTaskResumeAll in tasks.c.

Solution (request for this issue)

Add portMEMORY_BARRIER definition to portmacro.h as follows:

Target

All series of Renesas RX.

ActoryOu commented 1 year ago

Hi @YuichiNakadaSX, Thanks for reporting this to us. Would you like to create PR to contribute the solution you mentioned?

YuichiNakadaSX commented 1 year ago

Hi @ActoryOu, Thank you for your comment. I am sorry that I am not able to PR about this because I need some paperwork if I do PR. Could you please update it on your side?

Skptak commented 1 year ago

Hey @YuichiNakadaSX, can you please validate if #864 is the exact set of changes you are looking for?

Thanks

TakeoTakahashi2020 commented 12 months ago

Hi @Skptak, thank you very much for your PR. I have confirmed your #864 code on @YuichiNakadaSX behalf.

BTW, inline assemble code in your portmacro.h had to be corrected which caused compile errror. The inline assemble code format seems to be broken by uncrustify. Each port.c in portable/Renesas/RX* also has same issue.

Could you please fix the inline assemble code and add /* *INDENT-OFF* */ and /* *INDENT-ON* */ as below to avoid compile errror issue.

image

Left code is your original code. Right code is fixed and INDENT-OFF/INDENT-ON is added.

Skptak commented 12 months ago

Hey @TakeoTakahashi2020 I've raised #876 to fix the formatting issues Once that is approved and merged I'll fix the changes on this PR

Thanks

TakeoTakahashi2020 commented 11 months ago

Hi @Skptak san,

I have confirmed #876. Thank you very much.

Once that is approved and merged I'll fix the changes on this PR

Understood.

Thanks.

Skptak commented 11 months ago

Hey @TakeoTakahashi2020, #864 has been merged into the mainline kernel, I'm going to mark this issue as closed now Please feel free to create a new issue if you need anything else!

TakeoTakahashi2020 commented 11 months ago

Hi @Skptak san, I confirmecd that #876 and #864 have been merged. Thank you very much!