qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] Monitor Readline - no terminal echo after exit


From: Markus Armbruster
Subject: Re: [Qemu-devel] Monitor Readline - no terminal echo after exit
Date: Fri, 25 Apr 2014 10:42:22 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux)

Mike Day <address@hidden> writes:

> On Thu, Apr 24, 2014 at 3:31 AM, Markus Armbruster <address@hidden> wrote:
>>> I believe someone on the list mentioned they are seeing a couple
>>> problems entering and exiting the Monitor. I'd like to look at this more
>>> closely, starting with my most pending issue: losing the terminal echo
>>> after exiting the Monitor.
>
> Thanks for the reply Markus.
>
>> Reproducer?
>
> I've found a couple of ways to reproduce the problem. The easiest is
> to use -nographic on the qemu command line when starting a qemu
> session. In this case the monitor opens stdio but there is no visible
> input or output.

-nographic without -nodefaults sets up a default serial line and a
monitor, multiplexed onto stdio.  Another way to get that is -serial
mon:stdio.

Maybe the multiplexing has regressed.  I'm not sure, as I don't use it
myself.  Gerd (cc'ed) might know more.

You could try old versions to confirm it's a regression, and if it is,
bisect it.

> Another way is to use -nographic along with -mon <chardev =
> stdio>,mode=readline. In this case the monitor works, but when you
> exit from the monitor your terminal will not echo characters.

I can't reproduce that problem.  Probably because I'm not taking the
exact same steps as you do.  Common problem with reproducers lacking
detail.

> For reference, here are the chardev and mon options I use:
>
>  -chardev stdio,id=mon0 -mon chardev=mon0,mode=readline
>
> I see that -nographic is a deprecated option, fwiw.

Yes, because it does several losely related things, what exactly it does
depends on many conditions, and nobody can predict what it does without
reading the code (and sometimes not even then).

The recommended way to suppress the display is --display none.  Then set
up monitor and serial to taste with --mon and --chardev.  If the default
magic gets in the way, whack it with --nodefaults.

>> The monitor runs on top of a QEMU chardev.  Suggest to start digging at
>> monitor_init(), both into the monitor itself, and into the
>> CharDriverState object.
>
> Thus far I've confirmed that when the -nographic option is passed, the
> mon_init_func does not get called (as it does for readline mode). I
> know why this is, but I'm not yet sure the right way to fix it.  Also,
> with -nographic and mon:stdio  monitor_flush is called for every line
> entered execpt for the last line. Normally monitor_flush is called for
> every line including the last line, at least in readline mode.
>
> I've run out of time looking at this today, but would but would be
> happy if anyone has further ideas.

Hope this helps a bit.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]