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

CMSIS-compatible ARM Cortex-M ports #1

Closed
wants to merge 2 commits into from

Conversation

quantum-leaps
Copy link

The ARM Cortex-M ports (Ports/ARM-Cortex-M directory) have been modified to comply with CMSIS. Specifically, the PendSV and SysTick exception handlers have been renamed to the CMSIS-compliant names PendSV_Handler (originally was OS_CPU_PendSVHandler) and SysTick_Handler (originally was OS_CPU_SysTickHandler). This change is necessary for the uC/OS-II applications to be able to use the CMSIS-compliant startup code.

@quantum-leaps
Copy link
Author

Updated some assembly files in the ARMv6-M directory.

@cwoodall
Copy link

@quantum-leaps under what conditions i this necessary? I just installed these handlers manually (by creating them locally and then calling these C functions). that is obviously not very efficient.

@quantum-leaps
Copy link
Author

Hi Christopher,
I'm not sure your question as to "under what conditions i this necessary?".

The unmodified uC/OS-II ports to ARM Cortex-M use names for exceptions and IRQs that are NOT conformant with CMSIS. Specifically, CMSIS requires that the handler for the PendSV exception be named PendSV_Handler.

So, my change is all about compliance with the CMSIS standard. This, in turn, allows the uC/OS-II ports to ARM Cortex-M be usable with the CMSIS-compliant startup code, which provides CMSIS-compliant interrupt vector table.

I hope that my comments make sense to you.

--Miro

@forg0ne
Copy link
Member

forg0ne commented Mar 17, 2021

This approach can break backwards compatibility with existing projects.
I'd recommend adding a new label to the asm files, and a wrapper for the C functions.
This will give you CMSIS compatibility without breaking projects that use the existing name.

@forg0ne
Copy link
Member

forg0ne commented Mar 17, 2021

Additionally, the merge target should be develop, not master.

@wes-jmagasrevy wes-jmagasrevy changed the base branch from master to develop April 27, 2021 14:45
Copy link
Member

@forg0ne forg0ne left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This approach can break backwards compatibility with existing projects that use the old handlers.
We cannot merge these changes while this is a concern.
Please review my comment about how to add CMSIS compatibility while maintaining backwards compatibility.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add CMSIS compliant name for PendSV and Systick for Cortex-M ports
3 participants