Received: from [140.186.70.92] (port=54014 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OBUBj-0004uy-3a for qemu-devel@nongnu.org; Mon, 10 May 2010 10:42:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OBUBc-0007QO-Hb for qemu-devel@nongnu.org; Mon, 10 May 2010 10:42:30 -0400 Received: from vsmtp05.dti.ne.jp ([202.216.231.140]:36268) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OBUBb-0007P9-Oj for qemu-devel@nongnu.org; Mon, 10 May 2010 10:42:24 -0400 Message-ID: <4BE81B39.1040101@juno.dti.ne.jp> Date: Mon, 10 May 2010 23:42:01 +0900 From: Shin-ichiro KAWASAKI MIME-Version: 1.0 Subject: Re: [Qemu-devel] qemu-system-sh4 broken again. References: <201003130151.36065.rob@landley.net> <201003131711.44849.rob@landley.net> <20100314212832.GE2381@hall.aurel32.net> <201003141908.41360.rob@landley.net> In-Reply-To: <201003141908.41360.rob@landley.net> Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Rob Landley Cc: qemu-devel@nongnu.org, Aurelien Jarno Hello, Rob, This mail might be too late, but I want to report you that I encountered similar trouble. Using the linux kernel after the following commit, the qemu-sh serial console shows no output. cd5f107628ab89c5dec5ad923f1c27f4cba41972 This trouble was discussed in sh-linux ML. http://marc.info/?l=linux-sh&m=127183863325672&w=2 To avoid this, - add "earlyprintk=sh-sci.1" to kernel command line, and - modify CONFIG_SERIAL_SH_SCI_NR_UARTS valud from 1 to 2, in kernel configuration menu. I hope that this is the trouble you see. Regards, Shin-ichiro KAWASAKI (2010/03/15 9:08), Rob Landley wrote: > On Sunday 14 March 2010 16:28:32 Aurelien Jarno wrote: >> On Sat, Mar 13, 2010 at 05:11:43PM -0600, Rob Landley wrote: >>> I found out that "-serial stdio" is apparently trying to open /dev/stdio, >>> which Ubuntu 9.04 hasn't got. If I say -serial /dev/tty it works from >>> the command line (but not in scripts). >> >> This is actually not specific at all to sh4. See this thread: >> http://www.mail-archive.com/qemu-devel@nongnu.org/msg20920.html > > http://www.mail-archive.com/qemu-devel@nongnu.org/msg22763.html > >> This is redundant. -nographic implies -serial stdio. > > Trying with just -nographic and no -serial lines, I get: > > $ qemu-system-sh4 -M r2d -nographic -no-reboot -kernel zImage-sh4 -hda image- > sh4.sqf -append "root=/dev/sda rw init=/usr/sbin/init.sh panic=1 PATH=/usr/bin > console=ttySC0 noiotrap HOST=sh4" > long read to SH7750_WCR1_A7 (0x000000001f800008) ignored > long read to SH7750_WCR2_A7 (0x000000001f80000c) ignored > long read to SH7750_WCR3_A7 (0x000000001f800010) ignored > long read to SH7750_MCR_A7 (0x000000001f800014) ignored > long read to SH7750_MCR_A7 (0x000000001f800014) ignored > > And it hangs. No output from any of the kernel serial writes. > > http://www.mail-archive.com/qemu-devel@nongnu.org/msg22775.html > >>> eg this should work as you'd expect it >>> >>> qemu -nodefaults -nographic -serial stdio >> >> -nographic is basically equivalent to -serial mon:stdio,signal=on -vga none >> except it operates on defaults. Your invocation actually ends up being very >> different as it doesn't multiplex the monitor and it doesn't disable ctrl-c. >> Basically, your invocation is equivalent to qemu -vga none -serial stdio > > http://www.mail-archive.com/qemu-devel@nongnu.org/msg22775.html > > $ qemu-system-sh4 -M r2d -nographic -no-reboot -kernel zImage-sh4 -hda image- > sh4.sqf -append "root=/dev/sda rw init=/usr/sbin/init.sh panic=1 PATH=/usr/bin > console=ttySC0 noiotrap HOST=sh4" -vga none -serial stdio > chardev: opening backend "stdio" failed > qemu: could not open serial device 'stdio': Inappropriate ioctl for device > > http://www.mail-archive.com/qemu-devel@nongnu.org/msg22777.html > > $ qemu-system-sh4 -M r2d -nodefaults -nographic -serial stdio -no-reboot - > kernel zImage-sh4 -hda image-sh4.sqf -append "root=/dev/sda rw > init=/usr/sbin/init.sh panic=1 PATH=/usr/bin console=ttySC0 noiotrap HOST=sh4" > long read to SH7750_WCR1_A7 (0x000000001f800008) ignored > long read to SH7750_WCR2_A7 (0x000000001f80000c) ignored > long read to SH7750_WCR3_A7 (0x000000001f800010) ignored > long read to SH7750_MCR_A7 (0x000000001f800014) ignored > long read to SH7750_MCR_A7 (0x000000001f800014) ignored > > And the hang's back, no output... > > Ok, this seems to work: > > qemu-system-sh4 -M r2d -nodefaults -nographic -serial null -serial stdio -no- > reboot -kernel zImage-sh4 -hda image-sh4.sqf -append "root=/dev/sda rw > init=/usr/sbin/init.sh panic=1 PATH=/usr/bin console=ttySC0 noiotrap HOST=sh4" > > I no longer even pretend to know why... > > Do I have to say "-nodefaults" on every other target as well to disable the > unwanted monitor I never knew was there? > > Rob