Hi,

I am currently adding LEDE support for the Netgear DM200 VDSL modem
[https://wiki.openwrt.org/toh/netgear/dm200], which uses a Lantiq VR9 SoC.

I was able to boot LEDE from RAM, and got the LEDs working, but I cannot
get the flash to work with LEDE :(

The bootloader (u-boot) has access to the flash and says this after
initialisation:

    8192 KiB W25Q64 at 0:3 is now current device

I assumed that it's a NOR flash chip given the size, connected via SPI.
The stock firmware only calls it "ltq_sflash" without being more specific.
For instance, here is the kernel cmdline from the stock firmware:

    root=/dev/mtdblock4 ro rootfstype=squashfs 
ip=192.168.1.1:192.168.1.10::::eth0:on console=ttyLTQ0,115200 
ethaddr=00:E0:92:00:01:40 mem=62M panic=1 
mtdparts=ltq_sflash:128k(uboot),64k(gphyfirmware),1600k(kernel),512k(firmware),5120k(rootfs),7232k@0x30000(image),64k(dniconfig),64k(log),512k(language),64k(sysconfig),8k(ubootconfig),4k(ART),4k(pot),-(ret)
 init=/etc/preinit vpe1_load_addr=0x83f00000 vpe1_mem=1M 
ubootver=U-Boot-2010.06-LANTIQ-v-2.3.16.1


So, assuming it's similar to other VR9 devices, I used this DTS:

       fpi@10000000 {
                localbus@0 {
                        nor-boot@0 {
                                compatible = "lantiq,nor";
                                bank-width = <2>;
                                reg = <0 0x0 0x0800000>;
                                #address-cells = <1>;
                                #size-cells = <1>;

                                partitions {
                                // etc


But with this DTS, LEDE fails to initialize the flash chip ("probing
failed" and nothing in /proc/mtd):

[    1.936821] lantiq nor flash device: 00800000 at 10000000
[    1.941431] ltq-nor 10000000.nor-boot: probing failed
[    2.054037] libphy: lantiq,xrx200-mdio: probed
[    2.078013] net-xrx200: invalid MAC, using random

I tried setting the CS (Chip Select) in the DTS, because the bootloader
uses bus 0 and CS 3 to access the flash.  I added this line to the
nor-boot@0 tree:

    lantiq,cs = <3>;

but it didn't change anything, LEDE still cannot access the flash.

How can I find the right parameters for the flash and set them in the DTS?
Any guidance would be appreciated!

Thanks,
Baptiste

Attachment: signature.asc
Description: PGP signature

_______________________________________________
Lede-dev mailing list
Lede-dev@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/lede-dev

Reply via email to