Re: [PATCH 02/10] media: renesas-ceu: Use of_device_get_match_data()

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

 



Em Fri,  4 Oct 2019 14:43:26 -0700
Stephen Boyd <swboyd@xxxxxxxxxxxx> escreveu:

> This driver can use the replacement API instead of calling
> of_match_device() and then dereferencing the pointer that is returned.
> This nicely avoids referencing the match table when it is undefined with
> configurations where CONFIG_OF=n.
> 
> Cc: Arnd Bergmann <arnd@xxxxxxxx>
> Cc: Geert Uytterhoeven <geert@xxxxxxxxxxxxxx>
> Cc: Jacopo Mondi <jacopo@xxxxxxxxxx>
> Cc: Mauro Carvalho Chehab <mchehab@xxxxxxxxxx>
> Cc: Rob Herring <robh+dt@xxxxxxxxxx>
> Cc: Frank Rowand <frowand.list@xxxxxxxxx>
> Cc: <linux-media@xxxxxxxxxxxxxxx>
> Cc: <linux-renesas-soc@xxxxxxxxxxxxxxx>
> Signed-off-by: Stephen Boyd <swboyd@xxxxxxxxxxxx>
> ---
> 
> Please ack or pick for immediate merge so the last patch can be merged.

Feel free to merge it via your tree:

Acked-by: Mauro Carvalho Chehab <mchehab+samsung@xxxxxxxxxx>


> 
>  drivers/media/platform/renesas-ceu.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/media/platform/renesas-ceu.c b/drivers/media/platform/renesas-ceu.c
> index 197b3991330d..60518bbc2cd5 100644
> --- a/drivers/media/platform/renesas-ceu.c
> +++ b/drivers/media/platform/renesas-ceu.c
> @@ -1679,7 +1679,7 @@ static int ceu_probe(struct platform_device *pdev)
>  	v4l2_async_notifier_init(&ceudev->notifier);
>  
>  	if (IS_ENABLED(CONFIG_OF) && dev->of_node) {
> -		ceu_data = of_match_device(ceu_of_match, dev)->data;
> +		ceu_data = of_device_get_match_data(dev);
>  		num_subdevs = ceu_parse_dt(ceudev);
>  	} else if (dev->platform_data) {
>  		/* Assume SH4 if booting with platform data. */



Thanks,
Mauro



[Index of Archives]     [Linux Samsung SOC]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux