qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PULL v4 00/35] Misc patches for 2018-12-21
Date: Fri, 4 Jan 2019 13:59:16 +0100	[thread overview]
Message-ID: <0ce7ff3a-4c7f-460c-feba-d5873b491b01@redhat.com> (raw)
In-Reply-To: <CAFEAcA9QKYc89Fknmz-MGSGv11eSTuvNYjsf+-sqsAGT=ZYQ3g@mail.gmail.com>

On 04/01/19 12:31, Peter Maydell wrote:
> I'll give this a go, but I think this will not necessarily be
> sufficient if some program invoked by make sets the O_NONBLOCK flag,
> and then make later in the same run tries to output and gets EINTR.
> Perhaps it would be better to put it in the test harness that
> invokes test binaries, so as to clear the flag as soon
> as possible? It could also then in theory print a warning
> if a test case had put stdin/stdout into non-blocking mode.

Aha, you gave me the clue I needed. :)  gtester redirected stdin/out/err
to /dev/null.

In the new harness, stdout is piped into tap-driver.pl, but everything
else is left in place.  Leaving stderr should be safe, while stdin is
the most likely culprit.  Adding </dev/null to the test invocation
should fix it; I'll send a new pull request either today or next Monday.

> (The semantics of O_NONBLOCK here seem to me to be completely
> broken. But they are what they are...)

Yes, and F_SETFL is not the only "interesting" fcntl in this respect;
fortunately QEMU is not using F_SETOWN anymore!

Paolo

  reply	other threads:[~2019-01-04 12:59 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-21 12:36 [Qemu-devel] [PULL v4 00/35] Misc patches for 2018-12-21 Paolo Bonzini
2018-12-21 12:36 ` [Qemu-devel] [PULL 22/35] test: execute g_test_run when tests are skipped Paolo Bonzini
2018-12-21 12:36 ` [Qemu-devel] [PULL 23/35] test: replace gtester with a TAP driver Paolo Bonzini
2018-12-21 21:09 ` [Qemu-devel] [PULL v4 00/35] Misc patches for 2018-12-21 Peter Maydell
2018-12-22  8:41   ` Paolo Bonzini
2018-12-22 11:26     ` Peter Maydell
2019-01-03 18:37     ` Peter Maydell
2019-01-04  7:59       ` Paolo Bonzini
2019-01-04 10:06         ` Peter Maydell
2019-01-04 11:01           ` Paolo Bonzini
2019-01-04 11:31             ` Peter Maydell
2019-01-04 12:59               ` Paolo Bonzini [this message]
2019-01-04 13:03         ` Peter Maydell
2019-01-04 13:34           ` Paolo Bonzini
2019-01-04 13:45           ` Peter Maydell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0ce7ff3a-4c7f-460c-feba-d5873b491b01@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).