tmedicci opened a new pull request, #15910:
URL: https://github.com/apache/nuttx/pull/15910

   ## Summary
   
   * arch/risc-v: Add ARCH_HAVE_RAMFUNCS to ESP32-C6 and ESP32-H2
   
   Following the https://github.com/apache/nuttx/pull/14741, add the 
`ARCH_HAVE_RAMFUNCS` config to ESP32-C6 and ESP32-H2 to suppress the RWX memory 
region warning.
   
   Signed-off-by: Tiago Medicci Serrano <tiago.medi...@espressif.com>
   
   ## Impact
   
   Impact on user: NO.
   
   Impact on build: YES. Suppress a warning during the build and prevent it 
from being understood incorrectly.
   
   Impact on hardware: NO.
   
   Impact on documentation: NO.
   
   Impact on security: NO.
   
   Impact on compatibility: NO.
   
   ## Testing
   
   Just build any defconfig for these two chips and check for the warning 
message:
   
   ```
   riscv-none-elf-ld: warning: 
/home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/nuttx/nuttx has 
a LOAD segment with RWX permissions
   ```
   
   For instance, `esp32h2-devkit:nsh`
   
   ### Building
   
   ```
   make -j distclean && ./tools/configure.sh esp32h2-devkit:nsh && make 
-j$(nproc)
   ```
   
   ### Results
   
   Before this patch, the build log shows the warning message:
   ```
   LD: nuttx
   riscv-none-elf-ld: warning: 
/home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/nuttx/nuttx has 
a LOAD segment with RWX permissions
   Memory region         Used Size  Region Size  %age Used
                ROM:      240761 B        16 MB      1.44%
        iram0_0_seg:       17168 B     258000 B      6.65%
           irom_seg:      117748 B        16 MB      0.70%
        dram0_0_seg:       27840 B     258000 B     10.79%
           drom_seg:      175228 B        16 MB      1.04%
         lp_ram_seg:          0 GB       4072 B      0.00%
    lp_reserved_seg:          0 GB         24 B      0.00%
   CP: nuttx.hex
   ```
   
   After this patch, the warning message is gone:
   ```
   LD: nuttx
   Memory region         Used Size  Region Size  %age Used
                ROM:      240761 B        16 MB      1.44%
        iram0_0_seg:       17168 B     258000 B      6.65%
           irom_seg:      117748 B        16 MB      0.70%
        dram0_0_seg:       27840 B     258000 B     10.79%
           drom_seg:      175228 B        16 MB      1.04%
         lp_ram_seg:          0 GB       4072 B      0.00%
    lp_reserved_seg:          0 GB         24 B      0.00%
   CP: nuttx.hex
   ```


-- 
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: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to