Linux-Amlogic Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH] staging: axis-fifo: media/meson: remove redundant dev_err call
@ 2021-04-07 10:10 Muhammad Usama Anjum
  2021-04-07 14:05 ` Hans Verkuil
  0 siblings, 1 reply; 3+ messages in thread
From: Muhammad Usama Anjum @ 2021-04-07 10:10 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Neil Armstrong, Mauro Carvalho Chehab,
	Kevin Hilman, Jerome Brunet, Martin Blumenstingl,
	open list:STAGING SUBSYSTEM, open list,
	open list:MESON VIDEO DECODER DRIVER FOR AMLOGIC SOCS,
	open list:MESON VIDEO DECODER DRIVER FOR AMLOGIC SOCS,
	moderated list:ARM/Amlogic Meson SoC support
  Cc: musamaanjum, linqiheng, kernel-janitors, dan.carpenter

devm_ioremap_resource() prints error message in itself. Remove the
dev_err call to avoid redundant error message.

Signed-off-by: Muhammad Usama Anjum <musamaanjum@gmail.com>
---
 drivers/staging/axis-fifo/axis-fifo.c   | 1 -
 drivers/staging/media/meson/vdec/vdec.c | 8 ++------
 2 files changed, 2 insertions(+), 7 deletions(-)

diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
index 2bb1c2e9cb57..ed9281089738 100644
--- a/drivers/staging/axis-fifo/axis-fifo.c
+++ b/drivers/staging/axis-fifo/axis-fifo.c
@@ -853,7 +853,6 @@ static int axis_fifo_probe(struct platform_device *pdev)
 	fifo->base_addr = devm_ioremap_resource(fifo->dt_device, r_mem);
 	if (IS_ERR(fifo->base_addr)) {
 		rc = PTR_ERR(fifo->base_addr);
-		dev_err(fifo->dt_device, "can't remap IO resource (%d)\n", rc);
 		goto err_initial;
 	}
 
diff --git a/drivers/staging/media/meson/vdec/vdec.c b/drivers/staging/media/meson/vdec/vdec.c
index 5d4db7a5b4b5..e51d69c4729d 100644
--- a/drivers/staging/media/meson/vdec/vdec.c
+++ b/drivers/staging/media/meson/vdec/vdec.c
@@ -1008,17 +1008,13 @@ static int vdec_probe(struct platform_device *pdev)
 
 	r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "dos");
 	core->dos_base = devm_ioremap_resource(dev, r);
-	if (IS_ERR(core->dos_base)) {
-		dev_err(dev, "Couldn't remap DOS memory\n");
+	if (IS_ERR(core->dos_base))
 		return PTR_ERR(core->dos_base);
-	}
 
 	r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "esparser");
 	core->esparser_base = devm_ioremap_resource(dev, r);
-	if (IS_ERR(core->esparser_base)) {
-		dev_err(dev, "Couldn't remap ESPARSER memory\n");
+	if (IS_ERR(core->esparser_base))
 		return PTR_ERR(core->esparser_base);
-	}
 
 	core->regmap_ao =
 		syscon_regmap_lookup_by_phandle(dev->of_node,
-- 
2.25.1


_______________________________________________
linux-amlogic mailing list
linux-amlogic@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-amlogic

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] staging: axis-fifo: media/meson: remove redundant dev_err call
  2021-04-07 10:10 [PATCH] staging: axis-fifo: media/meson: remove redundant dev_err call Muhammad Usama Anjum
@ 2021-04-07 14:05 ` Hans Verkuil
  2021-04-07 15:48   ` Muhammad Usama Anjum
  0 siblings, 1 reply; 3+ messages in thread
From: Hans Verkuil @ 2021-04-07 14:05 UTC (permalink / raw)
  To: Muhammad Usama Anjum, Greg Kroah-Hartman, Neil Armstrong,
	Mauro Carvalho Chehab, Kevin Hilman, Jerome Brunet,
	Martin Blumenstingl, open list:STAGING SUBSYSTEM, open list,
	open list:MESON VIDEO DECODER DRIVER FOR AMLOGIC SOCS,
	open list:MESON VIDEO DECODER DRIVER FOR AMLOGIC SOCS,
	moderated list:ARM/Amlogic Meson SoC support
  Cc: linqiheng, kernel-janitors, dan.carpenter

Hi Muhammad,

On 07/04/2021 12:10, Muhammad Usama Anjum wrote:
> devm_ioremap_resource() prints error message in itself. Remove the
> dev_err call to avoid redundant error message.

Please split this up into two separate patches! They are independent
changes and these two drivers are maintained by different people as well.

The patch itself looks OK, but it really has to be two separate patches.

Regards,

	Hans

> 
> Signed-off-by: Muhammad Usama Anjum <musamaanjum@gmail.com>
> ---
>  drivers/staging/axis-fifo/axis-fifo.c   | 1 -
>  drivers/staging/media/meson/vdec/vdec.c | 8 ++------
>  2 files changed, 2 insertions(+), 7 deletions(-)
> 
> diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
> index 2bb1c2e9cb57..ed9281089738 100644
> --- a/drivers/staging/axis-fifo/axis-fifo.c
> +++ b/drivers/staging/axis-fifo/axis-fifo.c
> @@ -853,7 +853,6 @@ static int axis_fifo_probe(struct platform_device *pdev)
>  	fifo->base_addr = devm_ioremap_resource(fifo->dt_device, r_mem);
>  	if (IS_ERR(fifo->base_addr)) {
>  		rc = PTR_ERR(fifo->base_addr);
> -		dev_err(fifo->dt_device, "can't remap IO resource (%d)\n", rc);
>  		goto err_initial;
>  	}
>  
> diff --git a/drivers/staging/media/meson/vdec/vdec.c b/drivers/staging/media/meson/vdec/vdec.c
> index 5d4db7a5b4b5..e51d69c4729d 100644
> --- a/drivers/staging/media/meson/vdec/vdec.c
> +++ b/drivers/staging/media/meson/vdec/vdec.c
> @@ -1008,17 +1008,13 @@ static int vdec_probe(struct platform_device *pdev)
>  
>  	r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "dos");
>  	core->dos_base = devm_ioremap_resource(dev, r);
> -	if (IS_ERR(core->dos_base)) {
> -		dev_err(dev, "Couldn't remap DOS memory\n");
> +	if (IS_ERR(core->dos_base))
>  		return PTR_ERR(core->dos_base);
> -	}
>  
>  	r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "esparser");
>  	core->esparser_base = devm_ioremap_resource(dev, r);
> -	if (IS_ERR(core->esparser_base)) {
> -		dev_err(dev, "Couldn't remap ESPARSER memory\n");
> +	if (IS_ERR(core->esparser_base))
>  		return PTR_ERR(core->esparser_base);
> -	}
>  
>  	core->regmap_ao =
>  		syscon_regmap_lookup_by_phandle(dev->of_node,
> 


_______________________________________________
linux-amlogic mailing list
linux-amlogic@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-amlogic

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] staging: axis-fifo: media/meson: remove redundant dev_err call
  2021-04-07 14:05 ` Hans Verkuil
