[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2985582.KWahZ5isJS@avalon>
Date: Fri, 16 Jan 2015 01:30:21 +0200
From: Laurent Pinchart <laurent.pinchart@...asonboard.com>
To: Wolfram Sang <wsa@...-dreams.de>
Cc: dmaengine@...r.kernel.org, linux-sh@...r.kernel.org,
Magnus Damm <magnus.damm@...il.com>,
Simon Horman <horms@...ge.net.au>,
Geert Uytterhoeven <geert@...ux-m68k.org>,
Philipp Zabel <p.zabel@...gutronix.de>,
Vinod Koul <vinod.koul@...el.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] dmaengine: of: bail out early if "dmas" property is not present
Hi Wolfram,
Thank you for the patch.
On Wednesday 14 January 2015 15:16:28 Wolfram Sang wrote:
> From: Wolfram Sang <wsa+renesas@...g-engineering.com>
>
> And don't print an error: not configured is not an error.
>
> Reported-by: Philipp Zabel <p.zabel@...gutronix.de>
> Signed-off-by: Wolfram Sang <wsa+renesas@...g-engineering.com>
This looks good to me.
Acked-by: Laurent Pinchart <laurent.pinchart@...asonboard.com>
> ---
>
> In response to Philipp's patch silencing the warning in the driver:
> http://patchwork.ozlabs.org/patch/425696/
>
> I think this should be handled in the core.
>
> drivers/dma/of-dma.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/dma/of-dma.c b/drivers/dma/of-dma.c
> index d5fbeaa1e7ba..ca31f1b45366 100644
> --- a/drivers/dma/of-dma.c
> +++ b/drivers/dma/of-dma.c
> @@ -159,6 +159,10 @@ struct dma_chan *of_dma_request_slave_channel(struct
> device_node *np, return ERR_PTR(-ENODEV);
> }
>
> + /* Silently fail if there is not even the "dmas" property */
> + if (!of_find_property(np, "dmas", NULL))
> + return ERR_PTR(-ENODEV);
> +
> count = of_property_count_strings(np, "dma-names");
> if (count < 0) {
> pr_err("%s: dma-names property of node '%s' missing or empty\n",
--
Regards,
Laurent Pinchart
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists