All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jason Cooper <jason@lakedaemon.net>
To: Arnaud Ebalard <arno@natisbad.org>
Cc: Gregory CLEMENT <gregory.clement@free-electrons.com>,
	Mark Rutland <mark.rutland@arm.com>,
	Boris Brezillon <boris.brezillon@free-electrons.com>,
	Thomas Petazzoni <info@free-electrons.com>,
	Herbert Xu <herbert@gondor.apana.org.au>,
	Pawel Moll <pawel.moll@arm.com>,
	Ian Campbell <ijc+devicetree@hellion.org.uk>,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, Eran Ben-Avi <benavi@marvell.com>,
	Nadav Haklai <nadavh@marvell.com>,
	devicetree@vger.kernel.org, Rob Herring <robh+dt@kernel.org>,
	Andrew Lunn <andrew@lunn.ch>,
	linux-crypto@vger.kernel.org, Kumar Gala <galak@codeaurora.org>,
	Tawfik Bayouk <tawfik@marvell.com>,
	"David S. Miller" <davem@davemloft.net>,
	Lior Amsalem <alior@marvell.com>,
	Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
Subject: Re: [PATCH 0/2] crypto: add new driver for Marvell CESA
Date: Mon, 13 Apr 2015 20:11:46 +0000	[thread overview]
Message-ID: <20150413201146.GL18660@io.lakedaemon.net> (raw)
In-Reply-To: <87r3rom2qu.fsf@natisbad.org>

Hey Arnaud,

On Mon, Apr 13, 2015 at 06:06:49PM +0200, Arnaud Ebalard wrote:
> Jason Cooper <jason@lakedaemon.net> writes:
...
> >> >> I really tried to adapt the existing driver to add the missing
> >> >> features (especially the support for TDMA), but all my attempts
> >> >> ended up introducing hackish code (not even talking about the
> >> >> performance penalty of this approach).
> >> > 
> >> > Ok, fair enough.  It would be helpful if this account of attempting to
> >> > reconcile the old driver made it into the commit message.  This puts us
> >> > in "perfect is the enemy of getting it done" territory.
> >> > 
> >> >> I have another solution though: keep the existing driver for old
> >> >> marvell SoCs (orion, kirkwood and dove), and add a new one for modern
> >> >> SoCs (armada 370, XP, 375 and 38x), so that users of the mv_cesa driver
> >> >> won't have to audit the new code.
> >> > 
> >> > A fair proposal, but I'll freely admit the number of people actually auditing
> >> > their code paths is orders of magnitude smaller than the number of users
> >> > of the driver.
> >> > 
> >> > There's such a large population of compatible legacy SoCs in the wild,
> >> > adding an artificial boundary doesn't make sense.  Especially since
> >> > we're talking about features everyone would want to use.
> >> > 
> >> > Perhaps we should keep both around, and deprecate the legacy driver over
> >> > 3 to 4 cycles?
> >> 
> >> But I guess that some users will want to use the new driver on the "old" marvell
> >> SoCs (especially kirkwood and dove).
> >
> > Yes, despite my arguments, I'm one of those people.  :-P
> >
> >> If we go to this path, then the best solution would be to still update
> >> all the the dts, and modifying the old driver to be able to use the
> >> new binding: for my point of view the only adaptation should be
> >> related to the SRAM. It will be also needed to find a way to be able
> >> to load only one driver at a time: either the old or the new, but not
> >> both.
> 
> The approach Boris proposed above seems to make everyone happy:
> 
>  1) Keep the old driver for old marvells SoCs (kirkwood, dove and orion)
>  2) Introduce the new driver for those that are not supported by the old
>     driver, i.e. armada (370, XP, 375, 38x)
> 
> AFAICT, this can easily be done (based on compatible strings) and it
> will let everyone the time to audit the new driver. Current users will
> not be taken by surprise. At some point, when everyone is confident w/
> the new driver, we can then switch to that one for all SoCs so that
> old platform get more performance.
> 
> Additionnally, for those who want to get the feature of the new driver
> for their old SoC right now, we *could* add a simple kernel config option
> for the new driver to use it for the old SoC too (that one disabling the
> old one).
> 
> 
> > I'd appreciate if we'd look into it.  I understand from on-list and
> > off-list discussion that the rewrite was unavoidable.  So I'm willing to
> > concede that.  Giving people time to migrate from old to new while still
> > being able to update for other security fixes seems reasonable.
> 
> Jason, what do you think of the approach above? 