@ 2021-04-07 15:48   ` Muhammad Usama Anjum
  0 siblings, 0 replies; 3+ messages in thread
From: Muhammad Usama Anjum @ 2021-04-07 15:48 UTC (permalink / raw)
  To: Hans Verkuil
  Cc: musamaanjum, linqiheng, kernel-janitors, dan.carpenter,
	Greg Kroah-Hartman, Neil Armstrong, Mauro Carvalho Chehab,
	Kevin Hilman, Jerome Brunet, Martin Blumenstingl,
	open list:STAGING SUBSYSTEM, open list,
	open list:MESON VIDEO DECODER DRIVER FOR AMLOGIC SOCS,
	open list:MESON VIDEO DECODER DRIVER FOR AMLOGIC SOCS,
	moderated list:ARM/Amlogic Meson SoC support

On Wed, 2021-04-07 at 16:05 +0200, Hans Verkuil wrote:
> Hi Muhammad,
> 
> On 07/04/2021 12:10, Muhammad Usama Anjum wrote:
> > devm_ioremap_resource() prints error message in itself. Remove the
> > dev_err call to avoid redundant error message.
> 
> Please split this up into two separate patches! They are independent
> changes and these two drivers are maintained by different people as well.
> 
> The patch itself looks OK, but it really has to be two separate patches.
> 
Okay. I'll send two separate patches. Thank you.

Regards,
Usama
> Regards,
> 
> 	Hans
> 
> > Signed-off-by: Muhammad Usama Anjum <musamaanjum@gmail.com>
> > ---
> >  drivers/staging/axis-fifo/axis-fifo.c   | 1 -
> >  drivers/staging/media/meson/vdec/vdec.c | 8 ++------
> >  2 files changed, 2 insertions(+), 7 deletions(-)
> > 
> > diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
> > index 2bb1c2e9cb57..ed9281089738 100644
> > --- a/drivers/staging/axis-fifo/axis-fifo.c
> > +++ b/drivers/staging/axis-fifo/axis-fifo.c
> > @@ -853,7 +853,6 @@ static int axis_fifo_probe(struct platform_device *pdev)
> >  	fifo->base_addr = devm_ioremap_resource(fifo->dt_device, r_mem);
> >  	if (IS_ERR(fifo->base_addr)) {
> >  		rc = PTR_ERR(fifo->base_addr);
> > -		dev_err(fifo->dt_device, "can't remap IO resource (%d)\n", rc);
> >  		goto err_initial;
> >  	}
> >  
> > diff --git a/drivers/staging/media/meson/vdec/vdec.c b/drivers/staging/media/meson/vdec/vdec.c
> > index 5d4db7a5b4b5..e51d69c4729d 100644
> > --- a/drivers/staging/media/meson/vdec/vdec.c
> > +++ b/drivers/staging/media/meson/vdec/vdec.c
> > @@ -1008,17 +1008,13 @@ static int vdec_probe(struct platform_device *pdev)
> >  
> >  	r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "dos");
> >  	core->dos_base = devm_ioremap_resource(dev, r);
> > -	if (IS_ERR(core->dos_base)) {
> > -		dev_err(dev, "Couldn't remap DOS memory\n");
> > +	if (IS_ERR(core->dos_base))
> >  		return PTR_ERR(core->dos_base);
> > -	}
> >  
> >  	r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "esparser");
> >  	core->esparser_base = devm_ioremap_resource(dev, r);
> > -	if (IS_ERR(core->esparser_base)) {
> > -		dev_err(dev, "Couldn't remap ESPARSER memory\n");
> > +	if (IS_ERR(core->esparser_base))
> >  		return PTR_ERR(core->esparser_base);
> > -	}
> >  
> >  	core->regmap_ao =
> >  		syscon_regmap_lookup_by_phandle(dev->of_node,
> > 


_______________________________________________
linux-amlogic mailing list
linux-amlogic@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-amlogic

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, back to index

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-07 10:10 [PATCH] staging: axis-fifo: media/meson: remove redundant dev_err call Muhammad Usama Anjum
2021-04-07 14:05 ` Hans Verkuil
2021-04-07 15:48   ` Muhammad Usama Anjum

Linux-Amlogic Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-amlogic/0 linux-amlogic/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-amlogic linux-amlogic/ https://lore.kernel.org/linux-amlogic \
		linux-amlogic@lists.infradead.org
	public-inbox-index linux-amlogic

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.infradead.lists.linux-amlogic


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git