New Kernel for Wandboard Quard


#1

Hi, I am trying to follow the instructions on this page https://www.digikey.com/eewiki/display/linuxonarm/wandboard to build a new Kernel / SD boot disk for my Wandboard Quad. I am doing this in Ubuntu 18.04.1 on a x86-64 machine.

I am able to follow the instructions until I reach:

make ARCH=arm CROSS_COMPILE=${CC} wandboard_defconfig

When I execute the above, I get the following error:

HOSTCC scripts/basic/fixdep
/bin/sh: 1: cc: not found
scripts/Makefile.host:97: recipe for target ‘scripts/basic/fixdep’ failed
make[1]: *** [scripts/basic/fixdep] Error 127
Makefile:415: recipe for target ‘scripts_basic’ failed
make: *** [scripts_basic] Error 2

Would someone be able to help me? I can follow simple instructions, but otherwise am a Linux newbie. I am trying to build a new kernel so that my Wandboard Quad will have the latest patches. My current kernel does not fully support my DAC for USB Audio and DSD.

Thank you. Hammer8


#2

@hammer8

First double check how you exported “cc/CC” as it’s not getting passed to the kernel build scripts… Second, you do have gcc installed for the host machine?

Regards,


#3

Hi, I changed git checkout v2018.09 -b tmp to git checkout v2018.11 -b tmp

and got the rest of the procedure working. With the SD card that is created, I am able to boot my wandboard, but I am experiencing some issues. For example, it looks like the sound drivers are not installed. Do you have any instructions to get all the peripherals on the Wandboard Quad working? Thank you! Hammer8


#4

@hammer8, the snd drivers are installed, you just need to properly select which output device, thru alsamixer/aplay

 voodoo@w1-imx6q-wandboard-2gb:~$ uname -r ; dmesg | grep spdif ; lsmod | grep snd_soc ; aplay -l
4.19.9-armv7-x13
[    9.791224] imx-spdif sound-spdif: ASoC: CPU DAI (null) not registered
[    9.791238] imx-spdif sound-spdif: snd_soc_register_card failed: -517
[    9.847701] imx-spdif sound-spdif: ASoC: CPU DAI (null) not registered
[    9.847712] imx-spdif sound-spdif: snd_soc_register_card failed: -517
[    9.947043] imx-spdif sound-spdif: ASoC: CPU DAI (null) not registered
[    9.947062] imx-spdif sound-spdif: snd_soc_register_card failed: -517
[    9.990388] imx-spdif sound-spdif: ASoC: CPU DAI (null) not registered
[    9.990406] imx-spdif sound-spdif: snd_soc_register_card failed: -517
[   10.037378] imx-spdif sound-spdif: snd-soc-dummy-dai <-> 2004000.spdif mapping ok
[   10.037395] imx-spdif sound-spdif: ASoC: no DMI vendor name!
snd_soc_sgtl5000       32768  1
snd_soc_fsl_ssi        20480  2
snd_soc_imx_sgtl5000    16384  0
imx_pcm_fiq            16384  1 snd_soc_fsl_ssi
snd_soc_fsl_spdif      24576  2
imx_pcm_dma            16384  2 snd_soc_fsl_ssi,snd_soc_fsl_spdif
snd_soc_imx_spdif      16384  0
snd_soc_core          167936  7 snd_soc_fsl_ssi,snd_soc_imx_sgtl5000,snd_soc_fsl_spdif,snd_soc_sgtl5000,imx_pcm_dma,snd_soc_imx_spdif,imx_pcm_fiq
snd_pcm_dmaengine      16384  1 snd_soc_core
snd_pcm                86016  6 snd_soc_fsl_ssi,snd_pcm_dmaengine,dw_hdmi_ahb_audio,snd_soc_sgtl5000,snd_soc_core,imx_pcm_fiq
snd_soc_imx_audmux     16384  1 snd_soc_imx_sgtl5000
snd                    69632  4 dw_hdmi_ahb_audio,snd_timer,snd_soc_core,snd_pcm
**** List of PLAYBACK Hardware Devices ****
card 0: DWHDMI [DW-HDMI], device 0: DW HDMI [dw-hdmi-ahb-audio]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: imx6wandboardsg [imx6-wandboard-sgtl5000], device 0: HiFi sgtl5000-0 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 2: imxspdif [imx-spdif], device 0: S/PDIF PCM snd-soc-dummy-dai-0 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0

PS, if you don’t see any modules loaded with “lsmod” just run:

sudo depmod -a

and reboot…

Regards,


#5

Hi, when I do that, I get

root@arm:/home/debian# uname -r ; dmesg | grep spdif ; lsmod | grep snd_soc ; aplay -l
4.19.9-armv7-x13
aplay: device_list:270: no soundcards found…


#6

Yeap, run:

