Issue
thank you for read my problem. I'm going to debug mips assembly on QEMU environment. But I was confronted some problem.
I typed this command
qemu-system-mipsel -M malta -kernel vmlinux-2.6.32-5-5kc-malta -hda debian_squeeze_mipsel_standard.qcow2 -append "root=/dev/sda1" -redir tcp:4444::4444 -nographic
And qemu-system-mipsel said me an error
-redir tcp:4444::4444: The -redir option is deprecated. Please use '-netdev user,hostfwd=...' instead.
If -redir
option is deprecated, how change my command using by -netdev
option???
What's more strange is qemu-system-mipsel -M malta -kernel vmlinux-3.2.0-4-4kc-malta -hda debian_wheezy_mipsel_standard.qcow2 -append "root=/dev/sda1" -redir tcp:4444::4444 -nographic
command is successful on debian_wheezy_mipsel
environment!
Is this only debian_squeeze_mipsel
problem?
But I can't use debian_wheezy_mipsel
... this version couldn't operate apt-get package
well. So, I couldn't debug mips binary using by gdb or gcc.
Thank you:)
Solution
The QEMU project documents the replacements for deprecated-and-then-removed features in https://wiki.qemu.org/Features/RemovedFeatures -- in this case it says:
The -redir [tcp|udp]:hostport:[guestaddr]:guestport argument is replaced by either -netdev user,id=x,hostfwd=[tcp|udp]:[hostaddr]:hostport-[guestaddr]:guestport (for pluggable NICs, accompanied with -device …,netdev=x) or -nic user,hostfwd=[tcp|udp]:[hostaddr]:hostport-[guestaddr]:guestport (for embedded NICs). The new syntax allows different settings to be provided per NIC.
The feature was deprecated in QEMU v2.6.0 and dropped entirely in v3.1.0. So QEMU versions before 2.6 will not complain; QEMU between 2.6 and 3.0 will produce the deprecation warning but work the same as older versions; and 3.1 and later will refuse to start because they don't recognize the option.
In your case I think the malta board uses a pluggable 'pcnet' PCI card, which would imply that you want the "-netdev user,id=x,hostfwd=... -device pcnet,netdev=x" of the two options above. If that doesn't work, try the other instead.
Answered By - Peter Maydell
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.