From: Paolo Bonzini <pbonzini@redhat.com>
To: Chunyan Liu <cyliu@suse.com>, Michael Tokarev <mjt@tls.msk.ru>,
Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>,
qemu-devel <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH][resend] Add -f option to qemu-nbd
Date: Thu, 19 Jan 2012 10:34:19 +0100 [thread overview]
Message-ID: <4F17E39B.6030503@redhat.com> (raw)
In-Reply-To: <CAERYnobB2TVUym=RcGgPx-ahL8YZ=tmc_YCqH4MWP-B4m=KFsg@mail.gmail.com>
On 01/19/2012 10:16 AM, Chunyan Liu wrote:
>> > Yes, that's true. He could have two definitions (SOCKET_PATH with %d and
>> > SOCKET_PATH_HELP without) so that the occurrences would stay close in the
>> > source code.
> Not clear how it will use SOCKET_PATH and SOCKET_PATH_HELP.
> SOCKET_PATH_HELP stores the abstract string of sock path? (e.g.
> /var/lock/qemu-nbd-xxx)
Yes (s/xxx/PID/).
>> Yes, though actually ENOENT is an important special case that is worth
>> reporting to the user. It happens when the nbd module is not loaded.
> If nbd module is not loaded, open device will fail, we can add error info:
> fd = open(device, O_RDWR);
> if (fd == -1) {
> fprintf(stderr, "Failed to open %s\n", device);
> continue;
> }
> And in next place, if using err instead of fprintf, it will print ENOENT error
> message. Is that enough?
You do not need this fprintf. Otherwise, yes.
Please build your patch on top of git://github.com/bonzini/qemu.git,
branch nbd-next.
Thanks,
Paolo
prev parent reply other threads:[~2012-01-19 9:34 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-18 8:48 [Qemu-devel] [PATCH][resend] Add -f option to qemu-nbd Chunyan Liu
2012-01-18 10:51 ` Paolo Bonzini
2012-01-19 8:52 ` Chunyan Liu
2012-01-19 9:03 ` Paolo Bonzini
2012-01-18 10:56 ` Michael Tokarev
2012-01-18 11:26 ` Paolo Bonzini
2012-01-19 9:16 ` Chunyan Liu
2012-01-19 9:34 ` Paolo Bonzini [this message]
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=4F17E39B.6030503@redhat.com \
--to=pbonzini@redhat.com \
--cc=cyliu@suse.com \
--cc=mjt@tls.msk.ru \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@linux.vnet.ibm.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.