# mount
rootfs on / type rootfs (rw)
/dev/root on / type yaffs (rw,relatime)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,relatime)
/dev/shm on /tmp type tmpfs (rw,relatime,size=20m)
/dev/mtdblock9 on /tmp/squashfs type yaffs (rw,relatime)
/dev/loop0 on /opt type squashfs (ro,relatime)
/dev/mtdblock11 on /var/opt/onkyo/avr/etc type yaffs (rw,relatime)
/dev/root on /dev/.static/dev type yaffs (rw,relatime)
tmpfs on /dev type tmpfs (rw,relatime,size=10M,mode=0755)
usbfs on /proc/bus/usb type usbfs (rw,relatime)
# df -h
Filesystem Size Used Available Use% Mounted on
rootfs 8.0M 6.7M 1.3M 84% /
/dev/root 8.0M 6.7M 1.3M 84% /
/dev/mtdblock9 9.5M 8.9M 600.0k 94% /tmp/squashfs
/dev/loop0 8.9M 8.9M 0 100% /opt
/dev/mtdblock11 1.4M 1.3M 124.0k 91% /var/opt/onkyo/avr/etc
/dev/root 8.0M 6.7M 1.3M 84% /dev/.static/dev
# ps -w
PID USER VSZ STAT COMMAND
1 root 1112 S init
2 root 0 SW [kthreadd]
3 root 0 SW [ksoftirqd/0]
4 root 0 SW [events/0]
5 root 0 SW [khelper]
9 root 0 SW [async/mgr]
52 root 0 SW [sync_supers]
54 root 0 SW [bdi-default]
55 root 0 SW [kblockd/0]
80 root 0 SW [kswapd0]
81 root 0 SW [aio/0]
82 root 0 SW [crypto/0]
120 root 0 SW [mtdblockd]
160 root 0 SW [spi_davinci.0]
171 root 0 SW [spi_davinci.1]
209 root 0 SW< [loop0]
218 root 35780 S N /opt/onkyo/avr/bin/Audioappe
223 root 1120 S -sh
224 root 127m S N /opt/onkyo/avr/bin/netapp
229 root 9832 S N /opt/onkyo/avr/bin/spid
239 root 0 SW< [DSPLINK_DPC_0]
240 root 0 SW< [DSPLINK_DPC_1]
241 root 0 SW< [DSPLINK_DPC_2]
243 root 0 SW< [DSPLINK_DPC_3]
284 cgi 820 S N thttpd -C /etc/thttpd.conf -l /dev/null
294 root 1100 S N /bin/sh /opt/onkyo/avr/bin/thttpd_alive_check
369 root 576 S < udevd --daemon
521 root 0 SW [khubd]
562 root 0 SW [usbhid_resumer]
606 root 0 SW [cfg80211]
717 root 1112 S N udhcpc -b -R -p /var/run/udhcpc.eth0.pid -i eth0
780 root 516 S N /opt/onkyo/avr/bin/AmxBcast -e eth0 -b ONKYO -p TX-NR509 -v 0.0...0 -c 60128 -d
791 root 696 S N /opt/onkyo/avr/bin/lld2d -t 20 eth0
1753 root 1092 S N sleep 5
1755 root 1100 R ps -w
Startup
# cd /etc/rc.d/rcS.d/
# ls -la
drwxr-xr-x 1 root root 512 Jan 14 2011 .
drwxr-xr-x 1 root root 512 Jan 14 2011 ..
lrwxrwxrwx 1 root root 16 Jan 1 00:00 S01netapp -> ../init.d/netapp
lrwxrwxrwx 1 root root 22 Jan 1 00:00 S02audioapp -> ../init.d/audioappe.sh
# more ../init.d/netapp
#!/bin/sh
APP=/opt/onkyo/avr/bin/netapp
NETAPP_NODEBUG=1
MOUNT_DIR=/mnt/squashfs
BLOCK_DIR=/dev/mtdblock9
FS_OPT_NAME=da83x_rootfs_opt.img
USER_BLOCK_DIR=/dev/mtdblock11
USER_MOUNT_DIR=/var/opt/onkyo/avr/etc
device_mount()
{
mount -t proc proc /proc
mkdir -p /sys
mount -t sysfs sysfs /sys
mount -t tmpfs -o rw,size=20m /dev/shm /tmp
if [ ! -d $MOUNT_DIR ]; then
mkdir -p $MOUNT_DIR
fi
if [ -f /etc/boot_bk.properties ]; then
mv /etc/boot_bk.properties /etc/boot.properties
fi
if [ -f /etc/boot.properties ]; then
BLOCK__DIR=`cat /etc/boot.properties | grep '^optfs=' | cut -d= -f2`
if [ -n $BLOCK__DIR ]; then
BLOCK_DIR=$BLOCK__DIR
fi
fi
if [ -e /etc/rc.d/rcS.d/S00debug ]; then
source /etc/init.d/debug setcore
fi
echo $BLOCK_DIR
mount -t yaffs $BLOCK_DIR $MOUNT_DIR
mount -t squashfs -o loop $MOUNT_DIR/$FS_OPT_NAME /opt
echo $USER_BLOCK_DIR
mount -t yaffs $USER_BLOCK_DIR $USER_MOUNT_DIR
chmod 755 $USER_BLOCK_DIR $USER_MOUNT_DIR
VAR_AVR_DIR=/var/opt/onkyo/avr
PFS_DATA_DIR=/var/opt/onkyo/avr/etc
PFS_ORIGDATA_DIR=/opt/onkyo/avr/etc/pfsInfo
PREPRO_FILE="PreProCode.dat"
INI_FILE="INI"
if [ -f $PFS_DATA_DIR/$INI_FILE ]; then
if [ -f $PFS_DATA_DIR/$PREPRO_FILE ]; then
mv $PFS_DATA_DIR/$PREPRO_FILE $VAR_AVR_DIR
fi
rm -rf $PFS_DATA_DIR/*
if [ -f $VAR_AVR_DIR/$PREPRO_FILE ]; then
mv -f $VAR_AVR_DIR/$PREPRO_FILE $PFS_DATA_DIR
fi
fi
USER_FILE="sirinfo.usr.dat"
if [ ! -f $PFS_DATA_DIR/$USER_FILE ]; then
cp $PFS_ORIGDATA_DIR/* $PFS_DATA_DIR/ -a
fi
PFS_PREPRODATA_DIR=/opt/onkyo/avr/etc/prepro
if [ ! -f $PFS_DATA_DIR/$PREPRO_FILE ]; then
cp $PFS_PREPRODATA_DIR/* $PFS_DATA_DIR/ -a
fi
PFS_DATA_DIR=/var/opt/onkyo/avr/etc
PFS_AUDIODATA_DIR=/opt/onkyo/avr/etc/audio
AUDYSSEY_FILE="AudysseyFilter.dat"
if [ ! -f $PFS_DATA_DIR/$AUDYSSEY_FILE ]; then
cp $PFS_AUDIODATA_DIR/* $PFS_DATA_DIR/ -a
fi
}
case "$1" in
start|restart)
device_mount
#$APP -d $NETAPP_NODEBUG
;;
stop)
killall $APP
;;
status)
;;
*)
echo "Usage: $0 {start|stop|status|restart}"
exit 1
;;
esac
# lsmod
snd_usb_audio 48580 0 - Live 0xbf256000
snd_hwdep 3484 1 snd_usb_audio, Live 0xbf250000
snd_usb_lib 11460 1 snd_usb_audio, Live 0xbf24b000
snd_rawmidi 13040 1 snd_usb_lib, Live 0xbf242000
snd_soc_evm 1592 0 - Live 0xbf23c000
snd_soc_davinci_mcasp 5056 1 snd_soc_evm, Live 0xbf235000
snd_soc_davinci 4400 1 snd_soc_evm, Live 0xbf22e000
snd_soc_tlv320aic3x 18244 1 snd_soc_evm, Live 0xbf224000
snd_soc_core 26001 4 snd_soc_evm,snd_soc_davinci_mcasp,snd_soc_davinci,snd_soc_tlv320aic3x, Live 0xbf218000
snd_pcm_oss 30532 0 - Live 0xbf20b000
snd_pcm 48456 4 snd_usb_audio,snd_soc_davinci,snd_soc_core,snd_pcm_oss, Live 0xbf1fa000
snd_page_alloc 2316 1 snd_pcm, Live 0xbf1f4000
snd_timer 14236 1 snd_pcm, Live 0xbf1eb000
snd 29604 8 snd_usb_audio,snd_hwdep,snd_usb_lib,snd_rawmidi,snd_soc_core,snd_pcm_oss,snd_pcm,snd_timer, Live 0xbf1de000
soundcore 3804 1 snd, Live 0xbf1d8000
ath9k_htc 31540 0 - Live 0xbf1cb000
ath9k_common 1084 1 ath9k_htc, Live 0xbf1c5000
ath9k_hw 253164 2 ath9k_htc,ath9k_common, Live 0xbf182000
ath 9828 2 ath9k_htc,ath9k_hw, Live 0xbf17d000
compat_firmware_class 53564 1 ath9k_htc, Live 0xbf16a000
compat 1172 0 - Live 0xbf164000
mac80211 148264 1 ath9k_htc, Live 0xbf13a000
cfg80211 100780 4 ath9k_htc,ath9k_hw,ath,mac80211, Live 0xbf11c000
sg 18048 0 - Live 0xbf112000
sd_mod 14040 0 - Live 0xbf109000
nls_ascii 2768 0 - Live 0xbf103000
nls_euc_jp 4124 0 - Live 0xbf0fc000
nls_cp932 76716 1 - Live 0xbf0e4000
nls_utf8 704 0 - Live 0xbf0de000
msdos 4996 0 - Live 0xbf0d7000
vfat 7176 0 - Live 0xbf0d0000
fat 35584 2 msdos,vfat, Live 0xbf0c2000
ntfs 84552 0 - Live 0xbf0a8000
usbhid 17464 0 - Live 0xbf09e000
hid 30284 1 usbhid, Live 0xbf091000
input_core 16096 3 snd,usbhid,hid, Live 0xbf088000
usb_storage 23648 0 - Live 0xbf07d000
scsi_mod 58160 3 sg,sd_mod,usb_storage, Live 0xbf069000
usb_libusual 7320 1 usb_storage, Live 0xbf062000
musb_hdrc 17616 0 - Live 0xbf058000
nop_usb_xceiv 940 1 musb_hdrc, Live 0xbf052000
ohci_hcd 12360 0 - Live 0xbf049000
usbcore 79628 10 snd_usb_audio,snd_usb_lib,ath9k_htc,compat,usbhid,usb_storage,usb_libusual,musb_hdrc,ohci_hcd, Live 0xbf030000
i2c_davinci 3106 0 - Live 0xbf02a000
i2c_dev 3688 0 - Live 0xbf024000
i2c_core 9748 4 snd_soc_tlv320aic3x,snd_soc_core,i2c_davinci,i2c_dev, Live 0xbf01c000
dsplinkk 93860 0 - Live 0xbf000000
# netstat -a -e -p
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:60128 0.0.0.0:* LISTEN 225/netapp
tcp 0 0 0.0.0.0:www 0.0.0.0:* LISTEN 284/thttpd
tcp 0 0 0.0.0.0:8888 0.0.0.0:* LISTEN 225/netapp
tcp 0 0 10.0.2.187:8888 10.0.2.115:49963 TIME_WAIT -
tcp 0 0 10.0.2.187:8888 10.0.2.115:49970 TIME_WAIT -
tcp 0 0 10.0.2.187:8888 10.0.2.115:49965 TIME_WAIT -
tcp 0 0 10.0.2.187:www 10.0.2.115:49969 TIME_WAIT -
tcp 0 0 10.0.2.187:8888 10.0.2.115:49959 TIME_WAIT -
tcp 0 0 10.0.2.187:34448 10.0.2.187:8888 TIME_WAIT -
tcp 0 0 10.0.2.187:34450 10.0.2.187:8888 TIME_WAIT -
tcp 0 0 10.0.2.187:34446 10.0.2.187:8888 TIME_WAIT -
tcp 0 0 10.0.2.187:34452 10.0.2.187:8888 TIME_WAIT -
tcp 0 0 10.0.2.187:34451 10.0.2.187:8888 TIME_WAIT -
tcp 0 0 10.0.2.187:34449 10.0.2.187:8888 TIME_WAIT -
tcp 0 0 10.0.2.187:8888 10.0.2.115:49967 TIME_WAIT -
tcp 0 0 10.0.2.187:8888 10.0.2.115:49972 TIME_WAIT -
tcp 0 0 10.0.2.187:34447 10.0.2.187:8888 TIME_WAIT -
tcp 0 0 10.0.2.187:60128 10.0.1.99:49790 ESTABLISHED 225/netapp
tcp 0 0 10.0.2.187:34445 10.0.2.187:8888 TIME_WAIT -
tcp 0 0 10.0.2.187:59528 10.0.2.115:2869 TIME_WAIT -
tcp 0 0 10.0.2.187:8888 10.0.2.115:49971 TIME_WAIT -
tcp 0 0 10.0.2.187:59529 10.0.2.115:2869 TIME_WAIT -
netstat: /proc/net/tcp6: No such file or directory
udp 0 0 localhost.localdomain:52767 0.0.0.0:* 225/netapp
udp 0 0 0.0.0.0:1900 0.0.0.0:* 225/netapp
udp 0 0 10.0.2.187:39390 0.0.0.0:* 225/netapp
udp 0 0 0.0.0.0:60128 0.0.0.0:* 225/netapp
udp 0 0 10.0.2.187:60669 0.0.0.0:* 225/netapp
netstat: /proc/net/udp6: No such file or directory
netstat: /proc/net/raw6: No such file or directory
Active UNIX domain sockets (servers and established)
Proto RefCnt Flags Type State I-Node PID/Program name Path
unix 2 [ ACC ] STREAM LISTENING 282 225/netapp /tmp/ISCP_CONTROL_SOCK
unix 2 [ ] DGRAM 35 230/spid /tmp/ipc_system
unix 2 [ ] DGRAM 37 218/Audioappe /tmp/audio_server
unix 2 [ ] DGRAM 42 225/netapp /tmp/netapp_server
unix 2 [ ] DGRAM 336 370/udevd @/org/kernel/udev/udevd
unix 2 [ ACC ] STREAM LISTENING 1667 225/netapp /tmp/ISCP_CONTROL_SOCK_READ26
unix 2 [ ] DGRAM 46 230/spid
unix 2 [ ] DGRAM 44 230/spid
# cat cpuinfo
Processor : ARM926EJ-S rev 5 (v5l)
BogoMIPS : 148.27
Features : swp half thumb fastmult edsp java
CPU implementer : 0x41
CPU architecture: 5TEJ
CPU variant : 0x0
CPU part : 0x926
CPU revision : 5
Hardware : DaVinci DA830/OMAP-L137/AM17xx EVM
Revision : 0000
Serial : 0000000000000000
# cat meminfo
MemTotal: 54724 kB
MemFree: 1760 kB
Buffers: 7312 kB
Cached: 31840 kB
SwapCached: 0 kB
Active: 6068 kB
Inactive: 38932 kB
Active(anon): 2416 kB
Inactive(anon): 3432 kB
Active(file): 3652 kB
Inactive(file): 35500 kB
Unevictable: 0 kB
Mlocked: 0 kB
SwapTotal: 0 kB
SwapFree: 0 kB
Dirty: 0 kB
Writeback: 0 kB
AnonPages: 5864 kB
Mapped: 8104 kB
Shmem: 0 kB
Slab: 4220 kB
SReclaimable: 2172 kB
SUnreclaim: 2048 kB
KernelStack: 496 kB
PageTables: 272 kB
NFS_Unstable: 0 kB
Bounce: 0 kB
WritebackTmp: 0 kB
CommitLimit: 27360 kB
Committed_AS: 158212 kB
VmallocTotal: 960512 kB
VmallocUsed: 4064 kB
VmallocChunk: 955580 kB
cat /proc/mtd
dev: size erasesize name
mtd0: 00004000 00004000 "params"
mtd1: 00010000 00004000 "2ndbl"
mtd2: 00040000 00004000 "bootloader"
mtd3: 00100000 00004000 "dsp1"
mtd4: 00100000 00004000 "dsp2"
mtd5: 00140000 00004000 "kernel"
mtd6: 00004000 00004000 "bootconf1"
mtd7: 00004000 00004000 "bootconf2"
mtd8: 00800000 00004000 "filesystem1"
mtd9: 00980000 00004000 "filesystem2"
mtd10: 00980000 00004000 "filesystem3"
mtd11: 00164000 00004000 "filesystem4"
cat /proc/yaffs
YAFFS built:Dec 13 2011 10:52:11
$Id: yaffs_fs.c,v 1.79 2009-03-17 01:12:00 wookey Exp $
$Id: yaffs_guts.c,v 1.82 2009-03-09 04:24:17 charles Exp $
Device 0 "filesystem1"
startBlock......... 0
endBlock........... 511
totalBytesPerChunk. 512
nDataBytesPerChunk. 512
chunkGroupBits..... 0
chunkGroupSize..... 1
nErasedBlocks...... 45
nReservedBlocks.... 5
blocksInCheckpoint. 0
nTnodesCreated..... 1200
nFreeTnodes........ 98
nObjectsCreated.... 800
nFreeObjects....... 77
nFreeChunks........ 3008
nPageWrites........ 8
nPageReads......... 20890
nBlockErasures..... 0
nGCCopies.......... 0
garbageCollections. 0
passiveGCs......... 0
nRetriedWrites..... 0
nShortOpCaches..... 10
nRetireBlocks...... 0
eccFixed........... 0
eccUnfixed......... 0
tagsEccFixed....... 0
tagsEccUnfixed..... 0
cacheHits.......... 0
nDeletedFiles...... 0
nUnlinkedFiles..... 0
nBackgroudDeletions 0
useNANDECC......... 1
isYaffs2........... 0
inbandTags......... 0
Device 1 "filesystem3"
startBlock......... 0
endBlock........... 607
totalBytesPerChunk. 512
nDataBytesPerChunk. 512
chunkGroupBits..... 0
chunkGroupSize..... 1
nErasedBlocks...... 17
nReservedBlocks.... 5
blocksInCheckpoint. 0
nTnodesCreated..... 1400
nFreeTnodes........ 50
nObjectsCreated.... 100
nFreeObjects....... 95
nFreeChunks........ 575
nPageWrites........ 0
nPageReads......... 74355
nBlockErasures..... 0
nGCCopies.......... 0
garbageCollections. 0
passiveGCs......... 0
nRetriedWrites..... 0
nShortOpCaches..... 10
nRetireBlocks...... 0
eccFixed........... 0
eccUnfixed......... 0
tagsEccFixed....... 1
tagsEccUnfixed..... 0
cacheHits.......... 0
nDeletedFiles...... 0
nUnlinkedFiles..... 0
nBackgroudDeletions 0
useNANDECC......... 1
isYaffs2........... 0
inbandTags......... 0
Device 2 "filesystem4"
startBlock......... 0
endBlock........... 88
totalBytesPerChunk. 512
nDataBytesPerChunk. 512
chunkGroupBits..... 0
chunkGroupSize..... 1
nErasedBlocks...... 7
nReservedBlocks.... 5
blocksInCheckpoint. 0
nTnodesCreated..... 300
nFreeTnodes........ 99
nObjectsCreated.... 100
nFreeObjects....... 39
nFreeChunks........ 443
nPageWrites........ 57
nPageReads......... 343
nBlockErasures..... 1
nGCCopies.......... 7
garbageCollections. 1
passiveGCs......... 0
nRetriedWrites..... 0
nShortOpCaches..... 10
nRetireBlocks...... 0
eccFixed........... 0
eccUnfixed......... 0
tagsEccFixed....... 1
tagsEccUnfixed..... 2
cacheHits.......... 0
nDeletedFiles...... 0
nUnlinkedFiles..... 0
nBackgroudDeletions 0
useNANDECC......... 1
isYaffs2........... 0
inbandTags......... 0