From: Arnd Bergmann <arnd@arndb.de>
To: Alexander Shiyan <shc_work@mail.ru>
Cc: linux-mmc@vger.kernel.org, Chris Ball <chris@printf.net>,
Shawn Guo <shawn.guo@linaro.org>,
Sascha Hauer <kernel@pengutronix.de>
Subject: Re: [PATCH 1/2] mmc: mxcmmc: Convert to devm-* API
Date: Sat, 22 Feb 2014 16:37:53 +0100 [thread overview]
Message-ID: <2376908.tRC2oWmiYE@wuerfel> (raw)
In-Reply-To: <1393080372-6760-1-git-send-email-shc_work@mail.ru>
On Saturday 22 February 2014 18:46:11 Alexander Shiyan wrote:
> Replace existing resource handling in the driver with managed
> device resource, this ensures more consistent error values and
> simplifies error paths.
>
> Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Nice cleanup!
> drivers/mmc/host/mxcmmc.c | 101 +++++++++++++++++-----------------------------
> 1 file changed, 38 insertions(+), 63 deletions(-)
>
> diff --git a/drivers/mmc/host/mxcmmc.c b/drivers/mmc/host/mxcmmc.c
> index f7199c8..84d630e 100644
> --- a/drivers/mmc/host/mxcmmc.c
> +++ b/drivers/mmc/host/mxcmmc.c
> @@ -124,9 +124,8 @@ enum mxcmci_type {
>
> struct mxcmci_host {
> struct mmc_host *mmc;
> - struct resource *res;
> void __iomem *base;
> - int irq;
> + dma_addr_t phys_base;
> int detect_irq;
> struct dma_chan *dma;
> struct dma_async_tx_descriptor *desc;
Just nitpicking, but I think phys_base should be either phys_addr_t or
resource_size_t. dma_addr_t is what you get out of the dma-mapping API,
not what you use for ioremap. In theory they may be different, but I
don't know how we'd handle that case for the dmaengine API, since we
don't currently have a way to convert between the two, other than for
doing DMA on memory pages.
Arnd
next prev parent reply other threads:[~2014-02-22 15:38 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-22 14:46 [PATCH 1/2] mmc: mxcmmc: Convert to devm-* API Alexander Shiyan
2014-02-22 14:46 ` [PATCH 2/2] mmc: mxcmmc: Convert to SIMPLE_DEV_PM_OPS Alexander Shiyan
2014-02-22 14:51 ` Fabio Estevam
2014-02-22 14:57 ` Alexander Shiyan
2014-02-22 14:59 ` Fabio Estevam
2014-02-22 15:02 ` Alexander Shiyan
2014-02-22 15:05 ` Fabio Estevam
2014-02-22 15:42 ` Arnd Bergmann
2014-02-22 15:37 ` Arnd Bergmann [this message]
2014-02-22 16:02 ` [PATCH 1/2] mmc: mxcmmc: Convert to devm-* API Alexander Shiyan
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=2376908.tRC2oWmiYE@wuerfel \
--to=arnd@arndb.de \
--cc=chris@printf.net \
--cc=kernel@pengutronix.de \
--cc=linux-mmc@vger.kernel.org \
--cc=shawn.guo@linaro.org \
--cc=shc_work@mail.ru \
/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