Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 06 Sep 2013 12:13:42 -0700
From:      Sean Bruno <sean_bruno@yahoo.com>
To:        Adrian Chadd <adrian@freebsd.org>
Cc:        freebsd-embedded <freebsd-embedded@freebsd.org>
Subject:   Buffalo Airstation build support
Message-ID:  <1378494822.48894.9.camel@localhost>

next in thread | raw e-mail | index | archive | help

--=-Nka/7Lj5ePky+P6ge/VI
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

http://people.freebsd.org/~sbruno/buffalo_airstation_support.txt

Implement support for Buffalo, "OpenWRT Friendly" Atheros Mips 24k board
in the wifi builder.

I'm still working on the kernconf, but the wifi builder support will
create and image called /tftpboot/wzr300hp-tftp.bin that is accepted by
the router when pushed in via tftp and uboot following the instructions
at:
http://wiki.openwrt.org/toh/buffalo/wzr-hp-g300h#oem.installation.using.the=
.tftp.method

The kernel panics right now, and I'll follow up with a kernconf/hints
patch for review once I have fixed my initial crash and burn.BUFFALO
U-BOOT Ver 1.00
  =3D=3D CPU:400MHz, DDR:400MHz, AHB:200MHz =3D=3D
PB93 (ar7241 - Virian) U-boot
DRAM:  64 MB
WAN port disabling: done
Top of RAM usable for U-Boot at: 84000000
Reserving 267k for U-Boot at: 83fbc000
Reserving 192k for malloc() at: 83f8c000
Reserving 44 Bytes for Board Info at: 83f8bfd4
Reserving 36 Bytes for Global Data at: 83f8bfb0
Reserving 128k for boot params() at: 83f6bfb0
Stack Pointer at: 83f6bf98
Now running in RAM - U-Boot at: 83fbc000
flash bank #0 found 16 MB flash [MX25L128-45E, blk:0x10000, sectors:256]
flash bank #1 found 16 MB flash [MX25L128-45E, blk:0x10000, sectors:256]
Flash: 32 MB
In:    serial
Out:   serial
Err:   serial
Memory Test
uboot use  83F6BFB0 - 84000000
Memory Test start(80000000) end(83F00000) size(03F00000)
Pattern 00000000  Writing...  Reading...
Memory Test OK
### buf_ver=3D[1.00] U-Boot Ver.=3D[1.00]
### build_date(env)=3D[May 21 2012 - 06:39:59] build_date(bin)=3D[May 21
2012 - 06:39:59]
ag7240_enet_initialize...
Reading MAC Address from ENV(0x83f8c2f8)
No valid address in Flash. Using fixed address
Virian MDC CFG Value =3D=3D> 4
: cfg1 0x7 cfg2 0x7014
eth0: 02:aa:bb:cc:dd:1a
eth0 up
Virian MDC CFG Value =3D=3D> 4
: cfg1 0xf cfg2 0x7214
eth1: 00:03:7f:09:0b:ad
ATHRS26: resetting s26
ATHRS26: s26 reset done
eth1 up
eth0  02:AA:BB:CC:DD:1A
, eth1  00:03:7F:09:0B:AD

dup 1 speed 1000

tftp server(receive) go, waiting:4[sec]
Load address: 0x81f00000
$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
	 $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
tftp server done
Bytes transferred =3D 7154208 (6d2a20 hex)

Airstation Public header
Recv fw image [7154176] bytes, now writing...

flash-addr 0xBF060000 - 0xBF73FFFF
search sector 0xbf060000 - 0xbf73ffff
BANK #1 (6 : 115)
  000  PPPP.Poooooooooooooooooooooooooo
  032  oooooooooooooooooooooooooooooooo
  064  oooooooooooooooooooooooooooooooo
  096  oooooooooooooooooooo............
  128  ................................
  160  ................................
  192  ................................
  224  ................................
BANK #2 (-1 : -1)
  000  ................................
  032  ................................
  064  ................................
  096  ................................
  128  ................................
  160  ................................
  192  ................................
  224  ................................

First 0x6 last 0x73 sector size 0x10000
 115
Erased 110 sectors
Copy to Flash...=20
 Copy 7154176 byte to Flash...
write data: 81f00020 --> bf060000  (len:6d2a00)
done
change bootargs
console=3DttyS0,115200 root=3D31:03 rootfstype=3Djffs2 init=3D/sbin/init
mtdparts=3Dar7240-nor0:256k(u-boot),64k(u-boot-env),1152k@384k(uImage),6592=
k@1536k(rootfs),64k@320k(ART),64k@8128k(properties) mem=3D64M product_rev=
=3D1 UART=3D1
## Booting image at bf060000 ...
   Image Name:   FreeBSD
   Created:      2013-09-05  14:01:16 UTC
   Image Type:   MIPS Linux Kernel Image (lzma compressed)
   Data Size:    1084688 Bytes =3D  1 MB
   Load Address: 80050000
   Entry Point:  80050100
   Verifying Checksum ... crc32_fw: bf060040 - bf168d4f (len:00108d10)
calc...
crc32_fw: range1 bf060040 - bf168d4f
OK
   Uncompressing Kernel Image ... OK
Ethernet Disabled!
No initrd
## Transferring control to Linux (at address 80050100) ...
## Giving linux memsize in bytes, 67108864

Starting kernel ...

CPU platform: Atheros AR7242 rev 1
CPU Frequency=3D400 MHz
CPU DDR Frequency=3D400 MHz
CPU AHB Frequency=3D200 MHz
platform frequency: 400000000
CPU reference clock: 5 MHz
arguments:=20
  a0 =3D 00000009
  a1 =3D a3f6bfb0
  a2 =3D a3f6c490
  a3 =3D 00000020
Cmd line:argv is invalid
Environment:
envp is invalid
Cache info:
  picache_stride    =3D 4096
  picache_loopcount =3D 16
  pdcache_stride    =3D 4096
  pdcache_loopcount =3D 8
cpu0: MIPS Technologies processor v116.147
  MMU: Standard TLB, 16 entries
  L1 i-cache: 4 ways of 512 sets, 32 bytes per line
  L1 d-cache: 4 ways of 256 sets, 32 bytes per line
  Config1=3D0x9ee3519e<PerfCount,WatchRegs,MIPS16,EJTAG>
  Config3=3D0x20
Physical memory chunk(s):
0x541000 - 0x3ffffff, 61599744 bytes (15039 pages)
Maxmem is 0x4000000
KDB: debugger backends: ddb
KDB: current backend: ddb
Copyright (c) 1992-2013 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
	The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 10.0-CURRENT #8 r255228:255230M: Thu Sep  5 07:00:03 PDT 2013

sbruno@powernoodle:/home/sbruno/bsd/obj/mipseb/mips.mips/home/sbruno/bsd/he=
ad/sys/WZR-300HP mips
gcc version 4.2.1 20070831 patched [FreeBSD]
WARNING: WITNESS option enabled, expect reduced performance.
MEMGUARD DEBUGGING ALLOCATOR INITIALIZED:
	MEMGUARD map base: 0xc0800000
	MEMGUARD map size: 104860 KBytes
Preloaded elf kernel "kernel" at 0x8053b484.
real memory  =3D 67108864 (65536K bytes)
Physical memory chunk(s):
0x005d5000 - 0x03eb8fff, 59654144 bytes (14564 pages)
avail memory =3D 58933248 (56MB)
random device not loaded; using insecure entropy
random: <Software, Yarrow> initialized
mem: <memory>
null: <null device, zero device>
nexus0: <MIPS32 root nexus>
clock0: <Generic MIPS32 ticker> on nexus0
Timecounter "MIPS32" frequency 200000000 Hz quality 800
Event timer "MIPS32" frequency 200000000 Hz quality 800
apb0 at irq 4 on nexus0
uart0: <16550 or compatible> on apb0
uart0: console (115200,n,8,1)
uart0: fast interrupt
gpio0: <Atheros AR71XX GPIO driver> on apb0
gpio0: [GIANT-LOCKED]
gpio0: gpio pinmask=3D0x0
gpioc0: <GPIO controller> on gpio0
gpiobus0: <GPIO bus> on gpio0
pcib0 at irq 0 on nexus0
pcib0: ar71xx_pci_attach: missing hint 'baseslot', default to
AR71XX_PCI_BASE_SLOT
Trap cause =3D 7 (bus error (load or store) - kernel mode)
[ thread pid 0 tid 100000 ]
Stopped atpanic: corrupt spinlock


--=-Nka/7Lj5ePky+P6ge/VI
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: This is a digitally signed message part

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.14 (FreeBSD)

iQEcBAABAgAGBQJSKilmAAoJEBkJRdwI6BaHdEcH/0b/SoHQoo7fwRGfEjx6kKjd
0ngBlo+Twut/pXmyQNQoXfglT2kAAUyymzuagbRAySoeano9UnaBLOEMwx2JEdi6
pyGFguc6865h9Kn+o8mgdFQVPZaGWxj5fp2twIbxgwoUX97+0EUuSYv/4sHGCI6p
Balp38vEuNbuSexX6R7OGSfvxqIS73+eDUht01tgh5Hqx5W67lb6z819hl647Yfh
4BTwmA5IHrXyXE5nwqnDUdMN9fJ42USlc1gbCocSJJLAJ2IEJgfcpgsUIypxmBkE
QceO0aLuuLAQdbPIVrBsKgtmHR0T+slnzUDeL9ysg1Sgm7tOICJrHDF9TY9e5WA=
=ZVV3
-----END PGP SIGNATURE-----

--=-Nka/7Lj5ePky+P6ge/VI--




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1378494822.48894.9.camel>