Re: [PATCH -next] staging: ccree: remove redundant dev_err call in init_cc_resources()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Jan 11, 2018 at 1:14 PM, Wei Yongjun <weiyongjun1@xxxxxxxxxx> wrote:
> There is a error message within devm_ioremap_resource
> already, so remove the dev_err call to avoid redundant
> error message.
>
> Signed-off-by: Wei Yongjun <weiyongjun1@xxxxxxxxxx>
> ---
>  drivers/staging/ccree/cc_driver.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/staging/ccree/cc_driver.c b/drivers/staging/ccree/cc_driver.c
> index 6682d9d..c27d5a8 100644
> --- a/drivers/staging/ccree/cc_driver.c
> +++ b/drivers/staging/ccree/cc_driver.c
> @@ -174,10 +174,8 @@ static int init_cc_resources(struct platform_device *plat_dev)
>         req_mem_cc_regs = platform_get_resource(plat_dev, IORESOURCE_MEM, 0);
>         /* Map registers space */
>         new_drvdata->cc_base = devm_ioremap_resource(dev, req_mem_cc_regs);
> -       if (IS_ERR(new_drvdata->cc_base)) {
> -               dev_err(dev, "Failed to ioremap registers");
> +       if (IS_ERR(new_drvdata->cc_base))
>                 return PTR_ERR(new_drvdata->cc_base);
> -       }
>
>         dev_dbg(dev, "Got MEM resource (%s): %pR\n", req_mem_cc_regs->name,
>                 req_mem_cc_regs);
>

Yeah, that makes sense.

Acked-by: Gilad Ben-Yossef <gilad@xxxxxxxxxxxxx>

Thanks,
Gilad

-- 
Gilad Ben-Yossef
Chief Coffee Drinker

"If you take a class in large-scale robotics, can you end up in a
situation where the homework eats your dog?"
 -- Jean-Baptiste Queru
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel



[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux