From: Boris Brezillon <boris.brezillon@free-electrons.com>
To: Romain Perier <romain.perier@free-electrons.com>
Cc: Arnaud Ebalard <arno@natisbad.org>,
Jason Cooper <jason@lakedaemon.net>, Andrew Lunn <andrew@lunn.ch>,
Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>,
Gregory Clement <gregory.clement@free-electrons.com>,
Thomas Petazzoni <thomas.petazzoni@free-electrons.com>,
Nadav Haklai <nadavh@marvell.com>,
Ofer Heifetz <oferh@marvell.com>,
linux-crypto@vger.kernel.org
Subject: Re: [PATCH] crypto: marvell/cesa: Improving code readability
Date: Tue, 19 Apr 2016 17:19:00 +0200 [thread overview]
Message-ID: <20160419171900.21563a54@bbrezillon> (raw)
In-Reply-To: <1461078560-30924-1-git-send-email-romain.perier@free-electrons.com>
On Tue, 19 Apr 2016 17:09:20 +0200
Romain Perier <romain.perier@free-electrons.com> wrote:
> When looking for available engines, the variable "engine" is
> assigned to "&cesa->engines[i]" at the beginning of the for loop. Replacing
> next occurences of "&cesa->engines[i]" by "engine" and in order to improve
> readability.
>
> Signed-off-by: Romain Perier <romain.perier@free-electrons.com>
Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>
> ---
> drivers/crypto/marvell/cesa.c | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/crypto/marvell/cesa.c b/drivers/crypto/marvell/cesa.c
> index 80239ae..e8ef9fd 100644
> --- a/drivers/crypto/marvell/cesa.c
> +++ b/drivers/crypto/marvell/cesa.c
> @@ -475,18 +475,18 @@ static int mv_cesa_probe(struct platform_device *pdev)
> engine->regs = cesa->regs + CESA_ENGINE_OFF(i);
>
> if (dram && cesa->caps->has_tdma)
> - mv_cesa_conf_mbus_windows(&cesa->engines[i], dram);
> + mv_cesa_conf_mbus_windows(engine, dram);
>
> - writel(0, cesa->engines[i].regs + CESA_SA_INT_STATUS);
> + writel(0, engine->regs + CESA_SA_INT_STATUS);
> writel(CESA_SA_CFG_STOP_DIG_ERR,
> - cesa->engines[i].regs + CESA_SA_CFG);
> + engine->regs + CESA_SA_CFG);
> writel(engine->sram_dma & CESA_SA_SRAM_MSK,
> - cesa->engines[i].regs + CESA_SA_DESC_P0);
> + engine->regs + CESA_SA_DESC_P0);
>
> ret = devm_request_threaded_irq(dev, irq, NULL, mv_cesa_int,
> IRQF_ONESHOT,
> dev_name(&pdev->dev),
> - &cesa->engines[i]);
> + engine);
> if (ret)
> goto err_cleanup;
> }
--
Boris Brezillon, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
next prev parent reply other threads:[~2016-04-19 15:19 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-19 15:09 [PATCH] crypto: marvell/cesa: Improving code readability Romain Perier
2016-04-19 15:19 ` Boris Brezillon [this message]
2016-04-20 10:01 ` 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=20160419171900.21563a54@bbrezillon \
--to=boris.brezillon@free-electrons.com \
--cc=andrew@lunn.ch \
--cc=arno@natisbad.org \
--cc=gregory.clement@free-electrons.com \
--cc=jason@lakedaemon.net \
--cc=linux-crypto@vger.kernel.org \
--cc=nadavh@marvell.com \
--cc=oferh@marvell.com \
--cc=romain.perier@free-electrons.com \
--cc=sebastian.hesselbarth@gmail.com \
--cc=thomas.petazzoni@free-electrons.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