From: Angelo Dureghello <angelo@sysam.it>
To: Wei Yongjun <weiyongjun1@huawei.com>
Cc: Vinod Koul <vkoul@kernel.org>,
Dan Williams <dan.j.williams@intel.com>,
dmaengine@vger.kernel.org, kernel-janitors@vger.kernel.org
Subject: [-next] dmaengine: fsl-edma: fix the error return code in mcf_edma_probe()
Date: Wed, 4 Jul 2018 11:04:46 +0200 [thread overview]
Message-ID: <20180704090445.GD9939@jerusalem> (raw)
Reviewed-by: Angelo Dureghello <angelo@sysam.it>
Thanks for the fix.
On Wed, Jul 04, 2018 at 08:21:51AM +0000, Wei Yongjun wrote:
> The error return code PTR_ERR(pdata) is always 0 since pdata is
> NULL in this error handling case.
>
> Fixes: 5c1355ad87a2 ("dmaengine: fsl-edma: add ColdFire mcf5441x edma support")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---
> drivers/dma/mcf-edma.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/dma/mcf-edma.c b/drivers/dma/mcf-edma.c
> index 31e5317..787b7b6 100644
> --- a/drivers/dma/mcf-edma.c
> +++ b/drivers/dma/mcf-edma.c
> @@ -175,7 +175,7 @@ static int mcf_edma_probe(struct platform_device *pdev)
>
> pdata = dev_get_platdata(&pdev->dev);
> if (!pdata)
> - return PTR_ERR(pdata);
> + return -EINVAL;
>
> chans = pdata->dma_channels;
> len = sizeof(*mcf_edma) + sizeof(*mcf_chan) * chans;
>
> --
> To unsubscribe from this list: send the line "unsubscribe dmaengine" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
---
To unsubscribe from this list: send the line "unsubscribe dmaengine" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
WARNING: multiple messages have this Message-ID (diff)
From: Angelo Dureghello <angelo@sysam.it>
To: Wei Yongjun <weiyongjun1@huawei.com>
Cc: Vinod Koul <vkoul@kernel.org>,
Dan Williams <dan.j.williams@intel.com>,
dmaengine@vger.kernel.org, kernel-janitors@vger.kernel.org
Subject: Re: [PATCH -next] dmaengine: fsl-edma: fix the error return code in mcf_edma_probe()
Date: Wed, 04 Jul 2018 09:04:46 +0000 [thread overview]
Message-ID: <20180704090445.GD9939@jerusalem> (raw)
In-Reply-To: <1530692511-191869-1-git-send-email-weiyongjun1@huawei.com>
Reviewed-by: Angelo Dureghello <angelo@sysam.it>
Thanks for the fix.
On Wed, Jul 04, 2018 at 08:21:51AM +0000, Wei Yongjun wrote:
> The error return code PTR_ERR(pdata) is always 0 since pdata is
> NULL in this error handling case.
>
> Fixes: 5c1355ad87a2 ("dmaengine: fsl-edma: add ColdFire mcf5441x edma support")
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
> ---
> drivers/dma/mcf-edma.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/dma/mcf-edma.c b/drivers/dma/mcf-edma.c
> index 31e5317..787b7b6 100644
> --- a/drivers/dma/mcf-edma.c
> +++ b/drivers/dma/mcf-edma.c
> @@ -175,7 +175,7 @@ static int mcf_edma_probe(struct platform_device *pdev)
>
> pdata = dev_get_platdata(&pdev->dev);
> if (!pdata)
> - return PTR_ERR(pdata);
> + return -EINVAL;
>
> chans = pdata->dma_channels;
> len = sizeof(*mcf_edma) + sizeof(*mcf_chan) * chans;
>
> --
> To unsubscribe from this list: send the line "unsubscribe dmaengine" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next reply other threads:[~2018-07-04 9:04 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-04 9:04 Angelo Dureghello [this message]
2018-07-04 9:04 ` [PATCH -next] dmaengine: fsl-edma: fix the error return code in mcf_edma_probe() Angelo Dureghello
-- strict thread matches above, loose matches on Subject: below --
2018-07-04 8:21 [-next] " weiyongjun (A)
2018-07-04 8:21 ` [PATCH -next] " Wei Yongjun
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=20180704090445.GD9939@jerusalem \
--to=angelo@sysam.it \
--cc=dan.j.williams@intel.com \
--cc=dmaengine@vger.kernel.org \
--cc=kernel-janitors@vger.kernel.org \
--cc=vkoul@kernel.org \
--cc=weiyongjun1@huawei.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.