Hi @Sai I'm glad that you were able to resolve your issue and thank you for posting your work around so that others experiencing the same thing can easily reference this! Since the Microsoft Q&A community has a policy that "The question author cannot accept their own answer. They can only accept answers by others ", I'll repost your solution in case you'd like to accept the answer .
Error Message:
HardFault occurs when run the example. The assembly instruction generates HardFault is "bx lr" in _skip_secure_restore()
Solution:
Bug caused by not booting with secure status. Adding "-DTX_SINGLE_MODE_NON_SECURE" helped to work around the issue.
If I missed anything please let me know and I'd be happy to add it to my answer, or feel free to comment below with any additional information.
I hope this helps!
If you have any other questions, please let me know. Thank you again for your time and patience throughout this issue.
If the response helped, please do click Accept Answer and Yes for the answer provided. Doing so would help other community members with similar issue identify the solution. I highly appreciate your contribution to the community.