Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-29 Thread Stephen Boyd
Quoting Rob Herring (2018-11-29 17:01:54) > On Thu, Nov 29, 2018 at 6:28 PM Stephen Boyd wrote: > > > > Quoting Stephen Boyd (2018-11-07 10:37:31) > > > appropriate structure with to_platform_device() or to_i2c_client()? > > > > > > So the example would become > > > > > > struct

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-29 Thread Stephen Boyd
Quoting Rob Herring (2018-11-29 17:01:54) > On Thu, Nov 29, 2018 at 6:28 PM Stephen Boyd wrote: > > > > Quoting Stephen Boyd (2018-11-07 10:37:31) > > > appropriate structure with to_platform_device() or to_i2c_client()? > > > > > > So the example would become > > > > > > struct

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-29 Thread Rob Herring
On Thu, Nov 29, 2018 at 6:28 PM Stephen Boyd wrote: > > Quoting Stephen Boyd (2018-11-07 10:37:31) > > appropriate structure with to_platform_device() or to_i2c_client()? > > > > So the example would become > > > > struct of_driver_probe_func { > > int (*probe)(struct device *dev); > >

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-29 Thread Rob Herring
On Thu, Nov 29, 2018 at 6:28 PM Stephen Boyd wrote: > > Quoting Stephen Boyd (2018-11-07 10:37:31) > > appropriate structure with to_platform_device() or to_i2c_client()? > > > > So the example would become > > > > struct of_driver_probe_func { > > int (*probe)(struct device *dev); > >

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-29 Thread Stephen Boyd
Quoting Stephen Boyd (2018-11-07 10:37:31) > appropriate structure with to_platform_device() or to_i2c_client()? > > So the example would become > > struct of_driver_probe_func { > int (*probe)(struct device *dev); > }; > > struct of_driver_probe_func mtk_probes[] = { >

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-29 Thread Stephen Boyd
Quoting Stephen Boyd (2018-11-07 10:37:31) > appropriate structure with to_platform_device() or to_i2c_client()? > > So the example would become > > struct of_driver_probe_func { > int (*probe)(struct device *dev); > }; > > struct of_driver_probe_func mtk_probes[] = { >

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Geert Uytterhoeven
Hi Stephen, On Fri, Nov 9, 2018 at 5:59 PM Stephen Boyd wrote: > Quoting Geert Uytterhoeven (2018-11-09 01:56:01) > > On Wed, Nov 7, 2018 at 7:37 PM Stephen Boyd wrote: > > > Quoting Rob Herring (2018-11-06 12:44:52) > > > > On Tue, Nov 6, 2018 at 12:36 PM Stephen Boyd wrote: > > > int

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Geert Uytterhoeven
Hi Stephen, On Fri, Nov 9, 2018 at 5:59 PM Stephen Boyd wrote: > Quoting Geert Uytterhoeven (2018-11-09 01:56:01) > > On Wed, Nov 7, 2018 at 7:37 PM Stephen Boyd wrote: > > > Quoting Rob Herring (2018-11-06 12:44:52) > > > > On Tue, Nov 6, 2018 at 12:36 PM Stephen Boyd wrote: > > > int

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Stephen Boyd
Quoting Geert Uytterhoeven (2018-11-09 01:56:01) > On Wed, Nov 7, 2018 at 7:37 PM Stephen Boyd wrote: > > Quoting Rob Herring (2018-11-06 12:44:52) > > > On Tue, Nov 6, 2018 at 12:36 PM Stephen Boyd wrote: > > int (*probe)(struct platform_device *pdev); > > }; > > > > struct

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Stephen Boyd
Quoting Geert Uytterhoeven (2018-11-09 01:56:01) > On Wed, Nov 7, 2018 at 7:37 PM Stephen Boyd wrote: > > Quoting Rob Herring (2018-11-06 12:44:52) > > > On Tue, Nov 6, 2018 at 12:36 PM Stephen Boyd wrote: > > int (*probe)(struct platform_device *pdev); > > }; > > > > struct

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Frank Rowand
On 11/9/18 2:36 AM, Geert Uytterhoeven wrote: > Hi Matthias, > > On Fri, Nov 9, 2018 at 11:29 AM Matthias Brugger > wrote: >> On 08/11/2018 18:58, Stephen Boyd wrote: >>> Quoting Matthias Brugger (2018-11-08 00:29:46) On 06/11/2018 19:36, Stephen Boyd wrote: > +int

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Frank Rowand
On 11/9/18 2:36 AM, Geert Uytterhoeven wrote: > Hi Matthias, > > On Fri, Nov 9, 2018 at 11:29 AM Matthias Brugger > wrote: >> On 08/11/2018 18:58, Stephen Boyd wrote: >>> Quoting Matthias Brugger (2018-11-08 00:29:46) On 06/11/2018 19:36, Stephen Boyd wrote: > +int

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Rob Herring
On Fri, Nov 9, 2018 at 4:36 AM Geert Uytterhoeven wrote: > > Hi Matthias, > > On Fri, Nov 9, 2018 at 11:29 AM Matthias Brugger > wrote: > > On 08/11/2018 18:58, Stephen Boyd wrote: > > > Quoting Matthias Brugger (2018-11-08 00:29:46) > > >> On 06/11/2018 19:36, Stephen Boyd wrote: > > >>> +int

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Rob Herring
On Fri, Nov 9, 2018 at 4:36 AM Geert Uytterhoeven wrote: > > Hi Matthias, > > On Fri, Nov 9, 2018 at 11:29 AM Matthias Brugger > wrote: > > On 08/11/2018 18:58, Stephen Boyd wrote: > > > Quoting Matthias Brugger (2018-11-08 00:29:46) > > >> On 06/11/2018 19:36, Stephen Boyd wrote: > > >>> +int

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Geert Uytterhoeven
Hi Matthias, On Fri, Nov 9, 2018 at 11:29 AM Matthias Brugger wrote: > On 08/11/2018 18:58, Stephen Boyd wrote: > > Quoting Matthias Brugger (2018-11-08 00:29:46) > >> On 06/11/2018 19:36, Stephen Boyd wrote: > >>> +int platform_driver_probe_by_of_match_data(struct platform_device *pdev) > >>>

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Geert Uytterhoeven
Hi Matthias, On Fri, Nov 9, 2018 at 11:29 AM Matthias Brugger wrote: > On 08/11/2018 18:58, Stephen Boyd wrote: > > Quoting Matthias Brugger (2018-11-08 00:29:46) > >> On 06/11/2018 19:36, Stephen Boyd wrote: > >>> +int platform_driver_probe_by_of_match_data(struct platform_device *pdev) > >>>

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Matthias Brugger
On 08/11/2018 18:58, Stephen Boyd wrote: > Quoting Matthias Brugger (2018-11-08 00:29:46) >> On 06/11/2018 19:36, Stephen Boyd wrote: >>> +int platform_driver_probe_by_of_match_data(struct platform_device *pdev) >>> +{ >>> + int (*probe_func)(struct platform_device *pdev); >>> + >>> +

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Matthias Brugger
On 08/11/2018 18:58, Stephen Boyd wrote: > Quoting Matthias Brugger (2018-11-08 00:29:46) >> On 06/11/2018 19:36, Stephen Boyd wrote: >>> +int platform_driver_probe_by_of_match_data(struct platform_device *pdev) >>> +{ >>> + int (*probe_func)(struct platform_device *pdev); >>> + >>> +

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Geert Uytterhoeven
Hi Stephen, On Wed, Nov 7, 2018 at 7:37 PM Stephen Boyd wrote: > Quoting Rob Herring (2018-11-06 12:44:52) > > On Tue, Nov 6, 2018 at 12:36 PM Stephen Boyd wrote: > > > We have a handful of clk drivers that have a collection of slightly > > > variant device support keyed off of the compatible

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-09 Thread Geert Uytterhoeven
Hi Stephen, On Wed, Nov 7, 2018 at 7:37 PM Stephen Boyd wrote: > Quoting Rob Herring (2018-11-06 12:44:52) > > On Tue, Nov 6, 2018 at 12:36 PM Stephen Boyd wrote: > > > We have a handful of clk drivers that have a collection of slightly > > > variant device support keyed off of the compatible

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-08 Thread Stephen Boyd
Quoting Matthias Brugger (2018-11-08 00:29:46) > On 06/11/2018 19:36, Stephen Boyd wrote: > > +int platform_driver_probe_by_of_match_data(struct platform_device *pdev) > > +{ > > + int (*probe_func)(struct platform_device *pdev); > > + > > + probe_func = of_device_get_match_data(>dev); >

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-08 Thread Stephen Boyd
Quoting Matthias Brugger (2018-11-08 00:29:46) > On 06/11/2018 19:36, Stephen Boyd wrote: > > +int platform_driver_probe_by_of_match_data(struct platform_device *pdev) > > +{ > > + int (*probe_func)(struct platform_device *pdev); > > + > > + probe_func = of_device_get_match_data(>dev); >

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-08 Thread Matthias Brugger
On 06/11/2018 19:36, Stephen Boyd wrote: > We have a handful of clk drivers that have a collection of slightly > variant device support keyed off of the compatible string. In each of > these drivers, we demux the variant and then call the "real" probe > function based on whatever is stored in

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-08 Thread Matthias Brugger
On 06/11/2018 19:36, Stephen Boyd wrote: > We have a handful of clk drivers that have a collection of slightly > variant device support keyed off of the compatible string. In each of > these drivers, we demux the variant and then call the "real" probe > function based on whatever is stored in

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-07 Thread Stephen Boyd
Quoting Rob Herring (2018-11-06 12:44:52) > On Tue, Nov 6, 2018 at 12:36 PM Stephen Boyd wrote: > > > > We have a handful of clk drivers that have a collection of slightly > > variant device support keyed off of the compatible string. In each of > > these drivers, we demux the variant and then

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-07 Thread Stephen Boyd
Quoting Rob Herring (2018-11-06 12:44:52) > On Tue, Nov 6, 2018 at 12:36 PM Stephen Boyd wrote: > > > > We have a handful of clk drivers that have a collection of slightly > > variant device support keyed off of the compatible string. In each of > > these drivers, we demux the variant and then

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-06 Thread Rob Herring
On Tue, Nov 6, 2018 at 12:36 PM Stephen Boyd wrote: > > We have a handful of clk drivers that have a collection of slightly > variant device support keyed off of the compatible string. In each of > these drivers, we demux the variant and then call the "real" probe > function based on whatever is

Re: [PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-06 Thread Rob Herring
On Tue, Nov 6, 2018 at 12:36 PM Stephen Boyd wrote: > > We have a handful of clk drivers that have a collection of slightly > variant device support keyed off of the compatible string. In each of > these drivers, we demux the variant and then call the "real" probe > function based on whatever is

[PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-06 Thread Stephen Boyd
We have a handful of clk drivers that have a collection of slightly variant device support keyed off of the compatible string. In each of these drivers, we demux the variant and then call the "real" probe function based on whatever is stored in the match data for that compatible string. Let's

[PATCH 1/4] of/device: Add a way to probe drivers by match data

2018-11-06 Thread Stephen Boyd
We have a handful of clk drivers that have a collection of slightly variant device support keyed off of the compatible string. In each of these drivers, we demux the variant and then call the "real" probe function based on whatever is stored in the match data for that compatible string. Let's