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

CPU1 crash in certain SDK functions due to CPU2 crash #100

Open
tim-nordell-nimbelink opened this issue Aug 23, 2024 · 1 comment
Open
Assignees
Labels
ble Bluetooth Low Energy bug Something isn't working internal bug tracker Issue confirmed and logged into the internal bug tracking system mw Middleware-related issue or pull-request.

Comments

@tim-nordell-nimbelink
Copy link

tim-nordell-nimbelink commented Aug 23, 2024

The default placement of TL_Reftable causes CPU2 to overwrite the p_device_info_table, p_ble_table, p_thread_table, and p_sys_table variables within TL_Reftable when CPU2 crashes. The SDK code does not check for the crash condition from CPU2 and happily dereferences the values that CPU2 placed into this table causing CPU1 to crash. For instance, if CPU2 has crashed, invoking SHCI_GetWirelessFwInfo(...) from CPU1 will cause CPU1 to crash from this dereference.

I'd suggest that each usage of the pointers within TL_Reftable should check if one of the magic values that indicates a crash from CPU2 has been written to the top of SRAM2 before dereferencing these (potentially invalid) pointers.

Reproduction involves causing CPU2 to crash, and then invoking one of the functions that dereferences the pointers from TL_Reftable such as (but not limited to) SHCI_GetWirelessFwInfo(...).

@RJMSTM
Copy link
Contributor

RJMSTM commented Aug 27, 2024

ST Internal Reference: 189571

@RJMSTM RJMSTM added bug Something isn't working internal bug tracker Issue confirmed and logged into the internal bug tracking system ble Bluetooth Low Energy labels Aug 27, 2024
@ALABSTM ALABSTM added the mw Middleware-related issue or pull-request. label Sep 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ble Bluetooth Low Energy bug Something isn't working internal bug tracker Issue confirmed and logged into the internal bug tracking system mw Middleware-related issue or pull-request.
Projects
Development

No branches or pull requests

3 participants