I say keep it simple.  We shouldn't use the DT changes to trigger one
vice the other.  We need to be able to build both, but only load one at
a time.  If that's anything other than simple to do, then we make it a
Kconfig binary choice and move on.

thx,

Jason.

WARNING: multiple messages have this Message-ID (diff)
From: jason@lakedaemon.net (Jason Cooper)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 0/2] crypto: add new driver for Marvell CESA
Date: Mon, 13 Apr 2015 20:11:46 +0000	[thread overview]
Message-ID: <20150413201146.GL18660@io.lakedaemon.net> (raw)
In-Reply-To: <87r3rom2qu.fsf@natisbad.org>

Hey Arnaud,

On Mon, Apr 13, 2015 at 06:06:49PM +0200, Arnaud Ebalard wrote:
> Jason Cooper <jason@lakedaemon.net> writes:
...
> >> >> I really tried to adapt the existing driver to add the missing
> >> >> features (especially the support for TDMA), but all my attempts
> >> >> ended up introducing hackish code (not even talking about the
> >> >> performance penalty of this approach).
> >> > 
> >> > Ok, fair enough.  It would be helpful if this account of attempting to
> >> > reconcile the old driver made it into the commit message.  This puts us
> >> > in "perfect is the enemy of getting it done" territory.
> >> > 
> >> >> I have another solution though: keep the existing driver for old
> >> >> marvell SoCs (orion, kirkwood and dove), and add a new one for modern
> >> >> SoCs (armada 370, XP, 375 and 38x), so that users of the mv_cesa driver
> >> >> won't have to audit the new code.
> >> > 
> >> > A fair proposal, but I'll freely admit the number of people actually auditing
> >> > their code paths is orders of magnitude smaller than the number of users
> >> > of the driver.
> >> > 
> >> > There's such a large population of compatible legacy SoCs in the wild,
> >> > adding an artificial boundary doesn't make sense.  Especially since
> >> > we're talking about features everyone would want to use.
> >> > 
> >> > Perhaps we should keep both around, and deprecate the legacy driver over
> >> > 3 to 4 cycles?
> >> 
> >> But I guess that some users will want to use the new driver on the "old" marvell
> >> SoCs (especially kirkwood and dove).
> >
> > Yes, despite my arguments, I'm one of those people.  :-P
> >
> >> If we go to this path, then the best solution would be to still update
> >> all the the dts, and modifying the old driver to be able to use the
> >> new binding: for my point of view the only adaptation should be
> >> related to the SRAM. It will be also needed to find a way to be able
> >> to load only one driver at a time: either the old or the new, but not
> >> both.
> 
> The approach Boris proposed above seems to make everyone happy:
> 
>  1) Keep the old driver for old marvells SoCs (kirkwood, dove and orion)
>  2) Introduce the new driver for those that are not supported by the old
>     driver, i.e. armada (370, XP, 375, 38x)
> 
> AFAICT, this can easily be done (based on compatible strings) and it
> will let everyone the time to audit the new driver. Current users will
> not be taken by surprise. At some point, when everyone is confident w/
> the new driver, we can then switch to that one for all SoCs so that
> old platform get more performance.
> 
> Additionnally, for those who want to get the feature of the new driver
> for their old SoC right now, we *could* add a simple kernel config option
> for the new driver to use it for the old SoC too (that one disabling the
> old one).
> 
> 
> > I'd appreciate if we'd look into it.  I understand from on-list and
> > off-list discussion that the rewrite was unavoidable.  So I'm willing to
> > concede that.  Giving people time to migrate from old to new while still
> > being able to update for other security fixes seems reasonable.
> 
> Jason, what do you think of the approach above? 

I say keep it simple.  We shouldn't use the DT changes to trigger one
vice the other.  We need to be able to build both, but only load one at
a time.  If that's anything other than simple to do, then we make it a
Kconfig binary choice and move on.

thx,

Jason.

  reply	other threads:[~2015-04-13 20:12 UTC|newest]

