Hacking TL-MR3020 – Part 4 – Qemu test
Qemu with RootFS of TL-MR3020
This tutorial should show, how it is possible to set-up a Qemu virtualized environment.
DRAFT!
$dd if=/dev/zero of=myFileSystem.img bs=1024 count=65536 $sudo mke2fs myFileSystem.img $sudo mkdir /mnt/virtual $sudo mount -o loop myFileSystem.img /mnt/virtual
$sudo cp -R * /mnt/virtual/
Copy files from extracted squashfs to /mnt/virtualized
$sudo mknod -m 622 /mnt/virtual/dev/console c 5 1 $sudo chmod 777 /mnt/virtual/dev/console
Malta kernel for MIPS
https://people.debian.org/~aurel32/qemu/mips/
$ sudo qemu-system-mips -M malta -kernel 'vmlinux-2.6.32-5-4kc-malta' -nographic -append "init=/sbin/init root=/dev/sda rootfstype=ext2" -hda 'myFileSystem.img'
Add cross-compiler source
$sudo nano /etc/apt/source.list
#Embedian deb http://ftp.de.debian.org/debian squeeze main deb http://www.emdebian.org/debian/ squeeze main
$sudo apt-get install emdebian-archive-keyring
$cp arch/mips/configs/malta_defconfig .config
$ make menuconfig
$ make CROSS_COMPILE=mips-linux-gnu-
Leave a Reply