casaroli opened a new pull request, #4184:
URL: https://github.com/apache/nuttx-apps/pull/4184

   ## Summary
   
   The interrupt stack test in ostest tests `CONFIG_ARCH_INTERRUPTSTACK > 3` in 
an `#if` without `defined()`. A configuration with SMP and STACK_COLORATION but 
no interrupt stack does not define the option. With `-Werror=undef` the build 
of `sim:smp` then fails in `intstack.c:38`. Fixes the -Werror=undef build of 
sim:smp after apache/nuttx-apps#3982.
   
   The fix adds `defined(CONFIG_ARCH_INTERRUPTSTACK) &&` to the guard in 
`intstack.c` and to the same guard in `ostest_main.c`. The test stays disabled 
when the option is absent, as before.
   
   ## Impact
   
   Build fix for a test. No change when `CONFIG_ARCH_INTERRUPTSTACK` is 
defined. No runtime, API or Kconfig change. No other file uses the option in 
`testing/ostest`.
   
   ## Testing
   
   Host: Linux x86_64, NuttX CI image (`apache-nuttx-ci-linux`), `make 
EXTRAFLAGS=-Werror=undef`, nuttx and nuttx-apps master.
   
   - sim:smp, before: fails with `intstack.c:38:41: error: 
"CONFIG_ARCH_INTERRUPTSTACK" is not defined, evaluates to 0`.
   - sim:smp, after: builds, no warning.
   - qemu-armv8a:nsh_smp (option set to 8192), before and after: builds, no 
warning. `intstack_test` is still in the image after the fix (checked with 
`nm`).
   - sim:smp with TESTING_OSTEST enabled, after: builds, no warning.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to