Skip to content

Segfault Esp32c3 Firmware #583

Open
Open
@BrelJordan

Description

@BrelJordan

Checklist

  • Checked the issue tracker for similar issues to ensure this is not a duplicate
  • Read the documentation to confirm the issue is not addressed there and your configuration is set correctly
  • Tested with the latest version to ensure the issue hasn't been fixed

How often does this bug occurs?

always

Expected behavior

No Segmentation fault

Actual behavior (suspected bug)

I have esphosted ng on the host and the corresponding firmware v1.0.3.0.10. I connect to an AP and performed an iperf test. I lost the interface shortly after and the kernel module on the host detected a boot up event. I could also successfully reconnect. But repeating the test still fails.

Error logs or terminal output

I (50549) FW_MAIN: Get Tx power command
I (50618) FW_MAIN: Get Tx power command
I (50669) FW_MAIN: Get Tx power command
I (50889) FW_MAIN: Get Tx power command
I (51079) FW_MAIN: Get Tx power command
I (51229) FW_MAIN: Get Tx power command
I (51279) FW_MAIN: Get Tx power command
I (51309) FW_MAIN: Get Tx power command
I (51379) FW_MAIN: Get Tx power command
I (51428) FW_MAIN: Get Tx power command
I (51519) FW_MAIN: Get Tx power command
I (51599) FW_MAIN: Get Tx power command
I (51679) FW_MAIN: Scan request
I (51729) FW_MAIN: Set Tx power command
I (51778) FW_MAIN: Set Tx power command
I (54139) FW_MAIN: Auth request
I (54340) FW_CMD: Connecting to MC-Tech-Net, channel: 6 [3]
I (54340) FW_CMD: AUTH Commit

I (54345) wifi:new:<6,0>, old:<1,0>, ap:<255,255>, sta:<6,0>, prof:1, snd_ch_cfg:0x0
I (54347) wifi:state: init -> auth (0xb0)
I (54349) FW_CMD: Unregistered event: 43

I (54352) FW_CMD: handle_wpa_sta_rx_mgmt:731 Auth[11] recvd

I (54408) FW_MAIN: Assoc request
I (54408) wifi:state: auth -> assoc (0x0)
I (54428) FW_CMD: handle_wpa_sta_rx_mgmt:739 ASSOC Resp[1] recvd

I (54428) FW_CMD: STA connect event [channel 6]

I (54429) BSSID: 0x3fca963e   34 56 fe c7 34 23                                 |4V..4#|
I (54436) wifi:state: assoc -> run (0x10)
I (54468) FW_MAIN: Get Tx power command
I (54529) FW_MAIN: Get Tx power command
I (54568) FW_MAIN: Add key request
I (54568) FW_CMD: set_key_internal:1685

I (54568) FW_CMD: Setting PTK algo=3 index=0
I (54628) FW_MAIN: Add key request
I (54628) FW_CMD: set_key_internal:1685

I (54628) FW_CMD: Setting GTK [1]

I (54628) wifi:connected with MC-Tech-Net, aid = 1, channel 6, BW20, bssid = 34:56:fe:c7:34:23
I (54635) wifi:security: WPA2-PSK, phy: bgn, rssi: -65
I (54640) wifi:pm start, type: 1

I (54643) wifi:dp: 1, bi: 102400, li: 3, scale listen interval from 307200 us to 307200 us
I (54651) wifi:set rx beacon pti, rx_bcn_pti: 14, bcn_timeout: 25000, mt_pti: 14, mt_time: 10000
I (54660) FW_CMD: Wifi Station Connected event!!

I (54681) wifi:<ba-add>idx:0 (ifx:0, 34:56:fe:c7:34:23), tid:0, ssn:0, winSize:64
I (54705) wifi:AP's beacon interval = 102400 us, DTIM period = 1
I (56089) FW_MAIN: Set IP Address
I (56169) FW_MAIN: Set multicast mac address list
I (57786) wifi:<ba-add>idx:1 (ifx:0, 34:56:fe:c7:34:23), tid:6, ssn:3, winSize:64

assert failed: queue_next_transaction spi_slave_api.c:430 (spi_trans->rx_buffer)
Core  0 register dump:
MEPC    : 0x40380880  RA      : 0x4038b4ea  SP      : 0x3fcbc390  GP      : 0x3fc99a00
TP      : 0x3fcbc540  T0      : 0x37363534  T1      : 0x7271706f  T2      : 0x33323130
S0/FP   : 0x00000077  S1      : 0x00000001  A0      : 0x3fcbc3cc  A1      : 0x3fc9bd29
A2      : 0x00000001  A3      : 0x00000029  A4      : 0x00000001  A5      : 0x3fca0000
A6      : 0x7a797877  A7      : 0x76757473  S2      : 0x00000009  S3      : 0x3fcbc4f0
S4      : 0x3fc9bd28  S5      : 0x00000000  S6      : 0x00000000  S7      : 0x00000000
S8      : 0x00000000  S9      : 0x00000000  S10     : 0x00000000  S11     : 0x00000000
T3      : 0x6e6d6c6b  T4      : 0x6a696867  T5      : 0x66656463  T6      : 0x62613938
MSTATUS : 0x00001881  MTVEC   : 0x40380001  MCAUSE  : 0x00000002  MTVAL   : 0x00000000
MHARTID : 0x00000000

Stack memory:
3fcbc390: 0x6e6d6c6b 0x6a696867 0x66656463 0x40394306 0x3fc9ba14 0x3c0b04dc 0x3fc9c1bc 0x3c0a6d1c
3fcbc3b0: 0x3fc9ba24 0x3fcbc3c4 0x3fc9ba28 0x3c0a6d88 0x3fc9bd28 0x00303334 0x3fcbc440 0x65737361
3fcbc3d0: 0x66207472 0x656c6961 0x71203a64 0x65756575 0x78656e5f 0x72745f74 0x61736e61 0x6f697463
3fcbc3f0: 0x7073206e 0x6c735f69 0x5f657661 0x2e697061 0x33343a63 0x73282030 0x745f6970 0x736e6172
3fcbc410: 0x78723e2d 0x6675625f 0x29726566 0x00000000 0x3fcbc554 0x00000004 0x00000000 0x403913b6
3fcbc430: 0x00001800 0x00000018 0x3fca0cb0 0x4038aea2 0x00000000 0x00000000 0x00000000 0x403913b6
3fcbc450: 0x00000008 0x00000640 0x3fcdc710 0x403913f8 0x00000000 0x00000001 0x3fca1064 0x40380c60
3fcbc470: 0x00000008 0x00000640 0x3fcbff64 0x40380d6e 0x00000000 0x00000008 0x00000640 0x00000004
3fcbc490: 0x00000000 0x00000000 0x00000000 0x40000000 0x3fcc9284 0x3fcc9284 0x00000000 0x00000000
3fcbc4b0: 0x00000000 0x3fcc9284 0x3fcbff64 0x4200f652 0x00000000 0x3fca601c 0x3fcc324c 0x000005f8
3fcbc4d0: 0x00000000 0x00000000 0x00000000 0x4200f706 0x00000000 0x00000000 0x00000000 0x00000000
3fcbc4f0: 0x00000000 0x00000000 0x00000000 0x3fca601c 0x00000000 0x00000000 0x00000000 0x4038c4c0
3fcbc510: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000
3fcbc530: 0x00000000 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0xa5a5a5a5 0x00000150
3fcbc550: 0x3fcbc320 0x00000000 0x3fc9cc68 0x3fcbeed0 0x3fcbc550 0x3fc9cc60 0x00000003 0x3fcba744
3fcbc570: 0x3fcba744 0x3fcbc550 0x00000000 0x00000016 0x3fcbb54c 0x5f697073 0x74736f70 0x6f72705f
3fcbc590: 0x00736563 0x3fcbc540 0x00000016 0x00000000 0x00000000 0x00000000 0x00000000 0x3fca12ac
3fcbc5b0: 0x3fca1314 0x3fca137c 0x00000000 0x00000000 0x00000001 0x00000000 0x00000000 0x00000000
3fcbc5d0: 0x42005680 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000
3fcbc5f0: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000
3fcbc610: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000
3fcbc630: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000
3fcbc650: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000
3fcbc670: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000
3fcbc690: 0x00000000 0x00000000 0x00000000 0x00000000 0x00000240 0x3fcbc6f8 0x3fcbc890 0x3fcbc8d8
3fcbc6b0: 0x3fcbc878 0x00000000 0x3fcbc6bc 0xffffffff 0x3fcbc6bc 0x3fcbc6bc 0x00000000 0x3fcbc6d0
3fcbc6d0: 0xffffffff 0x3fcbc6d0 0x3fcbc6d0 0x00000000 0x00000014 0x00000018 0x3c00ffff 0x00000000
3fcbc6f0: 0xf62e62b4 0xcdb369bc 0x3fcbf0b0 0x00000000 0x3fcbf0b0 0x012f0000 0x00030000 0x40394324
3fcbc710: 0x3fcbf114 0x00000000 0x3fcbf114 0x012f0000 0x00030000 0x40394324 0x3fcbff64 0x00000000
3fcbc730: 0x3fcbff64 0x00040000 0x00030000 0x40394324 0x3fcbf7c0 0x00000000 0x3fcbf7c0 0x012f0000
3fcbc750: 0x00030000 0x40394324 0x3fcbf6c8 0x00000000 0x3fcbf6c8 0x00040000 0x00030000 0x40394324
3fcbc770: 0x3fca601c 0x00000000 0x3fca601c 0x00140000 0x00020000 0x40394324 0x3fcbf020 0x00000000



