All of lore.kernel.org
 help / color / mirror / Atom feed
From: Markus Armbruster <armbru@redhat.com>
To: Amos Kong <akong@redhat.com>
Cc: lcapitulino@redhat.com, qemu-devel@nongnu.org,
	stefanha@redhat.com, mst@redhat.com
Subject: Re: [Qemu-devel] [PATCH v3 2/2] net: introduce command to query rx-filter information
Date: Fri, 12 Jul 2013 08:32:29 +0200	[thread overview]
Message-ID: <87ip0ge1aa.fsf@blackfin.pond.sub.org> (raw)
In-Reply-To: <20130711140501.GA9449@amosk.info> (Amos Kong's message of "Thu, 11 Jul 2013 22:05:01 +0800")

Amos Kong <akong@redhat.com> writes:

> On Thu, Jul 04, 2013 at 08:28:59AM +0200, Markus Armbruster wrote:
>> Amos Kong <akong@redhat.com> writes:
>> 
>> > On Tue, Jul 02, 2013 at 03:27:12PM +0200, Markus Armbruster wrote:
>> >> Amos Kong <akong@redhat.com> writes:
>> >> 
>> >> > On Tue, Jul 02, 2013 at 11:05:56AM +0200, Markus Armbruster wrote:
>> >> >> Amos Kong <akong@redhat.com> writes:
>> >> [...]
>> >> >> >> This interface is abstract in the sense that it applies to
>> >> >> >> all NICs.  At
>> >> >> >> this time, it's implemented only virtio-net implements it.  I'm
>> >> >> >> habitually wary of abstractions based on just one concrete instance,
>> >> >> >> which makes me ask:
>> >> >> >> 
>> >> >> >> 1. Ignorant question first: could the feature make sense
>> >> >> >> for other NICs,
>> >> >> >> too, or is it specific to virtio-net?
>> >> >> >
>> >> >> > We will not. 
>> >> >> >
>> >> >> > It's ugly to check if nic is virtio-net nic in net/net.c, so I
>> >> >> > register the query function to NetClientInfo. Traversal the net
>> >> >> > client list in net/net.c, and execute query of each virtio-net
>> >> >> > instance in virtio-net.c
>> >> >> 
>> >> >> Implementing the feature as an optional callback is fine.
>> >> >> 
>> >> >> Let me rephrase my question: could this feature be implemented for other
>> >> >> NICs?  I'm *not* asking you to do that, just whether it would be
>> >> >> possible.
>> >> >> 
>> >> >> I'm asking because my review of the QAPI schema depends on the answer.
>> >> >> 
>> >> >> >> 2. If the former, are you reasonably sure this object will
>> >> >> >> do for other
>> >> >> >> NICs?
>> >> >> >
>> >> >> > No.
>> >> >> 
>> >> >> I'm not sure I understand you.  Do you mean to say that the feature
>> >> >> could be implemented for other NICs, but RxFilterInfo would probably not
>> >> >> fit for them?
>> >> >
>> >> > We will not implement the feature to other NICs, no request.
>> >> >
>> >> > We notify the management of virtio-net rx-filter change, because
>> >> > we want to sync the the rx-filter change to macvtap device.
>> >> 
>> >> I understand there are no plans to implement this feature for other
>> >> NICs.  But I'm not asking whether we *want* to implement it for other
>> >> NICs, I'm asking whether we *could*.
>> >  
>> > In theory, we can.
>> >
>> >> Or rephrased yet another way: what exactly makes this feature applicable
>> >> to virtio-net only?
>> >
>> > Macvtap can only be used by virtio-net, not other emulated nic.
>> > It's meaningless for management to know the rx-filter change of
>> > non-virtio-net NICs.
>> 
>> I'm having trouble squaring "in theory, we can" with "meaningless".  So
>> I'm rephrasing my question yet again.
>> 
>> Do NICs other than virtio-net have rx-filters?
>  
> Yes.
>
> Talked with Jason, upstream kernel fixed some bugs, then we can also
> use e1000 with macvtap. In this case, we should also implement a
> .query_rx_filter function for e1000. We can do it by another patchset.

Yes.  Just to avoid misunderstandings: I'm not asking you for that.  I
merely asked whether it's possible, and you answered that.

>> If yes, what have these NIC rx-filters in common, and how do they
>> differ?
>> 
>> Why would anybody want to query rx-filters?  Use cases, please.
>
> It's a way to tell management the rx-filter setup in guest nic.
> Management query the rx-filter setup of guest, then change the
> setup of macvtap device, macvtap uses same rx-filter setup as
> virtual nic.

So this use case is "mirror the virtual NIC's rx-filter setup to
macvtap".  Makes sense.

This leads me to the question I've been aiming for all along: will your
definition of RxFilterInfo do for devices other than virtio-net?

It should do if it contains only stuff that all NICs with an rx-filter
have.  Is that the case?

[...]

  reply	other threads:[~2013-07-12  6:32 UTC|newest]

Thread overview: 47+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-23  9:07 [Qemu-devel] [PATCH v3 0/2] mac programming over macvtap Amos Kong
2013-05-23  9:07 ` [Qemu-devel] [PATCH v3 1/2] net: introduce RX_FILTER_CHANGED event Amos Kong
2013-05-23 10:24   ` Michael S. Tsirkin
2013-05-23 14:28     ` Luiz Capitulino
2013-05-23 14:43       ` Michael S. Tsirkin
2013-05-23 14:52         ` Eric Blake
2013-05-23 14:57           ` Michael S. Tsirkin
2013-05-23 15:33             ` Luiz Capitulino
2013-05-24  3:20               ` Amos Kong
2013-05-23 12:01   ` Eric Blake
2013-06-26  6:54     ` Markus Armbruster
2013-06-26 13:53       ` Luiz Capitulino
2013-05-23  9:08 ` [Qemu-devel] [PATCH v3 2/2] net: introduce command to query rx-filter information Amos Kong
2013-05-23 10:23   ` Michael S. Tsirkin
2013-05-24  4:53     ` Amos Kong
2013-05-23 12:14   ` Eric Blake
2013-05-24  3:03     ` Amos Kong
2013-06-26  7:14     ` Markus Armbruster
2013-05-23 16:03   ` Luiz Capitulino
2013-05-24  3:08     ` Amos Kong
2013-05-24 12:23       ` Luiz Capitulino
2013-05-24 12:55         ` Eric Blake
2013-05-24 13:08           ` Luiz Capitulino
2013-05-24 13:23             ` Eric Blake
2013-06-26  9:35               ` Markus Armbruster
2013-05-24 15:20           ` Markus Armbruster
2013-05-24 16:12             ` Michael S. Tsirkin
2013-05-24 18:05               ` Eric Blake
2013-05-24 20:00                 ` Luiz Capitulino
2013-05-26  7:38                   ` Michael S. Tsirkin
2013-05-27  8:36                     ` Stefan Hajnoczi
2013-06-26  9:54   ` Markus Armbruster
2013-06-26 12:00     ` Markus Armbruster
2013-06-26 14:02       ` Luiz Capitulino
2013-06-26 14:15         ` Markus Armbruster
2013-06-28 14:04           ` Eric Blake
2013-06-28 17:27             ` Markus Armbruster
2013-07-01  3:24               ` Amos Kong
2013-07-02  6:33     ` Amos Kong
2013-07-02  9:05       ` Markus Armbruster
2013-07-02 10:40         ` Amos Kong
2013-07-02 13:27           ` Markus Armbruster
2013-07-04  3:31             ` Amos Kong
2013-07-04  6:28               ` Markus Armbruster
2013-07-11 14:05                 ` Amos Kong
2013-07-12  6:32                   ` Markus Armbruster [this message]
2013-07-12  7:07                     ` Amos Kong

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=87ip0ge1aa.fsf@blackfin.pond.sub.org \
    --to=armbru@redhat.com \
    --cc=akong@redhat.com \
    --cc=lcapitulino@redhat.com \
    --cc=mst@redhat.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 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.