From: Peter Maydell <peter.maydell@linaro.org>
To: qemu-devel@nongnu.org
Cc: "Paolo Bonzini" <pbonzini@redhat.com>,
"Thomas Huth" <thuth@redhat.com>,
"Laurent Vivier" <laurent@vivier.eu>,
"Marc-André Lureau" <marcandre.lureau@redhat.com>
Subject: [PATCH 0/2] chardev/char-file: Allow setting input file on command line
Date: Thu, 13 Apr 2023 16:07:22 +0100 [thread overview]
Message-ID: <20230413150724.404304-1-peter.maydell@linaro.org> (raw)
Our 'file' chardev backend supports specifying both an
input and an output file, but only if you create it via
the QMP interface -- there is no command-line syntax
support for setting the input file. This patchset adds
an extra 'input-path' option to the chardev.
The specific use case I have is that I'd like to be able to
feed fuzzer reproducer input into qtest without having to use
'-qtest stdio' and put the input onto stdin. Being able to
use a file chardev like this:
-chardev file,id=repro,path=/dev/null,input-path=repro.txt -qtest chardev:repro
means that stdio is free for use by gdb.
The first patch in the series fixes an assertion failure
in the qtest code if you try to pass it a named chardev;
the second patch adds the new option to the file backend.
thanks
-- PMM
Peter Maydell (2):
qtest: Don't assert on "-qtest chardev:myid"
chardev: Allow setting file chardev input file on the command line
chardev/char-file.c | 8 ++++++++
chardev/char.c | 3 +++
softmmu/qtest.c | 2 +-
qemu-options.hx | 10 ++++++++--
4 files changed, 20 insertions(+), 3 deletions(-)
--
2.34.1
next reply other threads:[~2023-04-13 15:08 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-13 15:07 Peter Maydell [this message]
2023-04-13 15:07 ` [PATCH 1/2] qtest: Don't assert on "-qtest chardev:myid" Peter Maydell
2023-04-14 14:50 ` Thomas Huth
2023-04-14 19:01 ` Marc-André Lureau
2023-04-13 15:07 ` [PATCH 2/2] chardev: Allow setting file chardev input file on the command line Peter Maydell
2023-04-14 14:03 ` Philippe Mathieu-Daudé
2023-04-14 14:21 ` Peter Maydell
2023-04-14 14:52 ` Thomas Huth
2023-04-14 19:33 ` Marc-André Lureau
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=20230413150724.404304-1-peter.maydell@linaro.org \
--to=peter.maydell@linaro.org \
--cc=laurent@vivier.eu \
--cc=marcandre.lureau@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=thuth@redhat.com \
/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).