sudo depmod -a

Your version of kmod on your x86 machine is too old for the xz compressed modules, so the depmod files are out of date on your wandboard…

Regards,


#7

Thanks…I tried that, but still when I do that, I get

root@arm:/home/debian# sudo depmod -a
root@arm:/home/debian# uname -r ; dmesg | grep spdif ; lsmod | grep snd_soc ; aplay -l
4.19.9-armv7-x13
aplay: device_list:270: no soundcards found…


#8

Do I need to do something on the x86 machine that I used to build the SD card and then try again?

Thank you


#9

No it should work, also give this a try:

sudo update-initramfs -uk `uname -r`

You may have to reboot…

Are the modules installed and around this size?

voodoo@w1-imx6q-wandboard-2gb:~$ du -sh /lib/modules/4.19.9-armv7-x13/*.dep
236K	/lib/modules/4.19.9-armv7-x13/modules.dep
voodoo@w1-imx6q-wandboard-2gb:~$ du -sh /lib/modules/4.19.9-armv7-x13/
27M	/lib/modules/4.19.9-armv7-x13/

Regards,


#10

Hi,

root@arm:/home/debian# sudo update-initramfs -uk uname -r
/boot/initrd.img-4.19.9-armv7-x13 does not exist. Cannot update.

root@arm:/home/debian# du -sh /lib/modules/4.19.9-armv7-x13/*.dep
236K /lib/modules/4.19.9-armv7-x13/modules.dep
root@arm:/home/debian# du -sh /lib/modules/4.19.9-armv7-x13/
27M /lib/modules/4.19.9-armv7-x13/

Sizes look okay…after I reboot, I try:

root@arm:/home/debian# sudo update-initramfs -uk uname -r
/boot/initrd.img-4.19.9-armv7-x13 does not exist. Cannot update.

So still same issue, but now, I see the soundcards. So, is the missing /boot/initrd.img-4.19.9-armv7-x13 okay?

Thanks again.

[ 7.487418] imx-spdif sound-spdif: ASoC: CPU DAI (null) not registered
[ 7.504408] imx-spdif sound-spdif: snd_soc_register_card failed: -517
[ 7.638627] imx-spdif sound-spdif: ASoC: CPU DAI (null) not registered
[ 7.645311] imx-spdif sound-spdif: snd_soc_register_card failed: -517
[ 7.701623] imx-spdif sound-spdif: ASoC: CPU DAI (null) not registered
[ 7.708274] imx-spdif sound-spdif: snd_soc_register_card failed: -517
[ 7.769985] imx-spdif sound-spdif: snd-soc-dummy-dai <-> 2004000.spdif mappin g ok
[ 7.777754] imx-spdif sound-spdif: ASoC: no DMI vendor name!
snd_soc_imx_sgtl5000 16384 0
snd_soc_sgtl5000 32768 1
snd_soc_imx_spdif 16384 0
snd_soc_imx_audmux 16384 1 snd_soc_imx_sgtl5000
snd_soc_fsl_ssi 20480 2
snd_soc_fsl_spdif 24576 2
imx_pcm_dma 16384 2 snd_soc_fsl_ssi,snd_soc_fsl_spdif
imx_pcm_fiq 16384 1 snd_soc_fsl_ssi
snd_soc_core 167936 7 snd_soc_fsl_ssi,snd_soc_imx_sgtl5000,snd_soc_fsl _spdif,snd_soc_sgtl5000,imx_pcm_dma,snd_soc_imx_spdif,imx_pcm_fiq
snd_pcm_dmaengine 16384 1 snd_soc_core
snd_pcm 86016 6 snd_soc_fsl_ssi,snd_pcm_dmaengine,dw_hdmi_ahb_au dio,snd_soc_sgtl5000,snd_soc_core,imx_pcm_fiq
snd 69632 4 dw_hdmi_ahb_audio,snd_timer,snd_soc_core,snd_pcm
**** List of PLAYBACK Hardware Devices ****
card 0: DWHDMI [DW-HDMI], device 0: DW HDMI [dw-hdmi-ahb-audio]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: imx6wandboardsg [imx6-wandboard-sgtl5000], device 0: HiFi sgtl5000-0
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: imxspdif [imx-spdif], device 0: S/PDIF PCM snd-soc-dummy-dai-0
Subdevices: 1/1
Subdevice #0: subdevice #0


#11

Correct, missing /boot/initrd.img-4.19.9-armv7-x13 isn’t a big deal for the wandboard’s…

For reference it’s the “-c” that creates, “-u” updates…

sudo update-initramfs -ck uname -r

Regards,


#12

Thanks. It’s working…should I still do

sudo update-initramfs -ck uname -r

to create the file?

I really appreciate all your help. Would you allow me to paypal you something as a token of my appreciation? What is your address?

Thank you.