Commit Graph

2 Commits

Author SHA1 Message Date
deadprogram a7626e87e9 esp32c6: prepare target for espradio WiFi support
The ESP32-C6 target was never built with a radio blob in mind. Three gaps
in targets/esp32c6.ld prevented espradio from linking or running:

- The Espressif WiFi/PHY libraries resolve ~245 internal symbols against
  the mask ROM. Only seven ROM symbols were defined. Add the ESP-IDF
  generated ROM interface tables (1201 symbols), all as PROVIDE() so any
  real definition in the program wins over the ROM copy.
- The .iram output section did not collect the blob IRAM sections
  (.wifi0iram, .wifirxiram, .wifislpiram, .wifislprxiram, .wifiextrairam,
  .wifiorslpiram, .coexiram, .iram1). Without them that code lands in
  flash and crashes when called from an interrupt.
- _heap_end ran to the end of SRAM at 0x40880000, over the mask ROM stack
  and ROM data. phy_param_rom sits at 0x4087fce8, inside that range, so a
  growing Go heap would corrupt the PHY. Cap the heap at 0x4087C610.

Also add the espradio build tag to esp32c6.json, matching esp32c3.json
and esp32s3.json.

Signed-off-by: Ron Evans <ron@hybridgroup.com>
2026-08-29 19:30:41 +02:00
deadprogram 5f66260c3a machine,targets: add minimal esp32c6 implementation
This adds a minimal esp32c6 implementation, currently only
supporting the examples/serial and examples/blinky1 programs.
It does correctly output the expected "Hello, World" via the
serial port, as well as blink the onboard LED.

In addition, it adds support for the PLIC based IRQ handling
as used on the ESP32C6 processor.

Some parts of this code are loosely based on PR #5252 and #5248

Signed-off-by: deadprogram <ron@hybridgroup.com>
2026-06-25 19:30:24 +02:00