ELF file SHA256: 79ee664d1

Rebooting...
ESP-ROM:esp32c3-api1-20210207
Build:Feb  7 2021
rst:0xc (RTC_SW_CPU_RST),boot:0xc (SPI_FAST_FLASH_BOOT)
Saved PC:0x40380838
SPIWP:0xee
mode:DIO, clock div:1
load:0x3fcd5820,len:0x1574
load:0x403cc710,len:0xc30
load:0x403ce710,len:0x2f58
entry 0x403cc71a
I (35) boot: ESP-IDF 67c1de1e-dirty 2nd stage bootloader
I (35) boot: compile time Mar 19 2025 09:59:12
I (35) boot: chip revision: v0.4
I (36) boot: efuse block revision: v1.3
I (39) boot.esp32c3: SPI Speed      : 80MHz
I (43) boot.esp32c3: SPI Mode       : DIO
I (47) boot.esp32c3: SPI Flash Size : 4MB
I (51) boot: Enabling RNG early entropy source...
I (55) boot: Partition Table:
I (58) boot: ## Label            Usage          Type ST Offset   Length
I (64) boot:  0 nvs              WiFi data        01 02 00009000 00004000
I (71) boot:  1 otadata          OTA data         01 00 0000d000 00002000
I (77) boot:  2 phy_init         RF data          01 01 0000f000 00001000
I (84) boot:  3 factory          factory app      00 00 00010000 00100000
I (90) boot:  4 ota_0            OTA app          00 10 00110000 00100000
I (97) boot:  5 ota_1            OTA app          00 11 00210000 00100000
I (103) boot: End of partition table
I (107) boot: Defaulting to factory image
I (110) esp_image: segment 0: paddr=00010020 vaddr=3c0a0020 size=1a3f0h (107504) map
I (135) esp_image: segment 1: paddr=0002a418 vaddr=3fc99200 size=036f8h ( 14072) load
I (138) esp_image: segment 2: paddr=0002db18 vaddr=40380000 size=02500h (  9472) load
I (141) esp_image: segment 3: paddr=00030020 vaddr=42000020 size=971e0h (618976) map
I (245) esp_image: segment 4: paddr=000c7208 vaddr=40382500 size=16b94h ( 93076) load
I (262) esp_image: segment 5: paddr=000ddda4 vaddr=50000200 size=0001ch (    28) load
I (270) boot: Loaded app from partition at offset 0x10000
I (270) boot: Disabling RNG early entropy source...
I (280) cpu_start: Unicore app
I (289) cpu_start: Pro cpu start user code
I (289) cpu_start: cpu freq: 160000000 Hz
I (290) app_init: Application information:
I (290) app_init: Project name:     network_adapter
I (294) app_init: App version:      NG-1.0.3.0.10
I (299) app_init: Compile time:     Mar 19 2025 09:59:09
I (304) app_init: ELF file SHA256:  79ee664d1...
I (308) app_init: ESP-IDF:          67c1de1e-dirty
I (312) efuse_init: Min chip rev:     v0.3
I (316) efuse_init: Max chip rev:     v1.99
I (320) efuse_init: Chip rev:         v0.4
I (324) heap_init: Initializing. RAM available for dynamic allocation:
I (330) heap_init: At 3FCA0CB0 len 0001F350 (124 KiB): RAM
I (336) heap_init: At 3FCC0000 len 0001C710 (113 KiB): Retention RAM
I (342) heap_init: At 3FCDC710 len 00002950 (10 KiB): Retention RAM
I (348) heap_init: At 5000021C len 00001DCC (7 KiB): RTCRAM
I (354) spi_flash: detected chip: generic
I (357) spi_flash: flash io: dio
I (360) sleep_gpio: Configure to isolate all GPIO pins in sleep state
I (366) sleep_gpio: Enable automatic switching of GPIO sleep configuration
I (373) coexist: coex firmware version: 49a8cdc
I (403) coexist: coexist rom version 9387209
I (404) main_task: Started on CPU0
I (404) main_task: Calling app_main()
I (404) stats: *********************************************************************
I (410) stats:                 ESP-Hosted Firmware version :: NG-1.0.3.0.10
I (419) stats:                 Transport used :: SPI only
I (426) stats: *********************************************************************
I (433) FW_MAIN: Supported features are:
I (437) FW_MAIN: - WLAN over SPI
I (440) FW_BT: - BT/BLE
I (442) FW_BT:    - HCI Over SPI
I (445) FW_BT:    - BLE only
I (447) FW_MAIN: Capabilities: 0xe8
pp rom version: 9387209
net80211 rom version: 9387209
I (457) wifi:wifi driver task: 3fca7a4c, prio:23, stack:6656, core=0
I (463) wifi:wifi firmware version: 87d6f3c
I (466) wifi:wifi certification version: v7.0
I (470) wifi:config NVS flash: disabled
I (473) wifi:config nano formatting: disabled
I (477) wifi:Init data frame dynamic rx buffer num: 40
I (482) wifi:Init static rx mgmt buffer num: 5
I (486) wifi:Init management short buffer num: 32
I (491) wifi:Init dynamic tx buffer num: 40
I (495) wifi:Init static tx FG buffer num: 2
I (499) wifi:Init static rx buffer size: 1600
I (503) wifi:Init static rx buffer num: 20
I (506) wifi:Init dynamic rx buffer num: 40
I (511) wifi_init: rx ba win: 32
I (513) wifi_init: accept mbox: 6
I (516) wifi_init: tcpip mbox: 32
I (519) wifi_init: udp mbox: 6
I (522) wifi_init: tcp mbox: 6
I (525) wifi_init: tcp tx win: 5760
I (528) wifi_init: tcp rx win: 5760
I (531) wifi_init: tcp mss: 1440
I (534) wifi_init: WiFi IRAM OP enabled
I (538) wifi_init: WiFi RX IRAM OP enabled
I (542) BLE_INIT: BT controller compile version [d752dea]
I (548) BLE_INIT: Bluetooth MAC: f0:f5:bd:e9:ae:0a
I (552) phy_init: phy_version 1180,01f2a49,Jun  4 2024,16:34:25
I (592) FW_MAIN: ESP Bluetooth MAC addr: f0-f5-bd-e9-ae- a

I (593) FW_SPI: Using SPI interface
I (593) FW_SPI: Using SPI MODE 2
I (593) gpio: GPIO[4]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0
I (602) gpio: GPIO[5]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0
I (1611) FW_MAIN: Initial set up done
I (1611) main_task: Returned from app_main()
I (6829) FW_MAIN: INIT Interface command
I (6830) wifi:mode : sta (f0:f5:bd:e9:ae:08)
I (6831) wifi:enable tsf
I (6831) FW_CMD: Unregistered event: 43

I (6832) FW_CMD: station started and disabled softap mode
I (6869) FW_MAIN: Get MAC command
I (6919) FW_MAIN: Get Tx power command

Steps to reproduce the behavior

  1. install v1.0.3.0.10 to the esp and install the corresponding kernel module
  2. connect to an AP with hostapd
  3. run an iperf test test

Project release version

v1.0.3.0.10

System architecture

ARM 64-bit (Apple M1/M2, Raspberry Pi 4/5)

Operating system

Linux

Operating system version

openwrt 24

Shell

sh

Additional context

The esp is connected via spi to the host.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions