Re: [PATCH] usb: typec: Add num_altmodes partner attribute

2020-07-01 Thread Prashant Malani
Hi Greg, Thanks a lot for looking at the patch. (trimming text) On Wed, Jul 01, 2020 at 02:01:31PM +0200, Greg Kroah-Hartman wrote: > On Tue, Jun 30, 2020 at 05:31:48PM -0700, Prashant Malani wrote: > > Add a user-visible attribute for the number of alt modes available in a > >

Re: [PATCH] usb: typec: Add num_altmodes partner attribute

2020-07-01 Thread Prashant Malani
Hi Heikki, Thanks a lot for reviewing the patch. On Wed, Jul 01, 2020 at 11:22:30AM +0300, Heikki Krogerus wrote: > Hi Prashant, > > On Tue, Jun 30, 2020 at 05:31:48PM -0700, Prashant Malani wrote: > > Add a user-visible attribute for the number of alt modes available in a &g

Re: [PATCH] platform/chrome: cros_ec_debugfs: Support pd_info v2 format

2020-09-15 Thread Prashant Malani
the v1 format. This > > gives us more information about things such as DP mode of the typec pins > > and the CC state, along with some more things. > > > > Cc: Gwendal Grignou > > Cc: Prashant Malani > > Cc: Guenter Roeck > > Signed-off-by: Stephen Boy

Re: [PATCH] platform/chrome: cros_ec_debugfs: Support pd_info v2 format

2020-09-16 Thread Prashant Malani
Hi Enric, On Wed, Sep 16, 2020 at 2:39 AM Enric Balletbo i Serra wrote: > > Hi Prashant, > > > If I am not mistaken pdinfo is used by your userspace, so, assuming we don't > break (or we have a plan to not break) things I'm fine with it. In general, > delegating things to userspace and get rid of

Re: [PATCH 1/2] platform/chrome: cros_ec_typec: Add TBT pd_ctrl fields

2020-06-26 Thread Prashant Malani
Thanks Enric! On Fri, Jun 26, 2020 at 2:11 AM Enric Balletbo i Serra wrote: > > Hi Prashant, > > On 24/6/20 10:09, Prashant Malani wrote: > > To support Thunderbolt compatibility mode, synchronize > > ec_response_usb_pd_control_v2 with the Chrome EC version, so that &g

[PATCH 2/2] platform/chrome: cros_ec_typec: Add PM support

2020-06-26 Thread Prashant Malani
Define basic suspend resume functions for cros-ec-typec. On suspend, we simply ensure that any pending port update work is completed, and on resume, we re-poll the port state to account for any changes/disconnections that might have occurred during suspend. Signed-off-by: Prashant Malani

[PATCH 1/2] platform/chrome: cros_ec_typec: Use workqueue for port update

2020-06-26 Thread Prashant Malani
Use a work queue to call the port update routines, instead of doing it directly in the PD notifier callback. This will prevent other drivers with PD notifier callbacks from being blocked on the port update routine completing. Signed-off-by: Prashant Malani --- drivers/platform/chrome

[PATCH v2 1/2] platform/chrome: cros_ec_typec: Use workqueue for port update

2020-06-29 Thread Prashant Malani
Use a work queue to call the port update routines, instead of doing it directly in the PD notifier callback. This will prevent other drivers with PD notifier callbacks from being blocked on the port update routine completing. Signed-off-by: Prashant Malani --- Changes in v2: - No changes

Re: [PATCH v2 1/2] platform/chrome: cros_ec_typec: Use workqueue for port update

2020-06-29 Thread Prashant Malani
Hi Guenter, Thanks for the review! On Mon, Jun 29, 2020 at 9:24 AM Guenter Roeck wrote: > > On Mon, Jun 29, 2020 at 9:13 AM Prashant Malani wrote: > > > > Use a work queue to call the port update routines, instead of doing it > > directly in the PD notifier callback.

[PATCH v3 1/2] platform/chrome: cros_ec_typec: Use workqueue for port update

2020-06-29 Thread Prashant Malani
Use a work queue to call the port update routines, instead of doing it directly in the PD notifier callback. This will prevent other drivers with PD notifier callbacks from being blocked on the port update routine completing. Signed-off-by: Prashant Malani --- Changes in v3: - Use new 100

[PATCH v3 2/2] platform/chrome: cros_ec_typec: Add PM support

2020-06-29 Thread Prashant Malani
Define basic suspend resume functions for cros-ec-typec. On suspend, we simply ensure that any pending port update work is completed, and on resume, we re-poll the port state to account for any changes/disconnections that might have occurred during suspend. Signed-off-by: Prashant Malani

Re: [PATCH] platform/chrome: cros_ec_typec: Add a dependency on USB_ROLE_SWITCH

2020-06-29 Thread Prashant Malani
c_typec.c:108: undefined reference to > `fwnode_usb_role_switch_get' >ld: drivers/platform/chrome/cros_ec_typec.c:117: undefined reference to > `usb_role_switch_put' > > Fixes: 7e7def15fa4b ("platform/chrome: cros_ec_typec: Add USB mux control") > Reported-by: ker

Re: [PATCH 2/4] usb: typec: mux: intel_pmc_mux: Support for static SBU/HSL orientation

2020-05-11 Thread Prashant Malani
Hi Heikki, Thanks a lot for looking into this. Kindly see my response inline: On Mon, May 11, 2020 at 04:32:02PM +0300, Heikki Krogerus wrote: > On Fri, May 08, 2020 at 02:18:44PM +0300, Heikki Krogerus wrote: > > Hi Prashant, > > > > On Thu, May 07, 2020 at 03:40:41PM -

Re: [PATCH 1/2] dt-bindings: chrome: Add cros-ec-typec mux props

2020-05-11 Thread Prashant Malani
Hi Rob, Apologies in case you've already looked at this, but could you kindly review this patch? Thanks, -Prashant On Wed, Apr 22, 2020 at 03:22:39PM -0700, Prashant Malani wrote: > Add properties for mode, orientation and USB data role switches for > Type C connectors. When avail

Re: [PATCH 1/2] dt-bindings: chrome: Add cros-ec-typec mux props

2020-05-11 Thread Prashant Malani
Hi Rob, Thank you for reviewing the patch. Kindly see my comments inline: On Mon, May 11, 2020 at 02:28:00PM -0500, Rob Herring wrote: > On Wed, Apr 22, 2020 at 03:22:39PM -0700, Prashant Malani wrote: > > Add properties for mode, orientation and USB data role switches for > > Ty

Re: [PATCH 2/4] usb: typec: mux: intel_pmc_mux: Support for static SBU/HSL orientation

2020-05-12 Thread Prashant Malani
Hi Heikki, On Tue, May 12, 2020 at 05:22:51PM +0300, Heikki Krogerus wrote: > Hi Prashant, > > On Mon, May 11, 2020 at 10:57:19AM -0700, Prashant Malani wrote: > > Hi Heikki, > > > > Thanks a lot for looking into this. Kindly see my response inline: > > >

[PATCH] platform/chrome: cros_ec_typec: Make configure_mux static

2020-06-19 Thread Prashant Malani
Since cros_typec_configure_mux() is only used in cros-ec-typec, it should be marked static. Fixes: 7e7def15fa4b ("platform/chrome: cros_ec_typec: Add USB mux control") Reported-by: kernel test robot Signed-off-by: Prashant Malani --- drivers/platform/chrome/cros_ec_typec.c | 6 +++-

Re: [PATCH 1/2] dt-bindings: chrome: Add cros-ec-typec mux props

2020-06-09 Thread Prashant Malani
Hi Rob, Thanks again for the comments and feedback. Kindly see responses inline: (Trimming unrelated text from thread): On Tue, Jun 09, 2020 at 02:30:11PM -0600, Rob Herring wrote: > On Fri, May 29, 2020 at 5:30 PM Prashant Malani wrote: > > > > Nodes truncated and unrelated fi

Re: [PATCH 2/4] usb: typec: mux: intel_pmc_mux: Support for static SBU/HSL orientation

2020-05-07 Thread Prashant Malani
Hi Heikki, Thanks for the patches. On Thu, May 07, 2020 at 06:08:58PM +0300, Heikki Krogerus wrote: > The SBU and HSL orientation may be fixed/static from the mux > PoW. Apparently the retimer may take care of the orientation > of these lines. Handling the static SBU (AUX) and HSL > orientation w

Re: [PATCH 2/4] usb: typec: mux: intel_pmc_mux: Support for static SBU/HSL orientation

2020-05-08 Thread Prashant Malani
On Fri, May 08, 2020 at 02:18:40PM +0300, Heikki Krogerus wrote: > Hi Prashant, > > On Thu, May 07, 2020 at 03:40:41PM -0700, Prashant Malani wrote: > > > +static int sbu_orientation(struct pmc_usb_port *port) > > > +{ > > > + if (port->sbu_o

[PATCH 2/2] platform/chrome: cros_ec_typec: Add TBT compat support

2020-06-24 Thread Prashant Malani
Add mux control support for Thunderbolt compatibility mode. Suggested-by: Heikki Krogerus Co-developed-by: Azhar Shaikh Co-developed-by: Casey Bowman Signed-off-by: Prashant Malani --- drivers/platform/chrome/cros_ec_typec.c | 70 - 1 file changed, 69 insertions(+), 1

[PATCH 1/2] platform/chrome: cros_ec_typec: Add TBT pd_ctrl fields

2020-06-24 Thread Prashant Malani
To support Thunderbolt compatibility mode, synchronize ec_response_usb_pd_control_v2 with the Chrome EC version, so that we get the Thunderbolt related control fields and macros. Signed-off-by: Prashant Malani --- .../linux/platform_data/cros_ec_commands.h| 19 +++ 1 file

[PATCH v2 1/2] dt-bindings: chrome: Add cros-ec-typec mux props

2020-05-18 Thread Prashant Malani
. Signed-off-by: Prashant Malani Acked-By: Benson Leung --- Changes in v2: - Added more text to the switch descriptions, explaining their purpose, and relation to the Type C connector class framework. .../bindings/chrome/google,cros-ec-typec.yaml | 40 ++- 1 file changed, 39

[PATCH v2 2/2] platform/chrome: typec: Register Type C switches

2020-05-18 Thread Prashant Malani
Register Type C mux and switch handles, when provided via firmware bindings. These will allow the cros-ec-typec driver, and also alternate mode drivers to configure connected Muxes correctly, according to PD information retrieved from the Chrome OS EC. Signed-off-by: Prashant Malani Reviewed-by

Re: [PATCH 2/2] platform/chrome: typec: Register Type C switches

2020-05-18 Thread Prashant Malani
Hi Enric, On Thu, Apr 30, 2020 at 12:25:10AM +0200, Enric Balletbo i Serra wrote: > Hi Prashant, > > Following my previous comments ... > > On 23/4/20 0:22, Prashant Malani wrote: > > Register Type C mux and switch handles, when provided via firmware > > bindings. T

<    1   2   3