Support for A10/A20

  • A note to self, or possibly others running into the panic on boot: try the rootwait nousb kcmd options or combinations thereof.

    Can anyone test that? other SoCs don't need that.

  • Not quite sure what that does, but here's what looks relevant from A1000 fex file:

    OK usbc0 is disabled in the fex. So dtb should be OK. I don't see any differences.

  • OK usbc0 is disabled in the fex. So dtb should be OK. I don't see any differences.

    Hmm, maybe this is the problem - what would be the DTS equivalent of usb_host_init_state in FEX?

    Quote


    various: Set usbc2 usb_host_init_state to 1

    Code
    1. usb_host_init_state for usbc2 needs to be 1 for the wifi driver to properly
    2. auto-load. I don't have these boards to verify, but these are 512Mb RAM
    3. variants of 1Gb boards I do have, so it is safe to assume this is necessary
    4. with their 512Mb counter-parts too.
    5. Signed-off-by: Hans de Goede <[email protected]>
  • jernej


    it seems to activate a lcd screen it has to happen in uboot. So if I build a new custom uboot, can I use a already flashed image and just dd the new uboot to the sd-card like this:


    Code
    1. dd if=u-boot.bin of=/dev/mmcblk0 bs=1024 seek=32
  • it seems to activate a lcd screen it has to happen in uboot.

    simple-fb (U-Boot initialized screen) is not useful for LibreELEC.


    So if I build a new custom uboot, can I use a already flashed image and just dd the new uboot to the sd-card like this:

    you can.

  • simple-fb (U-Boot initialized screen) is not useful for LibreELEC.

    So I have this projector running android on a A20. In the fex file, hdmi is disabled and lcd is enabled. So it seems the projector works through the lcd interface. On the sunxi pages it is mentioned that a custom u-boot should be build and the data in the fex file should be converted to u-boot config. But now you say this will not work on LE because it doesn't us simple-fb? How can I make LE picture through the projector then?

    Would you say: don't bother, don't waist your time. Because this would means that LE will not work on any tablet, right?

  • I've tried the ready-made image linked here, which should be a mainline kernel, albeit an old one: Mainline Debian HowTo - linux-sunxi.org (image link). I didn't go into installing UBoot and full-featured boot - I think that nukes the onboard android, which I don't want to do yet (want to back up the partitions first, and don't have an ADB cable yet). But the pre-install environment did boot successfully, with even the USB ports working (there was no driver for the onboard wifi, but it did show up in lsusb.


    What would be a simple way to prevent jernej's build from loading the Realtek wifi drivers, to check if that's the culprit here?

  • What would be a simple way to prevent jernej's build from loading the Realtek wifi drivers, to check if that's the culprit here?

    The easiest that I could think of it to edit DT and remove USB node connected to wifi.


    But now you say this will not work on LE because it doesn't us simple-fb?

    Problem is that Kodi expects full DRM driver in order to work correctly. simple-fb is fbdev driver. You would see LibreELEC splash screen but I don't think Kodi would start.

    How can I make LE picture through the projector then?

    Would you say: don't bother, don't waist your time. Because this would means that LE will not work on any tablet, right?

    Anything can run LE if it uses DRM driver and GPU driver which supports GBM interface. You just need to figure how to properly describe LCD panel in device tree. But I'm not right person to help you with that, I don't have experience with any output besides HDMI.

  • Anything can run LE if it uses DRM driver and GPU driver which supports GBM interface. You just need to figure how to properly describe LCD panel in device tree. But I'm not right person to help you with that, I don't have experience with any output besides HDMI.

    OK, I will see if I can get further with this, I see in the pinephone dtb these lines that refer to the screen:

    So probably it will be something regarding dsi. For the moment I don't find a specific A20 dtb for tablets using mainline.

  • roel note that tablets can use parallel, DSI or LVDS interface. You have to check fex file to see which one is actually used on your device.

  • jernej seems its parallel. It's certainly not LVDS is this one is not enabled. The fex section describes it as lcd_para so I assume this means parallel. I think this is out of my league but maybe I find a site with some good explanation. I already found this: ST Community

    but I'm still confused about this drm/kms stuff.

  • Am I doing this right? I decompiled the DTB, set status="disabled" on the first enabled usb node (and the phy which the subsequent attempt to boot complained about), compiled and replaced sun4i-a10-a1000.dtb. Diff:


    That did get rid of detecting the USB wifi (didn't have anything else attached), but the error message is the same:

    Quote

    [ 4.084220] Run /init as init process

    [ 4.095837] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00000004

    [ 4.109445] ---[ end Kernel panic - not syncing: Attempted to kill init! exitcode=0x00000004 ]---

    jernej, which /init is this referring to? This one?

  • Am I doing this right? I decompiled the DTB, set status="disabled" on the first enabled usb node (and the phy which the subsequent attempt to boot complained about), compiled and replaced sun4i-a10-a1000.dtb.

    yes, seems good.

    but the error message is the same:

    So wifi just appears to be last driver loaded, but not the cause.


    jernej , which /init is this referring to? This one?

    Yes.

  • > which /init..


    Yes.

    Is there a way to check that it (and busybox executable) is actually on the built image..? (My understanding is that this is the early rootfs - like initramfs on a PC Linux distro - and on these images, that's embedded in the KERNEL image file.) I tried the binwalk method of extraction, but for every xz file it finds in the KERNEL file, unxz reports it as corrupted.

  • Is there a way to check that it (and busybox executable) is actually on the built image..?

    Not sure, but currently initramfs is in cpio archive, which starts with "070701" string.

  • Well.. there are ~15 CPIO signatures in there :D

    While there seems to be something compressed in there, trying to extract it results in a lot of cpio errors, not finding "member names" (file names?)

    Checked the init script, and will try booting with debugging in the kcmd, hopefully will get more clues what's wrong. If not, I reckon the intramfs is somehow broken.

  • will try booting with debugging in the kcmd, hopefully will get more clues what's wrong.

    Nope, that didn't yield anything. :( Any ideas? May as well start setting up a build environment at this point...