From: Dan Williams <dan.j.williams@intel.com>
To: "tmarri@apm.com" <tmarri@apm.com>
Cc: "linux-raid@vger.kernel.org" <linux-raid@vger.kernel.org>,
"herbert@gondor.hengli.com.au" <herbert@gondor.hengli.com.au>,
"linuxppc-dev@lists.ozlabs.org" <linuxppc-dev@lists.ozlabs.org>,
"linux-crypto@vger.kernel.org" <linux-crypto@vger.kernel.org>,
"yur@emcraft.com" <yur@emcraft.com>
Subject: Re: [PATCH v1 1/4] PPC4xx: Generalizing ADMA driver modifications
Date: Thu, 23 Sep 2010 15:38:20 -0700 [thread overview]
Message-ID: <4C9BD6DC.3070707@intel.com> (raw)
In-Reply-To: <1285279839-16588-1-git-send-email-tmarri@apm.com>
On 9/23/2010 3:10 PM, tmarri@apm.com wrote:
> From: Tirumala Marri<tmarri@apm.com>
>
> This patch generalizes the existing drver/dma/ppc4xx/adma.c, so that
> common code can be shared between different similar DMA engine
> drivers in other SoCs. Also Makefile and Kconfig changed to accommodate
> PPC4XX.
>
> Signed-off-by: Tirumala R Marri<tmarri@apm.com>
> ---
> V1:
> * No change.
> ---
> arch/powerpc/include/asm/async_tx.h | 4 +-
> drivers/dma/Kconfig | 6 +-
> drivers/dma/Makefile | 2 +-
> drivers/dma/ppc4xx/Makefile | 2 +-
> drivers/dma/ppc4xx/adma.c | 4437 +++--------------------------------
> drivers/dma/ppc4xx/adma.h | 92 +-
> 6 files changed, 354 insertions(+), 4189 deletions(-)
Did you look at this changelog before sending? It just deletes 4000
lines of code??
Moving and renaming code in one patch makes it very difficult to verify
the result. When generalizing code the first thing I want to see with a
very quick glance at the patch(es) is that the existing implementation
is not harmed. One way to go about this is to first identify the
portions of existing code that you want to reuse in your driver and the
pieces that are truly ppc440spe specific. Move the ppc440spe pieces to
their own file (get this reviewed and approved by the ppc440spe
authors). The remaining code in adma.c will be assumed generic. You
can then have another patch to do a simple s/ppc440spe/ppc4xx/ in adma.c
(no other logic changes or code movement). Then you can introduce your
ppc460ex unique implementation that calls into adma.c.
I don't want to see patches along the lines of "rename
drivers/dma/ppc4xx/adma.c to drivers/dma/ppc4xx/ppc4xx-adma.c" because
that is just redundant. Assume that the existing generic file names are
where the common code will lie and then add hw-implementation specific
files to call into that base.
Another rule is that the conversion should be bisectable at every step,
I should be able to apply each patch in the series and still have a
functional/runnable result.
--
Dan
next prev parent reply other threads:[~2010-09-23 22:48 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-09-23 22:10 [PATCH v1 1/4] PPC4xx: Generalizing ADMA driver modifications tmarri
2010-09-23 22:38 ` Dan Williams [this message]
2010-09-23 22:44 ` Tirumala Marri
2010-09-23 22:51 ` Dan Williams
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=4C9BD6DC.3070707@intel.com \
--to=dan.j.williams@intel.com \
--cc=herbert@gondor.hengli.com.au \
--cc=linux-crypto@vger.kernel.org \
--cc=linux-raid@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=tmarri@apm.com \
--cc=yur@emcraft.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).