-
Notifications
You must be signed in to change notification settings - Fork 8.2k
Description
Context: I'm developing a new network driver. I never wrote one from scratch, so doing a lot of stupid things. I would think that logging is there to help me, but instead, it puzzles me.
So, to reproduce this one, you'd need to look at the branch https://github.com/pfalcon/zephyr/tree/smsc9220-pfalcon-logging-issue . There lives the new WIP driver, and to test it, I made adhoc prj.conf changes to hello_world and echo_server samples. The changes are largely the same and include CONFIG_ETHERNET_LOG_LEVEL_DBG=y. I run:
hello_world$ zephyr-make BOARD=mps2_an385 run
[QEMU] CPU: cortex-m3
init ok
eth_smsc9220_isr: 0 0
eth_initialize
eth_tx
eth_tx
***** Booting Zephyr OS zephyr-v1.13.0-1494-gfabf4596e1 *****
[00:00:00.000,000] <err> eth_smsc9220.eth_init: MAC 52:54:00:12:34:56
Hello World! mps2_an385
That's the expected output (specifically <err> logging).
Now I run:
echo_server$ zephyr-make BOARD=mps2_an385 run
[QEMU] CPU: cortex-m3
uart:~$ init ok
eth_smsc9220_isr: 0 0
eth_initialize
eth_tx
eth_tx
***** Booting Zephyr OS zephyr-v1.13.0-1494-gfabf4596e1 *****
eth_tx
Which is not the expected output, as I miss that err logging of mac address.
(If you run these samples, you'll notice that soon after that output, they crash. Well, that's the issue I'd like logging to help me with, and not sure if it can, because from my PoV it works erratically even with simpler things.)