A new kernel for oxnas

This forum is for all other ARMv5 devices

Re: A new kernel for oxnas

Postby dangole » Fri Nov 08, 2013 1:31 pm

Thanks for the quick reply, I'll rebuild with more debugging later today and share the results. In the meantime I pushed my openwrt sources to:
https://gitorious.org/openwrt-oxnas/openwrt-oxnas
so git clone it and then
make menuconfig
select Target "PLXTECH NAS782X" (CONFIG_TARGET_oxnas)
For now I only added a profile for the STG-212, as that's the only hardware I got. You can create new profiles by adding them to
target/linux/oxnas/profiles/100-Generic.mk
and handle them in
target/linux/oxnas/image/Makefile
dangole
 
Posts: 6
Joined: Sun Nov 03, 2013 3:53 pm

Re: A new kernel for oxnas

Postby celemine1gig » Fri Nov 08, 2013 1:39 pm

Thank you very much, so far. Will definitely have a look at it, when I find the time. ;)
celemine1gig
 
Posts: 54
Joined: Fri Apr 26, 2013 7:55 pm

Re: A new kernel for oxnas

Postby dangole » Sat Nov 09, 2013 5:21 am

I managed to get the init process to boot once I disabled the oxnas_sata drive entirely :( If oxnas_sata is loaded, the system never runs init, but the console remains responsive.
The system also freezes once the Ethernet interface is brought up, however, disabling stmac brought me to a point where I got at least a minimal console and access to the NAND.
I can share more verbose bootlogs with anyone interested (too big to post here).
$this->bbcode_second_pass_code('', '
OX820 # bootm
## Loading kernel from FIT Image at 62000000 ...
Using 'config@1' configuration
Trying 'kernel@1' kernel subimage
Description: ARM OpenWrt Linux-3.12
Type: Kernel Image
Compression: uncompressed
Data Start: 0x620000e0
Data Size: 2521368 Bytes = 2.4 MiB
Architecture: ARM
OS: Linux
Load Address: 0x60008000
Entry Point: 0x60008000
Hash algo: crc32
Hash value: b0e463ab
Hash algo: sha1
Hash value: d29722ae828a5bddee14ee2ecc00a033469565a4
Verifying Hash Integrity ... crc32+ sha1+ OK
## Loading fdt from FIT Image at 62000000 ...
Using 'config@1' configuration
Trying 'fdt@1' fdt subimage
Description: ARM OpenWrt stg212 device tree blob
Type: Flat Device Tree
Compression: uncompressed
Data Start: 0x62267b28
Data Size: 4893 Bytes = 4.8 KiB
Architecture: ARM
Hash algo: crc32
Hash value: f97e2963
Hash algo: sha1
Hash value: cfb138982472cc85a01b45de16d678c18c1696be
Verifying Hash Integrity ... crc32+ sha1+ OK
Booting using the fdt blob at 0x62267b28
Loading Kernel Image ... OK
Loading Device Tree to 67e24000, end 67e2831c ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
[ 0.000000] Booting Linux on physical CPU 0x0
[ 0.000000] Linux version 3.12.0 (daniel@earthship) (gcc version 4.6.4 (OpenWrt/Linaro GCC 4.6-2013.05 r38636) ) #30 SMP Sat Nov 9 05:36:30 CET 2013
[ 0.000000] Machine: PLXTECH NAS782X SoC (Flattened Device Tree), model: MitraStar Technology Corp. STG-212
[ 0.000000] DT missing boot CPU MPIDR[23:0], fall back to default cpu_logical_map
[ 0.000000] PERCPU: Embedded 7 pages/cpu @c0637000 s8000 r8192 d12480 u32768
[ 0.000000] Kernel command line: console=ttyS0,115200n8 earlyprintk=serial
[ 0.000000] PID hash table entries: 512 (order: -1, 2048 bytes)
[ 0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
[ 0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
[ 0.000000] Virtual kernel memory layout:
[ 0.000000] vector : 0xffff0000 - 0xffff1000 ( 4 kB)
[ 0.000000] fixmap : 0xfff00000 - 0xfffe0000 ( 896 kB)
[ 0.000000] vmalloc : 0xc8800000 - 0xff000000 ( 872 MB)
[ 0.000000] lowmem : 0xc0000000 - 0xc8000000 ( 128 MB)
[ 0.000000] modules : 0xbf000000 - 0xc0000000 ( 16 MB)
[ 0.000000] .text : 0xc0008000 - 0xc03aeb9c (3739 kB)
[ 0.000000] .init : 0xc03af000 - 0xc04cff40 (1156 kB)
[ 0.000000] .data : 0xc04d0000 - 0xc04f4f6c ( 148 kB)
[ 0.000000] .bss : 0xc04f4f6c - 0xc05315b0 ( 242 kB)
[ 0.000000] Hierarchical RCU implementation.
[ 0.000000] NR_IRQS:160
[ 0.000000] sched_clock: 24 bits at 390kHz, resolution 2560ns, wraps every 42949ms
[ 0.000250] Calibrating delay loop... 298.59 BogoMIPS (lpj=1492992)
[ 0.069949] pid_max: default: 32768 minimum: 301
[ 0.070195] Mount-cache hash table entries: 512
[ 0.072238] CPU: Testing write buffer coherency: ok
[ 0.072675] Setting up static identity map for 0xc00122f8 - 0xc0012330
[ 0.140264] Brought up 2 CPUs
[ 0.140290] SMP: Total of 2 processors activated.
[ 0.144893] pinctrl core: initialized pinctrl subsystem
[ 0.145809] NET: Registered protocol family 16
[ 0.146337] DMA: preallocated 256 KiB pool for atomic coherent allocations
[ 0.147845] cpuidle: using governor ladder
[ 0.147865] cpuidle: using governor menu
[ 0.163968] gpio-oxnas 44000000.gpio: at address c8846000
[ 0.164203] gpio-oxnas 44100000.gpio: at address c8848000
[ 0.166760] pinctrl-oxnas pinctrl.5: initialized OX820 pinctrl driver
[ 0.185326] bio: create slab <bio-0> at 0
[ 0.189281] pps_core: LinuxPPS API ver. 1 registered
[ 0.189299] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[ 0.189608] PTP clock support registered
[ 0.193861] DMA-API: preallocated 4096 debug entries
[ 0.193873] DMA-API: debugging enabled by kernel config
[ 0.194007] Switched to clocksource rps_clocksource_timer
[ 0.199201] NET: Registered protocol family 2
[ 0.200099] TCP established hash table entries: 1024 (order: 1, 8192 bytes)
[ 0.200156] TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
[ 0.200194] TCP: Hash tables configured (established 1024 bind 1024)
[ 0.200276] TCP: reno registered
[ 0.200302] UDP hash table entries: 256 (order: 1, 8192 bytes)
[ 0.200345] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[ 0.200675] NET: Registered protocol family 1
[ 1.000038] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[ 1.000143] msgmni has been set to 243
[ 1.002071] io scheduler noop registered
[ 1.002094] io scheduler deadline registered (default)
[ 1.002165] io scheduler cfq registered
[ 1.004264] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
[ 1.007377] 44200000.uart: ttyS0 at MMIO 0x44200000 (irq = 55, base_baud = 390625) is a 16550A
[ 1.346498] console [ttyS0] enabled
[ 1.354598] ONFI param page 0 valid
[ 1.358074] ONFI flash detected
[ 1.361205] NAND device: Manufacturer ID: 0xad, Chip ID: 0xf1 (Hynix H27U1G8F2BTR-BC), 128MiB, page size: 2048, OOB size: 64
[ 1.372372] Scanning device for bad blocks
[ 1.461644] Bad eraseblock 602 at 0x000004b40000
[ 1.526184] 2 ofpart partitions found on MTD device 41000000.nand
[ 1.532254] Creating 2 MTD partitions on "41000000.nand":
[ 1.537628] 0x000000000000-0x000000e00000 : "boot"
[ 1.546375] 0x000000e00000-0x000008000000 : "data"
[ 1.567219] TCP: cubic registered
[ 1.570634] NET: Registered protocol family 10
[ 1.576115] sit: IPv6 over IPv4 tunneling driver
[ 1.582558] NET: Registered protocol family 17
[ 1.587082] 8021q: 802.1Q VLAN Support v1.8
[ 1.599324] Freeing unused kernel memory: 1152K (c03af000 - c04cf000)
Console is alive
procd: Console is alive
kmod: ran 1 iterations
- preinit -
procd: - preinit -
Press the [f] key and hit [enter] to enter failsafe mode
f
- failsafe -


BusyBox v1.19.4 (2013-11-08 15:30:25 CET) built-in shell (ash)
Enter 'help' for a list of built-in commands.

ash: can't access tty; job control turned off
_______ ________ __
| |.-----.-----.-----.| | | |.----.| |_
| - || _ | -__| || | | || _|| _|
|_______|| __|_____|__|__||________||__| |____|
|__| W I R E L E S S F R E E D O M
-----------------------------------------------------
BARRIER BREAKER (Bleeding Edge, r38695)
-----------------------------------------------------
* 1/2 oz Galliano Pour all ingredients into
* 4 oz cold Coffee an irish coffee mug filled
* 1 1/2 oz Dark Rum with crushed ice. Stir.
* 2 tsp. Creme de Cacao
-----------------------------------------------------
root@(none):/# cat /proc/cpuinfo
processor : 0
model name : ARMv6-compatible processor rev 5 (v6l)
Features : swp half thumb fastmult edsp java tls
CPU implementer : 0x41
CPU architecture: 7
CPU variant : 0x0
CPU part : 0xb02
CPU revision : 5

processor : 1
model name : ARMv6-compatible processor rev 5 (v6l)
Features : swp half thumb fastmult edsp java tls
CPU implementer : 0x41
CPU architecture: 7
CPU variant : 0x0
CPU part : 0xb02
CPU revision : 5

Hardware : PLXTECH NAS782X SoC (Flattened Device Tree)
Revision : 0000
Serial : 0000000000000000
root@(none):/# cd /sys
root@(none):/sys# cd devices
root@(none):/sys/devices# ls
40200100.ehci 44f001f0.pllb pinctrl.5
40400000.ethernet 45900000.sata platform
41000000.nand 47000600.local-timer stdclk.2
44200000.uart 47000620.watchdog sysclk.1
44400000.rps 47001000.gic system
44400200.timer gmacclk.4 twdclk.3
44e001f0.plla oscillator.0 virtual
root@(none):/sys/devices# cd /proc/device-tree
root@(none):/proc/device-tree# ls
#address-cells interrupt-parent rps@44400000
#size-cells local-timer@47000600 sata@45900000
aliases memory stdclk
chosen model sysclk
compatible name timer@44400200
cpus nand@41000000 twdclk
ehci@40200100 oscillator uart@44200000
ethernet@40400000 pinctrl watchdog@47000620
gic@47001000 plla@44e001f0
gmacclk pllb@44f001f0
root@(none):/proc/device-tree# cat model
MitraStar Technology Corp. STG-212root@(none):/proc/device-tree#
root@(none):/proc/device-tree# cd /sys/kernel/debug/clk
root@(none):/sys/kernel/debug/clk# cat clk_summary
clock enable_cnt prepare_cnt rate
---------------------------------------------------------------------
gmacclk 0 0 125000000
etha 0 0 125000000
oscillator 3 3 25000000
usbdev 0 0 25000000
ref600 0 0 25000000
pcieb 0 0 25000000
ethb 0 0 25000000
static 1 1 25000000
pciea 0 0 25000000
usbmph 0 0 25000000
audio 0 0 25000000
sata 0 0 25000000
sd 0 0 25000000
cipher 0 0 25000000
dma_sgdma 0 0 25000000
leon 0 0 25000000
pllb 0 0 25000000
plla 1 1 750000000
twdclk 0 0 375000000
sysclk 1 1 6250000

root@(none):/sys/kernel/debug/clk#
')
dangole
 
Posts: 6
Joined: Sun Nov 03, 2013 3:53 pm

Re: A new kernel for oxnas

Postby navym » Sat Nov 09, 2013 5:46 am

you can post a link here

BTW: A few days ago, another forum member seems get the kernel working on a medion based device (do not know exact model).
the versions he use are U-Boot 2013.07 and Linux-3.11.6, with PCI and NAND disabled
navym
 
Posts: 17
Joined: Tue Sep 24, 2013 2:11 am

Re: A new kernel for oxnas

Postby navym » Mon Nov 11, 2013 3:29 pm

I've rebased the changes onto 3.12 mainline kernel
https://github.com/kref/linux-oxnas/tree/v3.12

$this->bbcode_second_pass_code('', '[ 0.000000] Booting Linux on physical CPU 0x0
[ 0.000000] Linux version 3.12.0+ (mahaijun@ubuntu) (gcc version 4.7.3 (Ubuntu/Linaro 4.7.3-1ubuntu1) ) #47 SMP Sun Nov 10 15:16:56 CST 2013
[ 0.000000] CPU: ARMv6-compatible processor [410fb025] revision 5 (ARMv7), cr=00c5387d
[ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[ 0.000000] Machine: PLXTECH NAS782X SoC (Flattened Device Tree), model: plxtech,nas7820
[ 0.000000] Memory policy: ECC disabled, Data cache writealloc
[ 0.000000] On node 0 totalpages: 32768
[ 0.000000] free_area_init_node: node 0, pgdat c066dc40, node_mem_map c06ab000
[ 0.000000] Normal zone: 256 pages used for memmap
[ 0.000000] Normal zone: 0 pages reserved
[ 0.000000] Normal zone: 32768 pages, LIFO batch:7
[ 0.000000] DT missing boot CPU MPIDR[23:0], fall back to default cpu_logical_map
[ 0.000000] PERCPU: Embedded 7 pages/cpu @c07b0000 s6496 r8192 d13984 u32768
[ 0.000000] pcpu-alloc: s6496 r8192 d13984 u32768 alloc=8*4096
[ 0.000000] pcpu-alloc: [0] 0 [0] 1
[ 0.000000] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 32512
[ 0.000000] Kernel command line: console=ttyS0,115200n8 root=/dev/sda2 rootfstype=ext4 ubi.mtd=data,512
[ 0.000000] PID hash table entries: 512 (order: -1, 2048 bytes)
[ 0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
[ 0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
[ 0.000000] Memory: 123024K/131072K available (4651K kernel code, 219K rwdata, 1524K rodata, 154K init, 238K bss, 8048K reserved)
[ 0.000000] Virtual kernel memory layout:
vector : 0xffff0000 - 0xffff1000 ( 4 kB)
fixmap : 0xfff00000 - 0xfffe0000 ( 896 kB)
vmalloc : 0xc8800000 - 0xff000000 ( 872 MB)
lowmem : 0xc0000000 - 0xc8000000 ( 128 MB)
modules : 0xbf000000 - 0xc0000000 ( 16 MB)
.text : 0xc0008000 - 0xc060fe28 (6176 kB)
.init : 0xc0610000 - 0xc0636960 ( 155 kB)
.data : 0xc0638000 - 0xc066ef48 ( 220 kB)
.bss : 0xc066ef50 - 0xc06aaa14 ( 239 kB)
[ 0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
[ 0.000000] Hierarchical RCU implementation.
[ 0.000000] NR_IRQS:160
[ 0.000000] sched_clock: 24 bits at 390kHz, resolution 2560ns, wraps every 42949ms
[ 0.000000] Console: colour dummy device 80x30
[ 0.000181] Calibrating delay loop... 319.48 BogoMIPS (lpj=1597440)
[ 0.050027] pid_max: default: 32768 minimum: 301
[ 0.050234] Mount-cache hash table entries: 512
[ 0.052487] CPU: Testing write buffer coherency: ok
[ 0.052894] Setting up static identity map for 0xc046c178 - 0xc046c1d4
[ 0.054330] CPU1: Booted secondary processor
[ 0.110197] Brought up 2 CPUs
[ 0.110220] SMP: Total of 2 processors activated.
[ 0.111380] devtmpfs: initialized
[ 0.114572] pinctrl core: initialized pinctrl subsystem
[ 0.114923] NET: Registered protocol family 16
[ 0.115438] DMA: preallocated 256 KiB pool for atomic coherent allocations
[ 0.118356] gpio-oxnas 44000000.gpio: at address c8846000
[ 0.118566] gpio-oxnas 44100000.gpio: at address c8848000
[ 0.119022] pinctrl-oxnas pinctrl.5: initialized OX820 pinctrl driver
[ 0.125160] bio: create slab <bio-0> at 0
[ 0.236098] oxnas-pcie 47c00000.pcie-controller: PCIe version/deviceID 0x82510b5
[ 0.236213] oxnas-pcie 47c00000.pcie-controller: link up
[ 0.236431] oxnas-pcie 47c00000.pcie-controller: PCI host bridge to bus 0000:00
[ 0.236456] pci_bus 0000:00: root bus resource [mem 0x48000000-0x49ffffff]
[ 0.236474] pci_bus 0000:00: root bus resource [mem 0x4a000000-0x4bdfffff pref]
[ 0.236492] pci_bus 0000:00: root bus resource [io 0x4be00000-0x4befffff]
[ 0.236513] pci_bus 0000:00: root bus resource [bus 00-7f]
[ 0.236528] pci_bus 0000:00: scanning bus
[ 0.236577] pci 0000:00:00.0: [168c:002e] type 00 class 0x028000
[ 0.236618] pci 0000:00:00.0: reg 0x10: [mem 0x00000000-0x0000ffff 64bit]
[ 0.236687] pci 0000:00:00.0: calling pci_fixup_ide_bases+0x0/0x58
[ 0.236738] pci 0000:00:00.0: supports D1
[ 0.236753] pci 0000:00:00.0: PME# supported from D0 D1 D3hot
[ 0.236771] pci 0000:00:00.0: PME# disabled
[ 0.236999] pci_bus 0000:00: fixups for bus
[ 0.237022] PCI: bus0: Fast back to back transfers disabled
[ 0.237038] pci_bus 0000:00: bus scan returning with max=00
[ 0.237089] pci 0000:00:00.0: fixup irq: got 51
[ 0.237104] pci 0000:00:00.0: assigning IRQ 51
[ 0.237137] pci 0000:00:00.0: BAR 0: assigned [mem 0x48000000-0x4800ffff 64bit]
[ 0.237171] pci 0000:00:00.0: BAR 0: set to [mem 0x48000000-0x4800ffff 64bit] (PCI address [0x48000000-0x4800ffff])
[ 0.237501] vgaarb: loaded
[ 0.237895] SCSI subsystem initialized
[ 0.238187] libata version 3.00 loaded.
[ 0.238556] usbcore: registered new interface driver usbfs
[ 0.238638] usbcore: registered new interface driver hub
[ 0.238850] usbcore: registered new device driver usb
[ 0.238963] pps_core: LinuxPPS API ver. 1 registered
[ 0.238976] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[ 0.239014] PTP clock support registered
[ 0.240189] cfg80211: Calling CRDA to update world regulatory domain
[ 0.241326] Switched to clocksource rps_clocksource_timer
[ 0.254351] NET: Registered protocol family 2
[ 0.255080] TCP established hash table entries: 1024 (order: 1, 8192 bytes)
[ 0.255129] TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
[ 0.255168] TCP: Hash tables configured (established 1024 bind 1024)
[ 0.255262] TCP: reno registered
[ 0.255290] UDP hash table entries: 256 (order: 1, 8192 bytes)
[ 0.255331] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[ 0.255656] NET: Registered protocol family 1
[ 0.256143] RPC: Registered named UNIX socket transport module.
[ 0.256161] RPC: Registered udp transport module.
[ 0.256174] RPC: Registered tcp transport module.
[ 0.256184] RPC: Registered tcp NFSv4.1 backchannel transport module.
[ 0.256217] PCI: CLS 32 bytes, default 32
[ 0.270937] fuse init (API version 7.22)
[ 0.271787] msgmni has been set to 240
[ 0.275284] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 251)
[ 0.275302] io scheduler noop registered
[ 0.275312] io scheduler deadline registered
[ 0.275591] io scheduler cfq registered (default)
[ 0.276049] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
[ 0.277317] 44200000.uart: ttyS0 at MMIO 0x44200000 (irq = 55, base_baud = 390625) is a 16550A
[ 0.765058] console [ttyS0] enabled
[ 0.771886] loop: module loaded
[ 0.776020] scsi0 : sata_oxnas
[ 0.779340] ata1: SATA max UDMA/133 irq 50
[ 0.784499] ox820sata: reseting SATA core
[ 0.785175] NAND device: Manufacturer ID: 0xad, Chip ID: 0xf1 (Hynix NAND 128MiB 3,3V 8-bit), 128MiB, page size: 2048, OOB size: 64
[ 0.785200] Scanning device for bad blocks
[ 0.899422] 2 ofpart partitions found on MTD device 41000000.nand
[ 0.905512] Creating 2 MTD partitions on "41000000.nand":
[ 0.910904] 0x000000000000-0x000000e00000 : "boot"
[ 0.916958] 0x000000e00000-0x000008000000 : "data"
[ 0.923353] stmmac - user ID: 0x12, Synopsys ID: 0x35
[ 0.928381] Ring mode enabled
[ 0.931466] DMA HW capability register supported
[ 0.935974] Enhanced/Alternate descriptors
[ 0.940316] Enabled extended descriptors
[ 0.944302] RX Checksum Offload Engine supported (type 2)
[ 0.949749] TX Checksum insertion supported
[ 0.954007] Wake-Up On Lan supported
[ 0.957688] Enable RX Mitigation via HW Watchdog Timer
[ 0.965985] libphy: stmmac: probed
[ 0.969382] eth0: PHY ID 001cc914 at 0 IRQ 0 (stmmac-0:00) active
[ 0.975482] eth0: PHY ID 001cc914 at 3 IRQ 0 (stmmac-0:03)
[ 0.981104] PCI: enabling device 0000:00:00.0 (0140 -> 0142)
[ 0.986754] ath9k 0000:00:00.0: enabling bus mastering
[ 1.074959] ath: EEPROM regdomain: 0x6a
[ 1.074974] ath: EEPROM indicates we should expect a direct regpair map
[ 1.074992] ath: Country alpha2 being used: 00
[ 1.075002] ath: Regpair used: 0x6a
[ 1.078576] ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
[ 1.079805] ieee80211 phy0: Atheros AR9287 Rev:2 mem=0xc8860000, irq=51
[ 1.086522] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[ 1.093058] ehci-pci: EHCI PCI platform driver
[ 1.097730] oxnas-ehci 40200100.ehci: EHCI Host Controller
[ 1.103272] oxnas-ehci 40200100.ehci: new USB bus registered, assigned bus number 1
[ 1.111037] oxnas-ehci 40200100.ehci: irq 39, io mem 0x40200100
[ 1.129991] oxnas-ehci 40200100.ehci: USB 2.0 started, EHCI 1.00
[ 1.136261] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
[ 1.143073] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[ 1.150279] usb usb1: Product: EHCI Host Controller
[ 1.155146] usb usb1: Manufacturer: Linux 3.12.0+ ehci_hcd
[ 1.160622] usb usb1: SerialNumber: 40200100.ehci
[ 1.166085] hub 1-0:1.0: USB hub found
[ 1.169896] hub 1-0:1.0: 2 ports detected
[ 1.174579] usbcore: registered new interface driver usb-storage
[ 1.180794] usbcore: registered new interface driver usbserial
[ 1.186652] usbcore: registered new interface driver ch341
[ 1.192194] usbserial: USB Serial support registered for ch341-uart
[ 1.198484] usbcore: registered new interface driver pl2303
[ 1.204098] usbserial: USB Serial support registered for pl2303
[ 1.210293] mousedev: PS/2 mouse device common for all mice
[ 1.216107] usbcore: registered new interface driver usbhid
[ 1.221698] usbhid: USB HID core driver
[ 1.225797] TCP: cubic registered
[ 1.230195] NET: Registered protocol family 10
[ 1.236075] sit: IPv6 over IPv4 tunneling driver
[ 1.241515] NET: Registered protocol family 17
[ 1.248174] UBI: attaching mtd1 to ubi0
[ 1.314444] ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
[ 1.322076] ata1.00: ATA-6: ST3120827AS, 3.42, max UDMA/133
[ 1.327656] ata1.00: 234441648 sectors, multi 0: LBA48 NCQ (depth 0/32)
[ 1.335884] ata1.00: configured for UDMA/133
[ 1.340723] scsi 0:0:0:0: Direct-Access ATA ST3120827AS 3.42 PQ: 0 ANSI: 5
[ 1.350110] sd 0:0:0:0: [sda] 234441648 512-byte logical blocks: (120 GB/111 GiB)
[ 1.358039] sd 0:0:0:0: [sda] Write Protect is off
[ 1.362849] sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
[ 1.363072] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[ 1.378728] sda: sda1 sda2 sda3
[ 1.384225] sd 0:0:0:0: [sda] Attached SCSI disk
[ 1.494607] usb 1-1: new high-speed USB device number 2 using oxnas-ehci
[ 1.581875] UBI: scanning is finished
[ 1.604848] UBI warning: print_rsvd_warning: cannot reserve enough PEBs for bad PEB handling, reserved 9, need 20
[ 1.616442] UBI: attached mtd1 (name "data", size 114 MiB) to ubi0
[ 1.622599] UBI: PEB size: 131072 bytes (128 KiB), LEB size: 129024 bytes
[ 1.629378] UBI: min./max. I/O unit sizes: 2048/2048, sub-page size 512
[ 1.635975] UBI: VID header offset: 512 (aligned 512), data offset: 2048
[ 1.642644] UBI: good PEBs: 912, bad PEBs: 0, corrupted PEBs: 0
[ 1.648547] UBI: user volume: 1, internal volumes: 1, max. volumes count: 128
[ 1.651722] usb 1-1: New USB device found, idVendor=05e3, idProduct=0608
[ 1.651735] usb 1-1: New USB device strings: Mfr=0, Product=1, SerialNumber=0
[ 1.651742] usb 1-1: Product: USB2.0 Hub
[ 1.652661] hub 1-1:1.0: USB hub found
[ 1.653102] hub 1-1:1.0: 4 ports detected
[ 1.680993] UBI: max/mean erase counter: 2/1, WL threshold: 4096, image sequence number: 0
[ 1.689231] UBI: available PEBs: 0, total reserved PEBs: 912, PEBs reserved for bad PEB handling: 9
[ 1.698293] UBI: background thread "ubi_bgt0d" started, PID 55
[ 1.732313] EXT4-fs (sda2): mounted filesystem with ordered data mode. Opts: (null)
[ 1.740032] VFS: Mounted root (ext4 filesystem) readonly on device 8:2.
[ 1.768832] devtmpfs: mounted
[ 1.772039] Freeing unused kernel memory: 152K (c0610000 - c0636000)')
navym
 
Posts: 17
Joined: Tue Sep 24, 2013 2:11 am

Re: A new kernel for oxnas

Postby Socaltom » Mon Nov 11, 2013 6:05 pm

What are the requirements for this kernel? does it support ext3 rootfs?
Tom

$this->bbcode_second_pass_quote('navym', 'I')'ve rebased the changes onto 3.12 mainline kernel
https://github.com/kref/linux-oxnas/tree/v3.12

$this->bbcode_second_pass_code('', '[ 0.000000] Booting Linux on physical CPU 0x0
[ 0.000000] Linux version 3.12.0+ (mahaijun@ubuntu) (gcc version 4.7.3 (Ubuntu/Linaro 4.7.3-1ubuntu1) ) #47 SMP Sun Nov 10 15:16:56 CST 2013
[ 0.000000] CPU: ARMv6-compatible processor [410fb025] revision 5 (ARMv7), cr=00c5387d
[ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[ 0.000000] Machine: PLXTECH NAS782X SoC (Flattened Device Tree), model: plxtech,nas7820
[ 0.000000] Memory policy: ECC disabled, Data cache writealloc
[ 0.000000] On node 0 totalpages: 32768
[ 0.000000] free_area_init_node: node 0, pgdat c066dc40, node_mem_map c06ab000
[ 0.000000] Normal zone: 256 pages used for memmap
[ 0.000000] Normal zone: 0 pages reserved
[ 0.000000] Normal zone: 32768 pages, LIFO batch:7
[ 0.000000] DT missing boot CPU MPIDR[23:0], fall back to default cpu_logical_map
[ 0.000000] PERCPU: Embedded 7 pages/cpu @c07b0000 s6496 r8192 d13984 u32768
[ 0.000000] pcpu-alloc: s6496 r8192 d13984 u32768 alloc=8*4096
[ 0.000000] pcpu-alloc: [0] 0 [0] 1
[ 0.000000] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 32512
[ 0.000000] Kernel command line: console=ttyS0,115200n8 root=/dev/sda2 rootfstype=ext4 ubi.mtd=data,512
[ 0.000000] PID hash table entries: 512 (order: -1, 2048 bytes)
[ 0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
[ 0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
[ 0.000000] Memory: 123024K/131072K available (4651K kernel code, 219K rwdata, 1524K rodata, 154K init, 238K bss, 8048K reserved)
[ 0.000000] Virtual kernel memory layout:
vector : 0xffff0000 - 0xffff1000 ( 4 kB)
fixmap : 0xfff00000 - 0xfffe0000 ( 896 kB)
vmalloc : 0xc8800000 - 0xff000000 ( 872 MB)
lowmem : 0xc0000000 - 0xc8000000 ( 128 MB)
modules : 0xbf000000 - 0xc0000000 ( 16 MB)
.text : 0xc0008000 - 0xc060fe28 (6176 kB)
.init : 0xc0610000 - 0xc0636960 ( 155 kB)
.data : 0xc0638000 - 0xc066ef48 ( 220 kB)
.bss : 0xc066ef50 - 0xc06aaa14 ( 239 kB)
[ 0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
[ 0.000000] Hierarchical RCU implementation.
[ 0.000000] NR_IRQS:160
[ 0.000000] sched_clock: 24 bits at 390kHz, resolution 2560ns, wraps every 42949ms
[ 0.000000] Console: colour dummy device 80x30
[ 0.000181] Calibrating delay loop... 319.48 BogoMIPS (lpj=1597440)
[ 0.050027] pid_max: default: 32768 minimum: 301
[ 0.050234] Mount-cache hash table entries: 512
[ 0.052487] CPU: Testing write buffer coherency: ok
[ 0.052894] Setting up static identity map for 0xc046c178 - 0xc046c1d4
[ 0.054330] CPU1: Booted secondary processor
[ 0.110197] Brought up 2 CPUs
[ 0.110220] SMP: Total of 2 processors activated.
[ 0.111380] devtmpfs: initialized
[ 0.114572] pinctrl core: initialized pinctrl subsystem
[ 0.114923] NET: Registered protocol family 16
[ 0.115438] DMA: preallocated 256 KiB pool for atomic coherent allocations
[ 0.118356] gpio-oxnas 44000000.gpio: at address c8846000
[ 0.118566] gpio-oxnas 44100000.gpio: at address c8848000
[ 0.119022] pinctrl-oxnas pinctrl.5: initialized OX820 pinctrl driver
[ 0.125160] bio: create slab <bio-0> at 0
[ 0.236098] oxnas-pcie 47c00000.pcie-controller: PCIe version/deviceID 0x82510b5
[ 0.236213] oxnas-pcie 47c00000.pcie-controller: link up
[ 0.236431] oxnas-pcie 47c00000.pcie-controller: PCI host bridge to bus 0000:00
[ 0.236456] pci_bus 0000:00: root bus resource [mem 0x48000000-0x49ffffff]
[ 0.236474] pci_bus 0000:00: root bus resource [mem 0x4a000000-0x4bdfffff pref]
[ 0.236492] pci_bus 0000:00: root bus resource [io 0x4be00000-0x4befffff]
[ 0.236513] pci_bus 0000:00: root bus resource [bus 00-7f]
[ 0.236528] pci_bus 0000:00: scanning bus
[ 0.236577] pci 0000:00:00.0: [168c:002e] type 00 class 0x028000
[ 0.236618] pci 0000:00:00.0: reg 0x10: [mem 0x00000000-0x0000ffff 64bit]
[ 0.236687] pci 0000:00:00.0: calling pci_fixup_ide_bases+0x0/0x58
[ 0.236738] pci 0000:00:00.0: supports D1
[ 0.236753] pci 0000:00:00.0: PME# supported from D0 D1 D3hot
[ 0.236771] pci 0000:00:00.0: PME# disabled
[ 0.236999] pci_bus 0000:00: fixups for bus
[ 0.237022] PCI: bus0: Fast back to back transfers disabled
[ 0.237038] pci_bus 0000:00: bus scan returning with max=00
[ 0.237089] pci 0000:00:00.0: fixup irq: got 51
[ 0.237104] pci 0000:00:00.0: assigning IRQ 51
[ 0.237137] pci 0000:00:00.0: BAR 0: assigned [mem 0x48000000-0x4800ffff 64bit]
[ 0.237171] pci 0000:00:00.0: BAR 0: set to [mem 0x48000000-0x4800ffff 64bit] (PCI address [0x48000000-0x4800ffff])
[ 0.237501] vgaarb: loaded
[ 0.237895] SCSI subsystem initialized
[ 0.238187] libata version 3.00 loaded.
[ 0.238556] usbcore: registered new interface driver usbfs
[ 0.238638] usbcore: registered new interface driver hub
[ 0.238850] usbcore: registered new device driver usb
[ 0.238963] pps_core: LinuxPPS API ver. 1 registered
[ 0.238976] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[ 0.239014] PTP clock support registered
[ 0.240189] cfg80211: Calling CRDA to update world regulatory domain
[ 0.241326] Switched to clocksource rps_clocksource_timer
[ 0.254351] NET: Registered protocol family 2
[ 0.255080] TCP established hash table entries: 1024 (order: 1, 8192 bytes)
[ 0.255129] TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
[ 0.255168] TCP: Hash tables configured (established 1024 bind 1024)
[ 0.255262] TCP: reno registered
[ 0.255290] UDP hash table entries: 256 (order: 1, 8192 bytes)
[ 0.255331] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[ 0.255656] NET: Registered protocol family 1
[ 0.256143] RPC: Registered named UNIX socket transport module.
[ 0.256161] RPC: Registered udp transport module.
[ 0.256174] RPC: Registered tcp transport module.
[ 0.256184] RPC: Registered tcp NFSv4.1 backchannel transport module.
[ 0.256217] PCI: CLS 32 bytes, default 32
[ 0.270937] fuse init (API version 7.22)
[ 0.271787] msgmni has been set to 240
[ 0.275284] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 251)
[ 0.275302] io scheduler noop registered
[ 0.275312] io scheduler deadline registered
[ 0.275591] io scheduler cfq registered (default)
[ 0.276049] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
[ 0.277317] 44200000.uart: ttyS0 at MMIO 0x44200000 (irq = 55, base_baud = 390625) is a 16550A
[ 0.765058] console [ttyS0] enabled
[ 0.771886] loop: module loaded
[ 0.776020] scsi0 : sata_oxnas
[ 0.779340] ata1: SATA max UDMA/133 irq 50
[ 0.784499] ox820sata: reseting SATA core
[ 0.785175] NAND device: Manufacturer ID: 0xad, Chip ID: 0xf1 (Hynix NAND 128MiB 3,3V 8-bit), 128MiB, page size: 2048, OOB size: 64
[ 0.785200] Scanning device for bad blocks
[ 0.899422] 2 ofpart partitions found on MTD device 41000000.nand
[ 0.905512] Creating 2 MTD partitions on "41000000.nand":
[ 0.910904] 0x000000000000-0x000000e00000 : "boot"
[ 0.916958] 0x000000e00000-0x000008000000 : "data"
[ 0.923353] stmmac - user ID: 0x12, Synopsys ID: 0x35
[ 0.928381] Ring mode enabled
[ 0.931466] DMA HW capability register supported
[ 0.935974] Enhanced/Alternate descriptors
[ 0.940316] Enabled extended descriptors
[ 0.944302] RX Checksum Offload Engine supported (type 2)
[ 0.949749] TX Checksum insertion supported
[ 0.954007] Wake-Up On Lan supported
[ 0.957688] Enable RX Mitigation via HW Watchdog Timer
[ 0.965985] libphy: stmmac: probed
[ 0.969382] eth0: PHY ID 001cc914 at 0 IRQ 0 (stmmac-0:00) active
[ 0.975482] eth0: PHY ID 001cc914 at 3 IRQ 0 (stmmac-0:03)
[ 0.981104] PCI: enabling device 0000:00:00.0 (0140 -> 0142)
[ 0.986754] ath9k 0000:00:00.0: enabling bus mastering
[ 1.074959] ath: EEPROM regdomain: 0x6a
[ 1.074974] ath: EEPROM indicates we should expect a direct regpair map
[ 1.074992] ath: Country alpha2 being used: 00
[ 1.075002] ath: Regpair used: 0x6a
[ 1.078576] ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
[ 1.079805] ieee80211 phy0: Atheros AR9287 Rev:2 mem=0xc8860000, irq=51
[ 1.086522] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[ 1.093058] ehci-pci: EHCI PCI platform driver
[ 1.097730] oxnas-ehci 40200100.ehci: EHCI Host Controller
[ 1.103272] oxnas-ehci 40200100.ehci: new USB bus registered, assigned bus number 1
[ 1.111037] oxnas-ehci 40200100.ehci: irq 39, io mem 0x40200100
[ 1.129991] oxnas-ehci 40200100.ehci: USB 2.0 started, EHCI 1.00
[ 1.136261] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
[ 1.143073] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[ 1.150279] usb usb1: Product: EHCI Host Controller
[ 1.155146] usb usb1: Manufacturer: Linux 3.12.0+ ehci_hcd
[ 1.160622] usb usb1: SerialNumber: 40200100.ehci
[ 1.166085] hub 1-0:1.0: USB hub found
[ 1.169896] hub 1-0:1.0: 2 ports detected
[ 1.174579] usbcore: registered new interface driver usb-storage
[ 1.180794] usbcore: registered new interface driver usbserial
[ 1.186652] usbcore: registered new interface driver ch341
[ 1.192194] usbserial: USB Serial support registered for ch341-uart
[ 1.198484] usbcore: registered new interface driver pl2303
[ 1.204098] usbserial: USB Serial support registered for pl2303
[ 1.210293] mousedev: PS/2 mouse device common for all mice
[ 1.216107] usbcore: registered new interface driver usbhid
[ 1.221698] usbhid: USB HID core driver
[ 1.225797] TCP: cubic registered
[ 1.230195] NET: Registered protocol family 10
[ 1.236075] sit: IPv6 over IPv4 tunneling driver
[ 1.241515] NET: Registered protocol family 17
[ 1.248174] UBI: attaching mtd1 to ubi0
[ 1.314444] ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
[ 1.322076] ata1.00: ATA-6: ST3120827AS, 3.42, max UDMA/133
[ 1.327656] ata1.00: 234441648 sectors, multi 0: LBA48 NCQ (depth 0/32)
[ 1.335884] ata1.00: configured for UDMA/133
[ 1.340723] scsi 0:0:0:0: Direct-Access ATA ST3120827AS 3.42 PQ: 0 ANSI: 5
[ 1.350110] sd 0:0:0:0: [sda] 234441648 512-byte logical blocks: (120 GB/111 GiB)
[ 1.358039] sd 0:0:0:0: [sda] Write Protect is off
[ 1.362849] sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
[ 1.363072] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[ 1.378728] sda: sda1 sda2 sda3
[ 1.384225] sd 0:0:0:0: [sda] Attached SCSI disk
[ 1.494607] usb 1-1: new high-speed USB device number 2 using oxnas-ehci
[ 1.581875] UBI: scanning is finished
[ 1.604848] UBI warning: print_rsvd_warning: cannot reserve enough PEBs for bad PEB handling, reserved 9, need 20
[ 1.616442] UBI: attached mtd1 (name "data", size 114 MiB) to ubi0
[ 1.622599] UBI: PEB size: 131072 bytes (128 KiB), LEB size: 129024 bytes
[ 1.629378] UBI: min./max. I/O unit sizes: 2048/2048, sub-page size 512
[ 1.635975] UBI: VID header offset: 512 (aligned 512), data offset: 2048
[ 1.642644] UBI: good PEBs: 912, bad PEBs: 0, corrupted PEBs: 0
[ 1.648547] UBI: user volume: 1, internal volumes: 1, max. volumes count: 128
[ 1.651722] usb 1-1: New USB device found, idVendor=05e3, idProduct=0608
[ 1.651735] usb 1-1: New USB device strings: Mfr=0, Product=1, SerialNumber=0
[ 1.651742] usb 1-1: Product: USB2.0 Hub
[ 1.652661] hub 1-1:1.0: USB hub found
[ 1.653102] hub 1-1:1.0: 4 ports detected
[ 1.680993] UBI: max/mean erase counter: 2/1, WL threshold: 4096, image sequence number: 0
[ 1.689231] UBI: available PEBs: 0, total reserved PEBs: 912, PEBs reserved for bad PEB handling: 9
[ 1.698293] UBI: background thread "ubi_bgt0d" started, PID 55
[ 1.732313] EXT4-fs (sda2): mounted filesystem with ordered data mode. Opts: (null)
[ 1.740032] VFS: Mounted root (ext4 filesystem) readonly on device 8:2.
[ 1.768832] devtmpfs: mounted
[ 1.772039] Freeing unused kernel memory: 152K (c0610000 - c0636000)')
used to be owned by me
Pink Pogo V2, Black Pogo V3, Zyxel NAS 325 v1,
used to be Adminstrator for
Goflex net, Black V3, Black V2
Now I have a couple of raspberry pi ( 3+ and 4)
Socaltom
 
Posts: 571
Joined: Thu Apr 07, 2011 2:21 pm
Location: The left side

Re: A new kernel for oxnas

Postby dangole » Wed Nov 13, 2013 7:15 pm

Thank you navym!!!
Both, your Kernel 3.12 and U-Boot (I rebased your patches on top of U-Boot 2013.10) work perfectly now in my OpenWrt tree:
https://gitorious.org/openwrt-oxnas/openwrt-oxnas/
Everything seems to work, see my bootlog on
http://wiki.openwrt.org/toh/medion/md86587

OpenWrt can boot be loaded from NAND by U-Boot and have either a built-in ramdisk, use UBIFS or GLUBI+squashfs on top of the NAND or directly use a filesystem on the SATA disk. If you need a fully-featured distribution, you can use pacstrap (or debootstrap or whatever) inside OpenWrt :)

Have fun!
dangole
 
Posts: 6
Joined: Sun Nov 03, 2013 3:53 pm

Re: A new kernel for oxnas

Postby celemine1gig » Wed Nov 13, 2013 8:08 pm

Very nice! ;)
Now the most interesting question, at least from my point of view:
How about some benchmarks, showing USB and SATA transfer rates. That is where the newer kernels struggled (a bit) so far. Best values are still on kernel 2.6.31.14 at the moment. Would be great to see some numbers.
I am going to do some testing on my own in a few days, maybe. But, if someone else is faster, please let me and of course the others know.
celemine1gig
 
Posts: 54
Joined: Fri Apr 26, 2013 7:55 pm

Re: A new kernel for oxnas

Postby dangole » Thu Nov 21, 2013 11:03 pm

From what I read, SATA performance is probably what matters most here:
$this->bbcode_second_pass_code('', '
root@OpenWrt:~# cat /proc/scsi/scsi
Attached devices:
Host: scsi0 Channel: 00 Id: 00 Lun: 00
Vendor: ATA Model: ST1000DM003-9YN1 Rev: NDP3
Type: Direct-Access ANSI SCSI revision: 05
root@OpenWrt:~# hdparm -t /dev/sda

/dev/sda:
Timing buffered disk reads: 212 MB in 3.02 seconds = 70.31 MB/sec

root@OpenWrt:~# time dd if=/dev/zero of=/mnt/data/testfile bs=64k count=10k
10240+0 records in
10240+0 records out
real 0m 19.24s
user 0m 0.11s
sys 0m 16.44s
')

The above filesystem write speed (on ext4 mounted with -o rw,nosuid,nodev,noexec,relatime,data=writeback,async) is probably not very precise, it shows ~ 33MB/s write speed.

Besides that, I'm quite happy with the general system performance. Feels fast and slick compared to a SheevaPlug or other kirkwood/orion based ARMv5 devices I touched before. Besides the usual OpenWrt gear (uhttpd, LuCI web gui, ...) I run lighttpd, two php-fcgi instances, mysql, transmission-web and samba. and though after a couple of days a significant amount of swap space is used, it still works fast and nice.
I wasn't really able to exhaust the ethernet NIC performance as my laptop only got a shitty ATL1C aka. AR8151 kills my system with interrupts at about 300MBit/s RX and doesn't really support Jumbo Frames...
So the performance of about 35MB/s load I see in samba transfers between the oxnas and my laptop was probably bottle-knecked by my laptops shitty NIC... The stmac driver however does seem to support full-sized real Jumbo Frames which might already help a lot to improve performance of huge data transfers (given that the other end also supports that).
dangole
 
Posts: 6
Joined: Sun Nov 03, 2013 3:53 pm

Re: A new kernel for oxnas

Postby celemine1gig » Fri Nov 22, 2013 7:03 pm

I'm in the process of compiling a test kernel. One really positive thing that I noticed is power management.
If I am not mistaking, then there is a working CPU-Idle driver, runtime power management etc..
If that works, this could save a (percentally seen) significant amount of power on these OX820 devices.

I'm really excited to see the first results firsthand.
celemine1gig
 
Posts: 54
Joined: Fri Apr 26, 2013 7:55 pm

PreviousNext

Return to Community Supported

Who is online

Users browsing this forum: No registered users and 11 guests