[Sound-open-firmware] Problems booting byt in qemu

Kai Vehmanen kai.vehmanen at linux.intel.com
Fri Jun 14 17:11:15 CEST 2019


Hi,

On Thu, 6 Jun 2019, Dragos Tarcatu wrote:

> [   10.667562] sof-nocodec sof-nocodec: ASoC: failed to instantiate card -22
> 
> I'm on top of sof-dev, but in my previous log I had the verbose IPC 
> logging option off.
> I'm currently running with the timeout values set to:
> 
> core.c:
> #define TIMEOUT_DEFAULT_IPC_MS  3000
> #define TIMEOUT_DEFAULT_BOOT_MS 10000
> 
> ipc.c:
> #define IPC_TIMEOUT_MS         3000

I could now reproduce the error you got with very latest driver 
(topic/sof-dev) and FW.

For me, simply bumping the timeouts did help. The separate timeout value 
in ipc.c is very misleading though -- I wasted some time today by just 
bumping the value in core.c and wondering why timeouts still happened. I 
made a pull-req to change to use the already defined default in core.c and to 
bump up the defaults, so that the driver would work out-of-the-box against 
a FW runnning under QEMU:

https://github.com/thesofproject/linux/pull/1038

... let's see what others think about that. If there is some good reason 
to keep small timeout values, then let's figure out how do we adjust these 
so that driver would work nicer with QEMU by default (maybe adjust the 
defaults just for nocodec mode or something similar).

For me, IPC timeout of 3sec and boot timeout of 5sec work out of the box 
(qemu running on a pretty low end desktop system). Trying to play a stream
still fails as HW_PARAMS IPC times out, but the reason is probably 
similar -- did not try to debug this yet. E.g. alsamixer can be used, so
the DSP is alive and well, but timeouts can be easily hit.

I also noted that we have some timing-related problem in the DSP boot. I 
had not noticed this before as I've run the xtensa qemu always with "-s 
-S" (or -d to the xtensa-host.sh script) flags. Today when I tried 
without, the firmware boot started failing systematically. But this is 
not related to FW/SW versions, but rather something to do with timing. 
When  running with debugs enabled, DSP boot is pretty reliable for me.

There are definitely issues to iron out in this full setup where both
host and DSP are emulated, but at least the basics are still working.

Br,
Kai


More information about the Sound-open-firmware mailing list