All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michal Schmidt <mschmidt@redhat.com>
To: "Vlad Zolotarov" <vladz@broadcom.com>
Cc: "Michał Mirosław" <mirqus@gmail.com>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"Dmitry Kravkov" <dmitry@broadcom.com>,
	"Eilon Greenstein" <eilong@broadcom.com>
Subject: Re: [PATCH 7/7] bnx2x: expose HW RX VLAN stripping toggle
Date: Wed, 31 Aug 2011 15:53:24 +0200	[thread overview]
Message-ID: <20110831155324.7554d035@alice> (raw)
In-Reply-To: <201108311501.39936.vladz@broadcom.com>

On Wed, 31 Aug 2011 15:01:39 +0300 Vlad Zolotarov wrote:
> On Tuesday 30 August 2011 22:30:11 Michal Schmidt wrote:
> 
> > > and then also in fp->flags.  Are the
> > > fp->flags strictly mirroring hardware state (as in: there is no
> > > way the states can differ in any point in time where the flags are
> > > tested)?
> > 
> > Yes. This is the purpose of the second mirroring of the flag.
> 
> Michal,
> although the above is true i'd say it's a bit of an overkill:
> RX VLAN stripping is configured in a function level, so keeping it in
> a per queue level is not needed. 
> 
> The problem u were trying to resolve (and u resolved it) was to
> separate the RX_VLAN_ENABLED flag semantics into two: requested
> feature and HW configured feature in order to further check the
> second in the fast path, while setting the first one in the
> set_features(). Then the second lag is updated according to the first
> one during the loading of the function (bnx2x_nic_load()).
> 
> Therefore it would be enough to just add those two flags in the
> function (bp) level keeping the rest of your patch as it is. This
> would also cancel the need for a patch 6.

Alright, I will remove the per-fp flag and move it to bp.

I will also apply the cheat suggested by Michał, so that:
 - dev->features & NETIF_F_HW_VLAN_RX is the requested state
 - bp->flags & RX_VLAN_STRIP_FLAG is the HW configured state
=> Only one new bp flag needed, not two.

BTW, Michał's cheat should apply to TPA_ENABLE_FLAG as well - it only
mirrors NETIF_F_LRO. But for TPA the HW configured state is really
per-queue (fp->disable_tpa). I will remove TPA_ENABLE_FLAG unless you
object to Michał's "cheat".

Thanks,
Michal

  reply	other threads:[~2011-08-31 13:53 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-30 14:30 [PATCH 0/7 net-next] bnx2x: cleanups and VLAN stripping toggle Michal Schmidt
2011-08-30 14:30 ` [PATCH 1/7] bnx2x: remove unused fields in struct bnx2x_func_init_params Michal Schmidt
2011-08-31 10:07   ` Vlad Zolotarov
2011-08-30 14:30 ` [PATCH 2/7] bnx2x: remove the 'leading' arguments Michal Schmidt
2011-08-31  9:57   ` Vlad Zolotarov
2011-08-30 14:30 ` [PATCH 3/7] bnx2x: decrease indentation in bnx2x_rx_int() Michal Schmidt
2011-08-31 10:33   ` Vlad Zolotarov
2011-08-30 14:30 ` [PATCH 4/7] bnx2x: simplify TPA sanity check Michal Schmidt
2011-08-31 10:22   ` Vlad Zolotarov
2011-08-30 14:30 ` [PATCH 5/7] bnx2x: do not set TPA flags and features in bnx2x_init_bp Michal Schmidt
2011-08-30 16:21   ` Vlad Zolotarov
2011-08-30 17:15     ` Michal Schmidt
2011-08-30 14:30 ` [PATCH 6/7] bnx2x: move fp->disable_tpa to ->flags Michal Schmidt
2011-08-30 14:30 ` [PATCH 7/7] bnx2x: expose HW RX VLAN stripping toggle Michal Schmidt
2011-08-30 18:27   ` Michał Mirosław
2011-08-30 19:30     ` Michal Schmidt
2011-08-30 20:08       ` Michał Mirosław
2011-08-31 12:01       ` Vlad Zolotarov
2011-08-31 13:53         ` Michal Schmidt [this message]
2011-08-31 15:07           ` Vlad Zolotarov
2011-08-31 15:37             ` Michal Schmidt
2011-08-31 15:51               ` Michal Schmidt
2011-08-31 16:16                 ` Vlad Zolotarov
2011-08-31 18:11                 ` Michał Mirosław

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=20110831155324.7554d035@alice \
    --to=mschmidt@redhat.com \
    --cc=dmitry@broadcom.com \
    --cc=eilong@broadcom.com \
    --cc=mirqus@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=vladz@broadcom.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.