Closed ewoodev closed 1 month ago
os/kernel/semaphore: Change ARCH_GET_RET_ADDRESS __builtin_return_add… …ress(0) Changes the use of __builtin_return_address() in semaphore to check for callers.
Could you leave why?
I added description in commit description
When a memory is alloc, we store the caller address requested by which code. However, if we wrap the alloc api and use it, the caller only looks at the wrapped api.
Therefore, we apply the DEBUG_SET_CALLER_ADDR macro to actually store the caller's address in alloc.