erpc icon indicating copy to clipboard operation
erpc copied to clipboard

Fix linking error on FreeRTOS when using portYIELD_FROM_ISR

Open Thom747 opened this issue 1 year ago • 1 comments

Pull request

Choose Correct

  • [x] bug
  • [ ] feature

Describe the pull request

The portYIELD_FROM_ISR() macro declares a variable called ulPortYieldRequired. FreeRTOS assumes ulPortYieldRequired is in the global namespace. To prevent linking errors, this PR introduces a function in the global namespace called ErpcPortYieldFromISR that then calls portYIELD_FROM_ISR().

To Reproduce

Build eRPC with FreeRTOS.

Expected behavior

eRPC builds as normal.

Desktop (please complete the following information):

  • OS: Ubuntu 20.04
  • eRPC Version: v1.12.0 and earlier

Steps you didn't forgot to do

  • [x] I checked if other PR isn't solving this issue.
  • [x] I read Contribution details and did appropriate actions.
  • [x] PR code is tested.
  • [x] PR code is formatted.
  • [x] Allow edits from maintainers pull request option is set (recommended).

Thom747 avatar Mar 05 '24 12:03 Thom747