Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision Next revisionBoth sides next revision | ||
| toh:d-link:dir-300 [2018/08/30 13:10] – kofec | toh:d-link:dir-300 [2019/11/23 05:46] – [Original Firmware flash layout] sefralgon | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== D-Link DIR-300 Rev.A1 (Airlink AR335W/ | ====== D-Link DIR-300 Rev.A1 (Airlink AR335W/ | ||
| + | |||
| + | {{section> | ||
| + | |||
| |:!: Note: For D-Link DIR-300 Rev.B (other hardware (HW), please see **[[toh: | |:!: Note: For D-Link DIR-300 Rev.B (other hardware (HW), please see **[[toh: | ||
| Line 23: | Line 26: | ||
| ===== First Time Installation... ===== | ===== First Time Installation... ===== | ||
| + | |||
| + | Before you install, you might need to back up the original firmware. It can be done in multiple ways, including but not limited to using UART and/or Telnet. The most important partition is Board/ | ||
| + | |||
| + | ==== Original Firmware flash layout ==== | ||
| + | < | ||
| + | # cat /proc/mtd | ||
| + | dev: size erasesize name | ||
| + | mtd0: 00400000 00010000 " | ||
| + | mtd1: 001ce000 00010000 " | ||
| + | mtd2: 003b0000 00010000 " | ||
| + | mtd3: 00010000 00010000 " | ||
| + | mtd4: 00020000 00010000 " | ||
| + | mtd5: 00010000 00010000 " | ||
| + | mtd6: 00010000 00010000 " | ||
| + | mtd7: 00400000 00010000 " | ||
| + | </ | ||
| + | |||
| + | Partition sizes correspond to DIR-300 v1.05_a319 firmware. While upgrade partition has multiple sections, only '' | ||
| + | |||
| + | ^ Layer0 | ||
| + | ^ Layer1 | ||
| + | ^ Layer2 | ||
| + | |||
| + | When original firmware is flashed onto the router, first 96B are stripped, since it's a header of some kind. The rest of it is written directly to '' | ||
| + | |||
| + | The data on the end of upgrade partition is likely remaining from past installation of some alt firmware and not used for anything. | ||
| + | |||
| ==== Flash Layout ==== | ==== Flash Layout ==== | ||
| First let's have a quick view at the [[docs: | First let's have a quick view at the [[docs: | ||
| Line 273: | Line 303: | ||
| openwrt-ath25-generic-squashfs-rootfs.bin | openwrt-ath25-generic-squashfs-rootfs.bin | ||
| </ | </ | ||
| + | Connect to telnet to 192.168.1.10 port 9000 | ||
| < | < | ||
| fis init | fis init | ||
| Line 280: | Line 311: | ||
| load -r -b %{FREEMEMLO} openwrt-ath25-generic-squashfs-rootfs.bin | load -r -b %{FREEMEMLO} openwrt-ath25-generic-squashfs-rootfs.bin | ||
| fis create rootfs | fis create rootfs | ||
| - | </ | ||
| - | If your router have already had DD-WRT installed, there will be a chance that the existing bootloader is MicroRedboot. In that case, the router boots rather fast, you cannot telnet to 192.168.1.1 9000 at start up. You will have to use Reset button to access Redboot. See http:// | ||
| - | |||
| - | If you have already followed this guide and your router is running OpenWrt, but because of some reason you still want to reflash using the bootloader you can access Redboot after 10-11 seconds from powering the device up with the following command: | ||
| - | |||
| - | < | ||
| - | telnet 192.168.1.10 9000 | ||
| </ | </ | ||
| ==== via Bootloader ==== | ==== via Bootloader ==== | ||
| Line 462: | Line 486: | ||
| ==== SD-card slot mod ==== | ==== SD-card slot mod ==== | ||
| There is a working mod to add a SD-card slot to your DIR-300. Follow the instructions [[http:// | There is a working mod to add a SD-card slot to your DIR-300. Follow the instructions [[http:// | ||
| + | ==== OpenWrt bootlog ==== | ||
| + | <WRAP bootlog> | ||
| + | < | ||
| + | [ 0.000000] Linux version 4.14.67 (kofec@E5420Mint) (gcc version 7.3.0 (OpenWrt GCC 7.3.0 r7981-a6e11ccb13)) #0 Wed Aug 29 19:00:58 2018 | ||
| + | [ 0.000000] bootconsole [early0] enabled | ||
| + | [ 0.000000] CPU0 revision is: 00019064 (MIPS 4KEc) | ||
| + | [ 0.000000] Determined physical RAM map: | ||
| + | [ 0.000000] | ||
| + | [ 0.000000] Initrd not found or empty - disabling initrd | ||
| + | [ 0.000000] Primary instruction cache 16kB, VIPT, 4-way, linesize 16 bytes. | ||
| + | [ 0.000000] Primary data cache 16kB, 4-way, VIPT, no aliases, linesize 16 bytes | ||
| + | [ 0.000000] Zone ranges: | ||
| + | [ 0.000000] | ||
| + | [ 0.000000] Movable zone start for each node | ||
| + | [ 0.000000] Early memory node ranges | ||
| + | [ 0.000000] | ||
| + | [ 0.000000] Initmem setup node 0 [mem 0x0000000000000000-0x0000000000ffffff] | ||
| + | [ 0.000000] On node 0 totalpages: 4096 | ||
| + | [ 0.000000] free_area_init_node: | ||
| + | [ 0.000000] | ||
| + | [ 0.000000] | ||
| + | [ 0.000000] | ||
| + | [ 0.000000] random: get_random_bytes called from 0x803a2724 with crng_init=0 | ||
| + | [ 0.000000] pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768 | ||
| + | [ 0.000000] pcpu-alloc: [0] 0 | ||
| + | [ 0.000000] Built 1 zonelists, mobility grouping off. Total pages: 4064 | ||
| + | [ 0.000000] Kernel command line: console=ttyS0, | ||
| + | [ 0.000000] PID hash table entries: 64 (order: -4, 256 bytes) | ||
| + | [ 0.000000] Dentry cache hash table entries: 2048 (order: 1, 8192 bytes) | ||
| + | [ 0.000000] Inode-cache hash table entries: 1024 (order: 0, 4096 bytes) | ||
| + | [ 0.000000] Memory: 12076K/ | ||
| + | [ 0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, | ||
| + | [ 0.000000] NR_IRQS: 128 | ||
| + | [ 0.000000] clocksource: | ||
| + | [ 0.000044] sched_clock: | ||
| + | [ 0.093925] Calibrating delay loop... 183.70 BogoMIPS (lpj=918528) | ||
| + | [ 0.247254] pid_max: default: 32768 minimum: 301 | ||
| + | [ 0.303331] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes) | ||
| + | [ 0.381815] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes) | ||
| + | [ 0.478520] clocksource: | ||
| + | [ 0.595452] futex hash table entries: 256 (order: -1, 3072 bytes) | ||
| + | [ 0.670236] NET: Registered protocol family 16 | ||
| + | [ 0.725362] Can't analyze schedule() prologue at 8031ebb8 | ||
| + | [ 0.874847] clocksource: | ||
| + | [ 0.941291] NET: Registered protocol family 2 | ||
| + | [ 0.996916] TCP established hash table entries: 1024 (order: 0, 4096 bytes) | ||
| + | [ 1.079706] TCP bind hash table entries: 1024 (order: 0, 4096 bytes) | ||
| + | [ 1.155501] TCP: Hash tables configured (established 1024 bind 1024) | ||
| + | [ 1.232162] UDP hash table entries: 256 (order: 0, 4096 bytes) | ||
| + | [ 1.301397] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes) | ||
| + | [ 1.377303] NET: Registered protocol family 1 | ||
| + | [ 1.429005] PCI: CLS 0 bytes, default 16 | ||
| + | [ 1.459740] Radio config found at offset 0xf8 (0x1f8) | ||
| + | [ 1.549079] Crashlog allocated RAM at address 0xf00000 | ||
| + | [ 1.630362] workingset: timestamp_bits=30 max_order=12 bucket_order=0 | ||
| + | [ 1.739465] squashfs: version 4.0 (2009/ | ||
| + | [ 1.808609] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc. | ||
| + | [ 1.992085] io scheduler noop registered | ||
| + | [ 2.038321] io scheduler deadline registered (default) | ||
| + | [ 2.100486] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled | ||
| + | [ 2.196960] serial8250: ttyS0 at MMIO 0x11100000 (irq = 9, base_baud = 5750000) is a 16550A | ||
| + | [ 2.296346] console [ttyS0] enabled | ||
| + | [ 2.379633] bootconsole [early0] disabled | ||
| + | [ 2.480695] ar2315-spiflash ar2315-spiflash.0: | ||
| + | [ 2.575388] Searching for RedBoot partition table in spiflash at offset 0x3d0000 | ||
| + | [ 3.039138] Searching for RedBoot partition table in spiflash at offset 0x3e0000 | ||
| + | [ 3.502859] 6 RedBoot partitions found on MTD device spiflash | ||
| + | [ 3.572014] Creating 6 MTD partitions on " | ||
| + | [ 3.631853] 0x000000000000-0x000000030000 : " | ||
| + | [ 3.704474] 0x000000030000-0x000000160000 : " | ||
| + | [ 3.784163] 0x000000160000-0x0000003e0000 : " | ||
| + | [ 3.849281] mtd: device 2 (rootfs) set to be root filesystem | ||
| + | [ 3.917851] 1 squashfs-split partitions found on MTD device rootfs | ||
| + | [ 3.992372] 0x0000002d0000-0x0000003e0000 : " | ||
| + | [ 4.074338] 0x0000003e0000-0x0000003ef000 : "FIS directory" | ||
| + | [ 4.152968] 0x0000003ef000-0x0000003f0000 : " | ||
| + | [ 4.232712] 0x0000003f0000-0x000000400000 : " | ||
| + | [ 4.376558] eth0: Atheros AR231x: 00: | ||
| + | [ 4.519858] IP17xx: Found IP175C at 0:00 | ||
| + | [ 4.688305] libphy: ar231x_eth_mii: | ||
| + | [ 4.906966] eth0: attached PHY driver [IC+ IP17xx] (mii_bus: | ||
| + | [ 4.996733] NET: Registered protocol family 17 | ||
| + | [ 5.050827] 8021q: 802.1Q VLAN Support v1.8 | ||
| + | [ 5.158519] VFS: Mounted root (squashfs filesystem) readonly on device 31:2. | ||
| + | [ 5.245421] Freeing unused kernel memory: 184K | ||
| + | [ 5.298969] This architecture does not have kernel memory protection. | ||
| + | [ 5.694951] random: fast init done | ||
| + | [ 8.640944] init: Console is alive | ||
| + | [ 8.683616] init: - watchdog - | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ | ||
| + | [ 137.135206] random: crng init done | ||
| + | </ | ||
| + | </ | ||
| ===== Tags ===== | ===== Tags ===== | ||
| [[meta: | [[meta: | ||
| {{tag> | {{tag> | ||