riscv-software-src / riscv-software-src/opensbi
riscv_encoding.h: redefinition issue
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 1.5k
- Forks
- 712
- PR merge metrics
- No merged PRs in 30d
Description
During integration with Apache NuttX RTOS we faced an issue that many warning about redefinition of values from riscv_encoding.h. The definitions with the same name are present in RTOS arch header files so both can't be included in a single compilation unit.
Maybe it is a good idea to add SBI_ or OPENSBI_ prefix to defines in riscv_encoding.h? Or any other proposals this can be solved?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing riscv_encoding.h and the RISC-V architecture headers in Apache NuttX that define the same names. Determine a naming or inclusion approach that avoids redefinition when both headers are included, then verify that an integration compilation unit no longer emits redefinition warnings.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100