qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: Stefan Hajnoczi <stefanha@redhat.com>
Cc: qemu-devel <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] net/tap.c: Possibly a way to stall tap input
Date: Fri, 02 Aug 2013 09:45:17 +0200	[thread overview]
Message-ID: <51FB638D.8030109@siemens.com> (raw)
In-Reply-To: <20130802073319.GB20399@stefanha-thinkpad.redhat.com>

On 2013-08-02 09:33, Stefan Hajnoczi wrote:
> On Thu, Aug 01, 2013 at 07:24:13PM +0200, Jan Kiszka wrote:
>> On 2013-08-01 19:15, Jan Kiszka wrote:
>>> Hi all,
>>>
>>> I'm tracking down a nasty stall of tap input over a custom 1.3.x QEMU
>>> version. Under certain load, our tap backend stops reading from the char
>>> device, and that even if we reset the guest. The frontend device
>>> (pcnet32) is able to receive (can_receive would return > 0), but the
>>    ^^^^^^^
>> Yes, the pcnet lacks qemu_flush_queued_packets, like certain other NIC
>> models already have. We added that to pcnet_init and pcnet_start (patch
>> will follow), but that didn't make a difference, likely due to what I
>> described below.
> 
> Yes, you need to add qemu_flush_queued_packets() where the guest enables
> RX or marks RX descriptors free (usually by writing to a hardware
> register to update the RX ring index).

For the pcnet, this is different as can_receive checks for stop and
suspend states.

> 
> Please also confirm that you are using -netdev tap -device pcnet32
> instead of the legacy -net syntax.  The reason I'm asking is because I
> remember the same issue with net/hub.c, which gets in the way if you use
> legacy syntax (see 199ee608).

We are using legacy syntax. But my analysis of the issue in tap.c
appears to be independent of other networking components. Possibly,
other setup paper over it, but the conceptual issue remains.

Jan

-- 
Siemens AG, Corporate Technology, CT RTC ITP SES-DE
Corporate Competence Center Embedded Linux

  reply	other threads:[~2013-08-02  7:45 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-01 17:15 [Qemu-devel] net/tap.c: Possibly a way to stall tap input Jan Kiszka
2013-08-01 17:24 ` Jan Kiszka
2013-08-02  7:33   ` Stefan Hajnoczi
2013-08-02  7:45     ` Jan Kiszka [this message]
2013-08-02 11:46 ` Stefan Hajnoczi
2013-08-02 12:45   ` Jan Kiszka
2013-08-02 16:49     ` Jan Kiszka
2013-08-02 19:41     ` Jan Kiszka
2013-08-05 11:38       ` Stefan Hajnoczi

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=51FB638D.8030109@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@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).