dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/1] video: convert to use new I2C API
@ 2020-03-26 21:09 Wolfram Sang
  2020-03-26 21:09 ` [PATCH 1/1] video: backlight: tosa_lcd: convert to use i2c_new_client_device() Wolfram Sang
  0 siblings, 1 reply; 6+ messages in thread
From: Wolfram Sang @ 2020-03-26 21:09 UTC (permalink / raw)
  To: linux-i2c; +Cc: Wolfram Sang, linux-fbdev, linux-kernel, dri-devel

We are deprecating calls which return NULL in favor of new variants which
return an ERR_PTR. Only build tested.


Wolfram Sang (1):
  video: backlight: tosa_lcd: convert to use i2c_new_client_device()

 drivers/video/backlight/tosa_lcd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

-- 
2.20.1

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* [PATCH 1/1] video: backlight: tosa_lcd: convert to use i2c_new_client_device()
  2020-03-26 21:09 [PATCH 0/1] video: convert to use new I2C API Wolfram Sang
@ 2020-03-26 21:09 ` Wolfram Sang
  2020-04-15 10:38   ` Daniel Thompson
  2020-04-17 10:14   ` Lee Jones
  0 siblings, 2 replies; 6+ messages in thread
From: Wolfram Sang @ 2020-03-26 21:09 UTC (permalink / raw)
  To: linux-i2c
  Cc: Daniel Thompson, Bartlomiej Zolnierkiewicz, Jingoo Han,
	linux-fbdev, dri-devel, linux-kernel, Wolfram Sang, Lee Jones

Move away from the deprecated API and return the shiny new ERRPTR where
useful.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
 drivers/video/backlight/tosa_lcd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/video/backlight/tosa_lcd.c b/drivers/video/backlight/tosa_lcd.c
index e8ab583e5098..113116d3585c 100644
--- a/drivers/video/backlight/tosa_lcd.c
+++ b/drivers/video/backlight/tosa_lcd.c
@@ -107,7 +107,7 @@ static void tosa_lcd_tg_on(struct tosa_lcd_data *data)
 	/* TG LCD GVSS */
 	tosa_tg_send(spi, TG_PINICTL, 0x0);
 
-	if (!data->i2c) {
+	if (IS_ERR_OR_NULL(data->i2c)) {
 		/*
 		 * after the pannel is powered up the first time,
 		 * we can access the i2c bus so probe for the DAC
@@ -119,7 +119,7 @@ static void tosa_lcd_tg_on(struct tosa_lcd_data *data)
 			.addr	= DAC_BASE,
 			.platform_data = data->spi,
 		};
-		data->i2c = i2c_new_device(adap, &info);
+		data->i2c = i2c_new_client_device(adap, &info);
 	}
 }
 
-- 
2.20.1

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* Re: [PATCH 1/1] video: backlight: tosa_lcd: convert to use i2c_new_client_device()
  2020-03-26 21:09 ` [PATCH 1/1] video: backlight: tosa_lcd: convert to use i2c_new_client_device() Wolfram Sang
@ 2020-04-15 10:38   ` Daniel Thompson
  2020-04-17 10:14   ` Lee Jones
  1 sibling, 0 replies; 6+ messages in thread
From: Daniel Thompson @ 2020-04-15 10:38 UTC (permalink / raw)
  To: Wolfram Sang
  Cc: linux-fbdev, Bartlomiej Zolnierkiewicz, Jingoo Han, linux-kernel,
	dri-devel, linux-i2c, Lee Jones

On Thu, Mar 26, 2020 at 10:09:59PM +0100, Wolfram Sang wrote:
> Move away from the deprecated API and return the shiny new ERRPTR where
> useful.
> 
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>

Reviewed-by: Daniel Thompson <daniel.thompson@linaro.org>


> ---
>  drivers/video/backlight/tosa_lcd.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/video/backlight/tosa_lcd.c b/drivers/video/backlight/tosa_lcd.c
> index e8ab583e5098..113116d3585c 100644
> --- a/drivers/video/backlight/tosa_lcd.c
> +++ b/drivers/video/backlight/tosa_lcd.c
> @@ -107,7 +107,7 @@ static void tosa_lcd_tg_on(struct tosa_lcd_data *data)
>  	/* TG LCD GVSS */
>  	tosa_tg_send(spi, TG_PINICTL, 0x0);
>  
> -	if (!data->i2c) {
> +	if (IS_ERR_OR_NULL(data->i2c)) {
>  		/*
>  		 * after the pannel is powered up the first time,
>  		 * we can access the i2c bus so probe for the DAC
> @@ -119,7 +119,7 @@ static void tosa_lcd_tg_on(struct tosa_lcd_data *data)
>  			.addr	= DAC_BASE,
>  			.platform_data = data->spi,
>  		};
> -		data->i2c = i2c_new_device(adap, &info);
> +		data->i2c = i2c_new_client_device(adap, &info);
>  	}
>  }
>  
> -- 
> 2.20.1
> 
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* Re: [PATCH 1/1] video: backlight: tosa_lcd: convert to use i2c_new_client_device()
  2020-03-26 21:09 ` [PATCH 1/1] video: backlight: tosa_lcd: convert to use i2c_new_client_device() Wolfram Sang
  2020-04-15 10:38   ` Daniel Thompson
@ 2020-04-17 10:14   ` Lee Jones
  2020-05-12 16:25     ` Wolfram Sang
  1 sibling, 1 reply; 6+ messages in thread
From: Lee Jones @ 2020-04-17 10:14 UTC (permalink / raw)
  To: Wolfram Sang
  Cc: Daniel Thompson, Bartlomiej Zolnierkiewicz, Jingoo Han,
	linux-fbdev, dri-devel, linux-kernel, linux-i2c

On Thu, 26 Mar 2020, Wolfram Sang wrote:

> Move away from the deprecated API and return the shiny new ERRPTR where
> useful.
> 
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
> ---
>  drivers/video/backlight/tosa_lcd.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

Applied, thanks.

-- 
Lee Jones [李琼斯]
Linaro Services Technical Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* Re: [PATCH 1/1] video: backlight: tosa_lcd: convert to use i2c_new_client_device()
  2020-04-17 10:14   ` Lee Jones
@ 2020-05-12 16:25     ` Wolfram Sang
  2020-05-13  8:00       ` Lee Jones
  0 siblings, 1 reply; 6+ messages in thread
From: Wolfram Sang @ 2020-05-12 16:25 UTC (permalink / raw)
  To: Lee Jones
  Cc: Daniel Thompson, Bartlomiej Zolnierkiewicz, Jingoo Han,
	linux-fbdev, dri-devel, linux-kernel, linux-i2c


[-- Attachment #1.1: Type: text/plain, Size: 455 bytes --]

On Fri, Apr 17, 2020 at 11:14:46AM +0100, Lee Jones wrote:
> On Thu, 26 Mar 2020, Wolfram Sang wrote:
> 
> > Move away from the deprecated API and return the shiny new ERRPTR where
> > useful.
> > 
> > Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
> > ---
> >  drivers/video/backlight/tosa_lcd.c | 4 ++--
> >  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> Applied, thanks.

Thanks! I don't see it in -next, though?


[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

[-- Attachment #2: Type: text/plain, Size: 160 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* Re: [PATCH 1/1] video: backlight: tosa_lcd: convert to use i2c_new_client_device()
  2020-05-12 16:25     ` Wolfram Sang
@ 2020-05-13  8:00       ` Lee Jones
  0 siblings, 0 replies; 6+ messages in thread
From: Lee Jones @ 2020-05-13  8:00 UTC (permalink / raw)
  To: Wolfram Sang
  Cc: Daniel Thompson, Bartlomiej Zolnierkiewicz, Jingoo Han,
	linux-fbdev, dri-devel, linux-kernel, linux-i2c

On Tue, 12 May 2020, Wolfram Sang wrote:

> On Fri, Apr 17, 2020 at 11:14:46AM +0100, Lee Jones wrote:
> > On Thu, 26 Mar 2020, Wolfram Sang wrote:
> > 
> > > Move away from the deprecated API and return the shiny new ERRPTR where
> > > useful.
> > > 
> > > Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
> > > ---
> > >  drivers/video/backlight/tosa_lcd.c | 4 ++--
> > >  1 file changed, 2 insertions(+), 2 deletions(-)
> > 
> > Applied, thanks.
> 
> Thanks! I don't see it in -next, though?

Just pushed.  Should be there soon.

-- 
Lee Jones [李琼斯]
Linaro Services Technical Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

end of thread, other threads:[~2020-05-13  9:10 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-26 21:09 [PATCH 0/1] video: convert to use new I2C API Wolfram Sang
2020-03-26 21:09 ` [PATCH 1/1] video: backlight: tosa_lcd: convert to use i2c_new_client_device() Wolfram Sang
2020-04-15 10:38   ` Daniel Thompson
2020-04-17 10:14   ` Lee Jones
2020-05-12 16:25     ` Wolfram Sang
2020-05-13  8:00       ` Lee Jones

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).