netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Saeed Mahameed <saeedm@mellanox.com>
To: "jarod@redhat.com" <jarod@redhat.com>
Cc: "vfalico@gmail.com" <vfalico@gmail.com>,
	"davem@davemloft.net" <davem@davemloft.net>,
	"herbert@gondor.apana.org.au" <herbert@gondor.apana.org.au>,
	"andy@greyhouse.net" <andy@greyhouse.net>,
	"steffen.klassert@secunet.com" <steffen.klassert@secunet.com>,
	"j.vosburgh@gmail.com" <j.vosburgh@gmail.com>,
	Boris Pismenny <borisp@mellanox.com>,
	"kuba@kernel.org" <kuba@kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"leon@kernel.org" <leon@kernel.org>,
	"jeffrey.t.kirsher@intel.com" <jeffrey.t.kirsher@intel.com>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>
Subject: Re: [PATCH net-next v2 3/4] mlx5: become aware of when running as a bonding slave
Date: Tue, 23 Jun 2020 19:57:02 +0000	[thread overview]
Message-ID: <bb655544aca2305e31876c9f5230a358813d42d3.camel@mellanox.com> (raw)
In-Reply-To: <CAKfmpSeM4zf_rY_oLJJcE=vqjS43qKE8C+vAQb2NohXe3Zxxew@mail.gmail.com>

On Sun, 2020-06-21 at 16:25 -0400, Jarod Wilson wrote:
> On Thu, Jun 11, 2020 at 5:51 PM Saeed Mahameed <saeedm@mellanox.com>
> wrote:
> > On Wed, 2020-06-10 at 14:59 -0400, Jarod Wilson wrote:
> > > I've been unable to get my hands on suitable supported hardware
> > > to
> > > date,
> > > but I believe this ought to be all that is needed to enable the
> > > mlx5
> > > driver to also work with bonding active-backup crypto offload
> > > passthru.
> > > 
> > > CC: Boris Pismenny <borisp@mellanox.com>
> > > CC: Saeed Mahameed <saeedm@mellanox.com>
> > > CC: Leon Romanovsky <leon@kernel.org>
> > > CC: Jay Vosburgh <j.vosburgh@gmail.com>
> > > CC: Veaceslav Falico <vfalico@gmail.com>
> > > CC: Andy Gospodarek <andy@greyhouse.net>
> > > CC: "David S. Miller" <davem@davemloft.net>
> > > CC: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
> > > CC: Jakub Kicinski <kuba@kernel.org>
> > > CC: Steffen Klassert <steffen.klassert@secunet.com>
> > > CC: Herbert Xu <herbert@gondor.apana.org.au>
> > > CC: netdev@vger.kernel.org
> > > Signed-off-by: Jarod Wilson <jarod@redhat.com>
> > > ---
> > >  drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c | 6
> > > ++++++
> > >  1 file changed, 6 insertions(+)
> > > 
> > > diff --git
> > > a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c
> > > b/drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c
> > > index 92eb3bad4acd..72ad6664bd73 100644
> > > --- a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c
> > > +++ b/drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c
> > > @@ -210,6 +210,9 @@ static inline int
> > > mlx5e_xfrm_validate_state(struct xfrm_state *x)
> > >       struct net_device *netdev = x->xso.dev;
> > >       struct mlx5e_priv *priv;
> > > 
> > > +     if (x->xso.slave_dev)
> > > +             netdev = x->xso.slave_dev;
> > > +
> > 
> > Do we really need to repeat this per driver ?
> > why not just setup xso.real_dev, in xfrm layer once and for all
> > before
> > calling device drivers ?
> > 
> > Device drivers will use xso.real_dev blindly.
> > 
> > Will be useful in the future when you add vlan support, etc..
> 
> Apologies, I didn't catch your reply until just recently. Yeah, that
> sounds like a better approach, if I can work it out cleanly. We just
> init xso.real_dev to the same thing as xso.dev, then overwrite it in
> the upper layer drivers (bonding, vlan, etc), while device drivers
> just always use xso.real_dev, if I'm understanding your suggestion.
> I'll see what I can come up with.
> 
> 

Yes, exactly what i meant, Thanks !





  reply	other threads:[~2020-06-23 19:57 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20200608210058.37352-1-jarod@redhat.com>
2020-06-08 21:00 ` [PATCH net-next 1/4] xfrm: bail early on slave pass over skb Jarod Wilson
2020-06-09  2:03   ` David Miller
2020-06-08 21:00 ` [PATCH net-next 2/4] ixgbe_ipsec: become aware of when running as a bonding slave Jarod Wilson
2020-06-08 23:19   ` Kirsher, Jeffrey T
2020-06-08 21:00 ` [PATCH net-next 3/4] bonding: support hardware encryption offload to slaves Jarod Wilson
2020-06-08 23:48   ` Jay Vosburgh
2020-06-09  0:14     ` Jarod Wilson
2020-06-08 21:00 ` [PATCH net-next 4/4] mlx5: become aware of when running as a bonding slave Jarod Wilson
     [not found] ` <20200610185910.48668-1-jarod@redhat.com>
2020-06-10 18:59   ` [PATCH net-next v2 1/4] xfrm: bail early on slave pass over skb Jarod Wilson
2020-06-10 18:59   ` [PATCH net-next v2 2/4] ixgbe_ipsec: become aware of when running as a bonding slave Jarod Wilson
2020-06-10 18:59   ` [PATCH net-next v2 3/4] mlx5: " Jarod Wilson
2020-06-11 21:51     ` Saeed Mahameed
2020-06-21 20:25       ` Jarod Wilson
2020-06-23 19:57         ` Saeed Mahameed [this message]
2020-06-10 18:59   ` [PATCH net-next v2 4/4] bonding: support hardware encryption offload to slaves Jarod Wilson

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=bb655544aca2305e31876c9f5230a358813d42d3.camel@mellanox.com \
    --to=saeedm@mellanox.com \
    --cc=andy@greyhouse.net \
    --cc=borisp@mellanox.com \
    --cc=davem@davemloft.net \
    --cc=herbert@gondor.apana.org.au \
    --cc=j.vosburgh@gmail.com \
    --cc=jarod@redhat.com \
    --cc=jeffrey.t.kirsher@intel.com \
    --cc=kuba@kernel.org \
    --cc=leon@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=steffen.klassert@secunet.com \
    --cc=vfalico@gmail.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).