Thread overview: 67+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-09 14:58 [PATCH 0/2] crypto: add new driver for Marvell CESA Boris Brezillon
2015-04-09 14:58 ` Boris Brezillon
2015-04-09 14:58 ` [PATCH 1/2] " Boris Brezillon
     [not found]   ` <1428591523-1780-2-git-send-email-boris.brezillon-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
2015-04-10 10:38     ` Paul Bolle
2015-04-10 10:38       ` Paul Bolle
2015-04-10 10:38       ` Paul Bolle
2015-04-10 11:17       ` Boris Brezillon
2015-04-10 11:17         ` Boris Brezillon
2015-04-09 14:58 ` [PATCH 2/2] crypto: marvell/CESA: update DT bindings documentation Boris Brezillon
2015-04-09 14:58   ` Boris Brezillon
2015-04-09 15:18 ` [PATCH 0/2] crypto: add new driver for Marvell CESA Andrew Lunn
2015-04-09 15:18   ` Andrew Lunn
     [not found]   ` <20150409172826.18916274@bbrezillon>
2015-04-09 15:37     ` Andrew Lunn
2015-04-09 15:37     ` Andrew Lunn
2015-04-09 15:37       ` Andrew Lunn
2015-04-09 15:37       ` Andrew Lunn
2015-04-09 15:34 ` Sebastian Hesselbarth
2015-04-09 15:34   ` Sebastian Hesselbarth
2015-04-09 15:57   ` Boris Brezillon
2015-04-09 15:57     ` Boris Brezillon
2015-04-09 23:21     ` Arnaud Ebalard
2015-04-09 23:21       ` Arnaud Ebalard
2015-04-09 23:21       ` Arnaud Ebalard
2015-04-09 15:52 ` Stephan Mueller
2015-04-09 15:52   ` Stephan Mueller
2015-04-10 13:50 ` Jason Cooper
2015-04-10 13:50   ` Jason Cooper
2015-04-10 15:11   ` Boris Brezillon
2015-04-10 15:11     ` Boris Brezillon
2015-04-10 22:30     ` Jason Cooper
2015-04-10 22:30       ` Jason Cooper
2015-04-13  9:39       ` Gregory CLEMENT
2015-04-13  9:39         ` Gregory CLEMENT
2015-04-13 12:47         ` Jason Cooper
2015-04-13 12:47           ` Jason Cooper
2015-04-13 16:06           ` Arnaud Ebalard
2015-04-13 16:06             ` Arnaud Ebalard
2015-04-13 20:11             ` Jason Cooper [this message]
2015-04-13 20:11               ` Jason Cooper
2015-04-17  8:33               ` Boris Brezillon
2015-04-17  8:33                 ` Boris Brezillon
2015-04-17  8:39                 ` Boris Brezillon
2015-04-17  8:39                   ` Boris Brezillon
2015-04-17 10:59                   ` Jason Cooper
2015-04-17 10:59                     ` Jason Cooper
2015-04-17 13:01                   ` Gregory CLEMENT
2015-04-17 13:01                     ` Gregory CLEMENT
2015-04-17 14:19                     ` Boris Brezillon
2015-04-17 14:19                       ` Boris Brezillon
2015-04-17 14:32                       ` Maxime Ripard
2015-04-17 14:32                         ` Maxime Ripard
2015-04-17 14:40                         ` Gregory CLEMENT
2015-04-17 14:40                           ` Gregory CLEMENT
2015-04-17 14:50                           ` Maxime Ripard
2015-04-17 14:50                             ` Maxime Ripard
2015-04-17 15:01                             ` Gregory CLEMENT
2015-04-17 15:01                               ` Gregory CLEMENT
2015-04-17 15:01                               ` Gregory CLEMENT
2015-04-17 15:49                               ` Maxime Ripard
2015-04-17 15:49                                 ` Maxime Ripard
2015-04-17 16:04                                 ` Gregory CLEMENT
2015-04-17 16:04                                   ` Gregory CLEMENT
2015-04-17 16:04                                   ` Gregory CLEMENT
2015-04-28 19:52 ` Boris Brezillon
2015-04-28 19:52   ` Boris Brezillon
2015-04-29  9:49   ` Herbert Xu
2015-04-29  9:49     ` Herbert Xu

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=20150413201146.GL18660@io.lakedaemon.net \
    --to=jason@lakedaemon.net \
    --cc=alior@marvell.com \
    --cc=andrew@lunn.ch \
    --cc=arno@natisbad.org \
    --cc=benavi@marvell.com \
    --cc=boris.brezillon@free-electrons.com \
    --cc=davem@davemloft.net \
    --cc=devicetree@vger.kernel.org \
    --cc=galak@codeaurora.org \
    --cc=gregory.clement@free-electrons.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=info@free-electrons.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=nadavh@marvell.com \
    --cc=pawel.moll@arm.com \
    --cc=robh+dt@kernel.org \
    --cc=sebastian.hesselbarth@gmail.com \
    --cc=tawfik@marvell.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.