Support for D-Link DIR-842 (Rev C2)

bootargs = "console=ttyS0,115200 root=31:02 rootfstype=squashfs,jffs2 root=31:02";

I meant to add mtdparts=

Thanks, I tried this, is shows on printenv but not on booting.

no that one is in dts format.... it wont show in printenv...

I tried this

setenv bootargs-append=console=ttyS0,115200 root=31:02 rootfstype=squashfs,jffs2 root=31:02

is shows on printenv but not on booting.

setenv bootargs 'console=ttyS0,115200 root=31:02 rootfstype=squashfs,jffs2'

you need to spend a day or two ironing out and getting use to it :wink:

Thanks!

I tired this, printenv shows

bootargs=console=ttyS0,115200 root=31:02 rootfstype=squashfs,jffs2

but it still doesnt show in bootlog.

1 Like

Thanks, but I cant find "boot" in kernel_menuconfig

BOOT OPTIONS >
      Support for the traditional ATAGS boot data passing [*]
      Supplement the appended DTB with traditional ATAG information [*]
              Kernel command line type > Extend with bootloader kernel arguments [*]

Thanks, but i cant find BOOT OPTIONS

Only

General setop
Machine selection
Openwrt specific image command line hack
Endianness selection (Big endian)
CPU selection
Kernel type
Bus options(PCI, PCMCIA, EISA, ISA, TC)
Power management options
CPU Power Management
Firmware Drivers
Virtualization
General architecture-dependent options
Enable loadable menu support
Enable the block layer
Executable file format
Networking support
Device Drivers
File systems
Security options
Cryptographic API
Library routines
Kernel hacking

I found the problem!

Turns out that I didnt enable seama firmware parser in the kernel,

go to kernek_menuconfig -> Memory Tree and Open Firmware support -> Openwrt specific MTD options-> select Seama firmware parser. And it boots!!!!

Thanks for your help!

But i have one more question.
The original firmware boots from 9f080040, but my openwrt build boots from 9f080000.
So I need to use bootm 9f080000 command to make openwrt boots.

Is there anyway I can make openwrt boots from 9f080040 also?

Thanks in advance

1 Like

target/linux/???

I based it on /target/linux/ath79/dts/qca9563_dlink_dir-859-a1.dts

because of this thread Support for DIR-842 rev: C1

1 Like

Will look into that.... jeff will probably help out if he drops by...

it is possible that you need to add some header magic when the buildroot generates the IMAGE... so your uboot actually copies to 0000 but the kernel itself starts at 0040.....

Boot your initramfs.... make full backups.... then hexdump -C | more your ( OEM ) kernel mtd part to see what the first 40 looks like.....

Be careful.... this is around the place where peeps start blasting critical data!

1 Like

Thanks very much for you help! Just another additional question , is

pci_bus 0000:00: No busn resource found for root bus, will use [bus 00-ff] 

normal? Because it seems like openwrt cant detect the wireless device

This is normal. It can be fixed by loading firmware.

Thanks, by loading firmware you mean loading wireless chip firmware?

You'll need to add your device to the 11-ath10k-caldata. It will load firmware from art to a file in /lib/firmware. Also mac should be patched,

Thanks, i added it but unfortunately

[   50.167509] ath10k 4.19 driver, optimized for CT firmware, probing pci device: 0x56.
[   50.177098] ath10k_pci 0000:00:00.0: enabling device (0000 -> 0002)
[   50.183862] ath10k_pci 0000:00:00.0: pci irq legacy oper_irq_mode 1 irq_mode 0 reset_mode 0
[   50.477587] firmware ath10k!fwcfg-pci-0000:00:00.0.txt: firmware_loading_store: map pages failed
[   50.666933] firmware ath10k!pre-cal-pci-0000:00:00.0.bin: firmware_loading_store: map pages failed
[   51.160531] firmware ath10k!QCA9888!hw2.0!ct-firmware-5.bin: firmware_loading_store: map pages failed
[   51.345585] firmware ath10k!QCA9888!hw2.0!ct-firmware-2.bin: firmware_loading_store: map pages failed
[   51.531209] firmware ath10k!QCA9888!hw2.0!firmware-6.bin: firmware_loading_store: map pages failed
[   51.720606] firmware ath10k!QCA9888!hw2.0!firmware-5.bin: firmware_loading_store: map pages failed
[   51.905955] firmware ath10k!QCA9888!hw2.0!firmware-4.bin: firmware_loading_store: map pages failed
[   52.095937] firmware ath10k!QCA9888!hw2.0!firmware-3.bin: firmware_loading_store: map pages failed
[   52.280802] firmware ath10k!QCA9888!hw2.0!firmware-2.bin: firmware_loading_store: map pages failed
[   52.290310] ath10k_pci 0000:00:00.0: Failed to find firmware-N.bin (N between 2 and 6) from ath10k/QCA9888/hw2.0: -11
[   52.301302] ath10k_pci 0000:00:00.0: could not fetch firmware files (-11)
[   52.308318] ath10k_pci 0000:00:00.0: could not probe fw (-11)
[   52.464835] ath9k 18100000.wmac: Direct firmware load for ath9k-eeprom-ahb-18100000.wmac.bin failed with error -2
[   52.475487] ath9k 18100000.wmac: Falling back to syfs fallback for: ath9k-eeprom-ahb-18100000.wmac.bin
[   52.593507] firmware ath9k-eeprom-ahb-18100000.wmac.bin: firmware_loading_store: map pages failed
[   52.603378] ath: phy1: Unable to load EEPROM file ath9k-eeprom-ahb-18100000.wmac.bin
[   52.611441] ath9k 18100000.wmac: failed to initialize device
[   52.617352] ath9k: probe of 18100000.wmac failed with error -22

What exactly did you add there?