[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_op
From: |
Jamie Lokier |
Subject: |
Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd. |
Date: |
Mon, 28 Jul 2008 12:59:29 +0100 |
User-agent: |
Mutt/1.5.13 (2006-08-11) |
Gerd Hoffmann wrote:
> > Btw, I've just tested. In the initial state, the tty side never
> > opened, read() blocks and poll/select report that it's not ready for
> > read.
>
> You still don't know whenever someone is connected or not.
> And thus you still don't know whenever the stuff you write to the
> tty is read out by someone or you risk to block when the kernel
> buffer is full.
That's no different from someone connected to the tty and not reading.
Is the problem that you want qemu to block when they do that?
> Also note that openpty() which is used by qemu gives you an open file
> handle for the tty side, so there is no "tty never opened" state.
Sure, but it's easy enough to use openpt(), grantpt() and unlockpt()
instead, as described in the Glibc manual.
-- Jamie
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., (continued)
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Anthony Liguori, 2008/07/23
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Daniel P. Berrange, 2008/07/24
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Anthony Liguori, 2008/07/24
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Jamie Lokier, 2008/07/24
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Gerd Hoffmann, 2008/07/24
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Paul Brook, 2008/07/24
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Anthony Liguori, 2008/07/24
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Gerd Hoffmann, 2008/07/25
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Jamie Lokier, 2008/07/25
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Gerd Hoffmann, 2008/07/28
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd.,
Jamie Lokier <=
- Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Gerd Hoffmann, 2008/07/28
- [Qemu-devel] Re: [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Anthony Liguori, 2008/07/24
- [Qemu-devel] Re: [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Gerd Hoffmann, 2008/07/25
- [Qemu-devel] Re: [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Anthony Liguori, 2008/07/25
- [Qemu-devel] Re: [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Gerd Hoffmann, 2008/07/28
- [Qemu-devel] Re: [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Anthony Liguori, 2008/07/28
Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Kevin Wolf, 2008/07/23
Re: [Qemu-devel] [PATCH 2/3] Always use nonblocking mode for qemu_chr_open_fd., Gerd Hoffmann, 2008/07/23