Skip to content

[Bug]: Discrepancy in __NVIC_PRIO_BITS default value between core_cm4.h and CMSIS-Core Documentation #9

Description

@Yahia-Sameh

Bug Summary

a mismatch between Documentation and Header

Detailed Description

Summary of the Issue

There is a discrepancy between the default value of __NVIC_PRIO_BITS listed in the CMSIS-Core documentation table and the actual default fallback value implemented in core_cm4.h.

Location

  • Documentation: CMSIS-Core (Cortex-M) -> Device Header File <device>.h -> Cortex-M4 core (core_cm4.h) table.
  • Header File: CMSIS/Core/Include/core_cm4.h

Description of Discrepancy

  1. CMSIS Documentation Table: Lists the Default value for __NVIC_PRIO_BITS as 4.
  2. core_cm4.h Header File: Defines the default fallback value as 3U inside the #ifndef block:
    #ifndef __NVIC_PRIO_BITS
      #define __NVIC_PRIO_BITS 3U
      #warning "__NVIC_PRIO_BITS not defined in device header file; using default!"
    #endif

Expected Behavior

No response

Actual Behavior

No response

Environment

No response

Severity

Minor

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingcmsisCMSIS-related issue or pull-request

Type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions