Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-11-17 Thread Dan Scally
On 17/11/2020 16:42, Andy Shevchenko wrote: > On Tue, Nov 17, 2020 at 2:02 PM Dan Scally wrote: >> On 16/11/2020 16:16, Andy Shevchenko wrote: >>> On Mon, Nov 16, 2020 at 02:15:01PM +, Dan Scally wrote: On 16/11/2020 14:10, Laurent Pinchart wrote: > I thought we were looking for ACPI

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-11-17 Thread Andy Shevchenko
On Tue, Nov 17, 2020 at 2:02 PM Dan Scally wrote: > > On 16/11/2020 16:16, Andy Shevchenko wrote: > > On Mon, Nov 16, 2020 at 02:15:01PM +, Dan Scally wrote: > >> On 16/11/2020 14:10, Laurent Pinchart wrote: > >>> I thought we were looking for ACPI devices, not companion devices, in > >>>

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-11-17 Thread Dan Scally
On 16/11/2020 16:16, Andy Shevchenko wrote: > On Mon, Nov 16, 2020 at 02:15:01PM +, Dan Scally wrote: >> On 16/11/2020 14:10, Laurent Pinchart wrote: >>> I thought we were looking for ACPI devices, not companion devices, in >>> order to extract information from the DSDT and store it in a

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-11-16 Thread Andy Shevchenko
On Mon, Nov 16, 2020 at 02:15:01PM +, Dan Scally wrote: > On 16/11/2020 14:10, Laurent Pinchart wrote: > > On Mon, Nov 16, 2020 at 03:57:17PM +0200, Andy Shevchenko wrote: > >> On Mon, Nov 16, 2020 at 10:53 AM Laurent Pinchart wrote: > >>> On Fri, Nov 13, 2020 at 09:45:00PM +0200, Andy

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-11-16 Thread Dan Scally
On 16/11/2020 14:10, Laurent Pinchart wrote: > Hi Andy, > > On Mon, Nov 16, 2020 at 03:57:17PM +0200, Andy Shevchenko wrote: >> On Mon, Nov 16, 2020 at 10:53 AM Laurent Pinchart wrote: >>> On Fri, Nov 13, 2020 at 09:45:00PM +0200, Andy Shevchenko wrote: On Fri, Nov 13, 2020 at 6:22 PM

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-11-16 Thread Laurent Pinchart
Hi Andy, On Mon, Nov 16, 2020 at 03:57:17PM +0200, Andy Shevchenko wrote: > On Mon, Nov 16, 2020 at 10:53 AM Laurent Pinchart wrote: > > On Fri, Nov 13, 2020 at 09:45:00PM +0200, Andy Shevchenko wrote: > > > On Fri, Nov 13, 2020 at 6:22 PM Laurent Pinchart wrote: > > > > On Fri, Nov 13, 2020 at

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-11-16 Thread Andy Shevchenko
On Mon, Nov 16, 2020 at 10:53 AM Laurent Pinchart wrote: > On Fri, Nov 13, 2020 at 09:45:00PM +0200, Andy Shevchenko wrote: > > On Fri, Nov 13, 2020 at 6:22 PM Laurent Pinchart wrote: > > > On Fri, Nov 13, 2020 at 10:02:30AM +, Dan Scally wrote: > > > > On 29/10/2020 22:51, Laurent Pinchart

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-11-16 Thread Laurent Pinchart
Hi Andy, On Fri, Nov 13, 2020 at 09:45:00PM +0200, Andy Shevchenko wrote: > On Fri, Nov 13, 2020 at 6:22 PM Laurent Pinchart wrote: > > On Fri, Nov 13, 2020 at 10:02:30AM +, Dan Scally wrote: > > > On 29/10/2020 22:51, Laurent Pinchart wrote: > > > > On Fri, Oct 30, 2020 at 12:22:15AM +0200,

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-11-15 Thread Daniel Scally
On 13/11/2020 19:45, Andy Shevchenko wrote: > On Fri, Nov 13, 2020 at 6:22 PM Laurent Pinchart > wrote: >> On Fri, Nov 13, 2020 at 10:02:30AM +, Dan Scally wrote: >>> On 29/10/2020 22:51, Laurent Pinchart wrote: On Fri, Oct 30, 2020 at 12:22:15AM +0200, Andy Shevchenko wrote: > On

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-11-13 Thread Andy Shevchenko
On Fri, Nov 13, 2020 at 6:22 PM Laurent Pinchart wrote: > On Fri, Nov 13, 2020 at 10:02:30AM +, Dan Scally wrote: > > On 29/10/2020 22:51, Laurent Pinchart wrote: > > > On Fri, Oct 30, 2020 at 12:22:15AM +0200, Andy Shevchenko wrote: > > >> On Thu, Oct 29, 2020 at 11:29:30PM +0200, Laurent

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-11-13 Thread Laurent Pinchart
Hi Dan, On Fri, Nov 13, 2020 at 10:02:30AM +, Dan Scally wrote: > On 29/10/2020 22:51, Laurent Pinchart wrote: > > On Fri, Oct 30, 2020 at 12:22:15AM +0200, Andy Shevchenko wrote: > >> On Thu, Oct 29, 2020 at 11:29:30PM +0200, Laurent Pinchart wrote: > >>> On Thu, Oct 29, 2020 at 10:26:56PM

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-11-13 Thread Dan Scally
On 29/10/2020 22:51, Laurent Pinchart wrote: > Hi Andy, > > On Fri, Oct 30, 2020 at 12:22:15AM +0200, Andy Shevchenko wrote: >> On Thu, Oct 29, 2020 at 11:29:30PM +0200, Laurent Pinchart wrote: >>> On Thu, Oct 29, 2020 at 10:26:56PM +0200, Andy Shevchenko wrote: On Thu, Oct 29, 2020 at 10:21

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-29 Thread Laurent Pinchart
Hi Andy, On Fri, Oct 30, 2020 at 12:22:15AM +0200, Andy Shevchenko wrote: > On Thu, Oct 29, 2020 at 11:29:30PM +0200, Laurent Pinchart wrote: > > On Thu, Oct 29, 2020 at 10:26:56PM +0200, Andy Shevchenko wrote: > > > On Thu, Oct 29, 2020 at 10:21 PM Laurent Pinchart wrote: > > > > On Mon, Oct 26,

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-29 Thread Dan Scally
Hi both On 29/10/2020 20:17, Laurent Pinchart wrote: > Hi Andy, > > On Mon, Oct 26, 2020 at 06:05:49PM +0200, Andy Shevchenko wrote: >> On Mon, Oct 26, 2020 at 08:20:14AM +, Dan Scally wrote: >>> On 24/10/2020 23:36, Laurent Pinchart wrote: On Sat, Oct 24, 2020 at 11:28:06PM +0100,

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-29 Thread Andy Shevchenko
On Thu, Oct 29, 2020 at 11:29:30PM +0200, Laurent Pinchart wrote: > On Thu, Oct 29, 2020 at 10:26:56PM +0200, Andy Shevchenko wrote: > > On Thu, Oct 29, 2020 at 10:21 PM Laurent Pinchart wrote: > > > On Mon, Oct 26, 2020 at 06:10:50PM +0200, Andy Shevchenko wrote: > > > > On Sat, Oct 24, 2020 at

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-29 Thread Laurent Pinchart
On Thu, Oct 29, 2020 at 10:26:56PM +0200, Andy Shevchenko wrote: > On Thu, Oct 29, 2020 at 10:21 PM Laurent Pinchart wrote: > > On Mon, Oct 26, 2020 at 06:10:50PM +0200, Andy Shevchenko wrote: > > > On Sat, Oct 24, 2020 at 12:37:02PM +0300, Laurent Pinchart wrote: > > > > On Sat, Oct 24, 2020 at

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-29 Thread Andy Shevchenko
On Thu, Oct 29, 2020 at 10:21 PM Laurent Pinchart wrote: > On Mon, Oct 26, 2020 at 06:10:50PM +0200, Andy Shevchenko wrote: > > On Sat, Oct 24, 2020 at 12:37:02PM +0300, Laurent Pinchart wrote: > > > On Sat, Oct 24, 2020 at 09:50:07AM +0100, Dan Scally wrote: > > > > On 24/10/2020 02:24, Laurent

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-29 Thread Laurent Pinchart
Hi Andy, On Mon, Oct 26, 2020 at 06:10:50PM +0200, Andy Shevchenko wrote: > On Sat, Oct 24, 2020 at 12:37:02PM +0300, Laurent Pinchart wrote: > > On Sat, Oct 24, 2020 at 09:50:07AM +0100, Dan Scally wrote: > > > On 24/10/2020 02:24, Laurent Pinchart wrote: > > > > On Mon, Oct 19, 2020 at

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-29 Thread Laurent Pinchart
Hi Andy, On Mon, Oct 26, 2020 at 06:05:49PM +0200, Andy Shevchenko wrote: > On Mon, Oct 26, 2020 at 08:20:14AM +, Dan Scally wrote: > > On 24/10/2020 23:36, Laurent Pinchart wrote: > > > On Sat, Oct 24, 2020 at 11:28:06PM +0100, Daniel Scally wrote: > > >> On 24/10/2020 10:37, Laurent

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-26 Thread Dan Scally
On 24/10/2020 23:36, Laurent Pinchart wrote: > Hi Dan, > > On Sat, Oct 24, 2020 at 11:28:06PM +0100, Daniel Scally wrote: >> On 24/10/2020 10:37, Laurent Pinchart wrote: > I wonder if we could avoid depending on the I2C device being created by > getting the fwnode from adev, and setting

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-25 Thread Sakari Ailus
Hi Daniel, On Sat, Oct 24, 2020 at 09:28:07PM +0100, Dan Scally wrote: ... > >> +int cio2_bridge_build(struct pci_dev *cio2) > >> +{ > >> + struct fwnode_handle *fwnode; > >> + int ret; > >> + > >> + pci_dev_get(cio2); > > Could you check that this isn't used by more than one user? The current

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-24 Thread Daniel Scally
Hi Laurent On 24/10/2020 23:36, Laurent Pinchart wrote: > Hi Dan, > > On Sat, Oct 24, 2020 at 11:28:06PM +0100, Daniel Scally wrote: >> On 24/10/2020 10:37, Laurent Pinchart wrote: >> > I wonder if we could avoid depending on the I2C device being created by > getting the fwnode from adev,

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-24 Thread Laurent Pinchart
Hi Dan, On Sat, Oct 24, 2020 at 11:28:06PM +0100, Daniel Scally wrote: > On 24/10/2020 10:37, Laurent Pinchart wrote: > > > >>> I wonder if we could avoid depending on the I2C device being created by > >>> getting the fwnode from adev, and setting ->secondary manually. adev > >>> would need to be

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-24 Thread Daniel Scally
Hi Laurent On 24/10/2020 10:37, Laurent Pinchart wrote: > >>> I wonder if we could avoid depending on the I2C device being created by >>> getting the fwnode from adev, and setting ->secondary manually. adev >>> would need to be passed to get_acpi_ssdb_sensor_data() instead of dev. >> Let me try

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-24 Thread Dan Scally
On 24/10/2020 16:14, Sakari Ailus wrote: > Hi Daniel, > > Thanks for the update. Thanks for the comments as always >> +// SPDX-License-Identifier: GPL-2.0 >> +// Author: Dan Scally > /* Author: ... */ > > But not the SPDX tag. Weird - okedokey >> +#include >> +#include >> +#include >>

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-24 Thread Sakari Ailus
Hi Daniel, Thanks for the update. On Mon, Oct 19, 2020 at 11:59:03PM +0100, Daniel Scally wrote: > Currently on platforms designed for Windows, connections between CIO2 and > sensors are not properly defined in DSDT. This patch extends the ipu3-cio2 > driver to compensate by building

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-24 Thread Sakari Ailus
Hi Laurent, Daniel, On Sat, Oct 24, 2020 at 04:24:11AM +0300, Laurent Pinchart wrote: > Hi Daniel, > > Thank you for the patch. > > On Mon, Oct 19, 2020 at 11:59:03PM +0100, Daniel Scally wrote: > > Currently on platforms designed for Windows, connections between CIO2 and > > sensors are not

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-24 Thread Laurent Pinchart
Hi Daniel, On Sat, Oct 24, 2020 at 09:50:07AM +0100, Dan Scally wrote: > On 24/10/2020 02:24, Laurent Pinchart wrote: > > > On Mon, Oct 19, 2020 at 11:59:03PM +0100, Daniel Scally wrote: > >> Currently on platforms designed for Windows, connections between CIO2 and > >> sensors are not properly

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-24 Thread Dan Scally
On 24/10/2020 02:24, Laurent Pinchart wrote: > Hi Daniel, > > Thank you for the patch. Thank you for reviewing it - very helpful comments > > On Mon, Oct 19, 2020 at 11:59:03PM +0100, Daniel Scally wrote: >> Currently on platforms designed for Windows, connections between CIO2 and >> sensors are

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-23 Thread Laurent Pinchart
Hi Daniel, Thank you for the patch. On Mon, Oct 19, 2020 at 11:59:03PM +0100, Daniel Scally wrote: > Currently on platforms designed for Windows, connections between CIO2 and > sensors are not properly defined in DSDT. This patch extends the ipu3-cio2 > driver to compensate by building

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-23 Thread Dan Scally
On 22/10/2020 14:40, Andy Shevchenko wrote: > On Thu, Oct 22, 2020 at 3:59 PM Daniel Scally wrote: >> On 20/10/2020 10:41, Andy Shevchenko wrote: > ... > +static const char * const port_names[] = { +"port0", "port1", "port2", "port3" >>> + comma. >> I think 4 ports is the maximum

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-22 Thread Andy Shevchenko
On Thu, Oct 22, 2020 at 3:59 PM Daniel Scally wrote: > On 20/10/2020 10:41, Andy Shevchenko wrote: ... > >> +static const char * const port_names[] = { > >> +"port0", "port1", "port2", "port3" > > + comma. > I think 4 ports is the maximum for CIO2 device, so this shouldn't ever > get

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-21 Thread Daniel Scally
Hi Andy On 20/10/2020 10:41, Andy Shevchenko wrote: >> +- Some Microsoft Surface models > Perhaps an example? Like '(e.g. Surface Book)' > >> +- The Lenovo Miix line > Ditto. Sure - I'll list them. >> +static const char * const port_names[] = { >> +"port0", "port1",

Re: [RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-20 Thread Andy Shevchenko
On Mon, Oct 19, 2020 at 11:59:03PM +0100, Daniel Scally wrote: > Currently on platforms designed for Windows, connections between CIO2 and > sensors are not properly defined in DSDT. This patch extends the ipu3-cio2 > driver to compensate by building software_node connections, parsing the >

[RFC PATCH v3 9/9] ipu3-cio2: Add functionality allowing software_node connections to sensors on platforms designed for Windows

2020-10-19 Thread Daniel Scally
Currently on platforms designed for Windows, connections between CIO2 and sensors are not properly defined in DSDT. This patch extends the ipu3-cio2 driver to compensate by building software_node connections, parsing the connection properties from the sensor's SSDB buffer. Suggested-by: Jordan