From: "Michael S. Tsirkin" <mst@redhat.com>
To: Blue Swirl <blauwirbel@gmail.com>
Cc: qemu-devel@nongnu.org
Subject: [Qemu-devel] Re: [PULL] vhost,e1000 fixes
Date: Mon, 20 Sep 2010 21:21:22 +0200 [thread overview]
Message-ID: <20100920192122.GI30611@redhat.com> (raw)
In-Reply-To: <AANLkTik33-2WDFXefGPpdtf7jho14VEjrjthFViUTZRc@mail.gmail.com>
On Mon, Sep 20, 2010 at 06:23:55PM +0000, Blue Swirl wrote:
> On Mon, Sep 20, 2010 at 6:08 PM, Michael S. Tsirkin <mst@redhat.com> wrote:
> > This fixes a bug in vhost error handling
> > (also triggers build warning with vhost enabled)
> > and fixes e1000 handling of short frames.
> >
> > Discussion on best ways to fix the e1000 issue
> > is still ongoing but the bug is severe enough
> > for some guests and the fix is safe enough
> > that I feel we should have it fixed ASAP
> > and look for that perfect approach later.
> >
> > Both fixes are 0.13 material IMO.
> >
> > The following changes since commit 952afb719f3c965bae12b5bd5f0f0f7ed0251cb8:
> >
> > mingw: use ASLR, no-SEH and DEP if available (2010-09-19 08:36:34 +0000)
> >
> > are available in the git repository at:
> > git://git.kernel.org/pub/scm/linux/kernel/git/mst/qemu.git for_anthony
> >
> > Michael S. Tsirkin (1):
> > vhost: fix infinite loop on error path
>
> I don't think your fix is correct either, it will call the ioctl()
> with file.index == -1.
This is my patch:
- while (--file.index >= 0) {
+ while (file.index-- > 0) {
int r = ioctl(net->dev.control, VHOST_NET_SET_BACKEND, &file);
assert(r >= 0);
}
For ioctl to get called with -1, index needs to be 0
before the decrement, and while won't be entered ...
what am I missing?
> How about int i; for (i = file.index; i >= 0;
> i--) { file.index = i;... ?
next prev parent reply other threads:[~2010-09-20 19:27 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-09-20 18:08 [Qemu-devel] [PULL] vhost,e1000 fixes Michael S. Tsirkin
2010-09-20 18:23 ` [Qemu-devel] " Anthony Liguori
2010-09-20 18:23 ` Blue Swirl
2010-09-20 19:21 ` Michael S. Tsirkin [this message]
2010-09-20 19:35 ` Blue Swirl
2010-09-20 19:45 ` Michael S. Tsirkin
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=20100920192122.GI30611@redhat.com \
--to=mst@redhat.com \
--cc=blauwirbel@gmail.com \
--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).