linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] platform/chrome: cros_ec_typec: Add a dependency on USB_ROLE_SWITCH
@ 2020-06-29 10:32 Enric Balletbo i Serra
  2020-06-29 16:55 ` Prashant Malani
  2020-07-01  9:10 ` Enric Balletbo i Serra
  0 siblings, 2 replies; 3+ messages in thread
From: Enric Balletbo i Serra @ 2020-06-29 10:32 UTC (permalink / raw)
  To: linux-kernel
  Cc: Collabora Kernel ML, groeck, bleung, dtor, gwendal, pmalani,
	kernel test robot, Heikki Krogerus

As reported by the kernel test robot the cros_ec_typec driver fails to
build if the USB_ROLE_SWITCH is not selected, to fix that, add a
dependency on that symbol. This fixes the following build error:

   drivers/platform/chrome/cros_ec_typec.c:133: undefined reference to `usb_role_switch_put'
   ld: drivers/platform/chrome/cros_ec_typec.o: in function `cros_typec_get_switch_handles':
   drivers/platform/chrome/cros_ec_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: kernel test robot <lkp@intel.com>
Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
---

 drivers/platform/chrome/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/platform/chrome/Kconfig b/drivers/platform/chrome/Kconfig
index cf072153bdc5..a056031dee81 100644
--- a/drivers/platform/chrome/Kconfig
+++ b/drivers/platform/chrome/Kconfig
@@ -218,6 +218,7 @@ config CROS_EC_TYPEC
 	tristate "ChromeOS EC Type-C Connector Control"
 	depends on MFD_CROS_EC_DEV && TYPEC
 	depends on CROS_USBPD_NOTIFY
+	depends on USB_ROLE_SWITCH
 	default MFD_CROS_EC_DEV
 	help
 	  If you say Y here, you get support for accessing Type C connector
-- 
2.27.0


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

* Re: [PATCH] platform/chrome: cros_ec_typec: Add a dependency on USB_ROLE_SWITCH
  2020-06-29 10:32 [PATCH] platform/chrome: cros_ec_typec: Add a dependency on USB_ROLE_SWITCH Enric Balletbo i Serra
@ 2020-06-29 16:55 ` Prashant Malani
  2020-07-01  9:10 ` Enric Balletbo i Serra
  1 sibling, 0 replies; 3+ messages in thread
From: Prashant Malani @ 2020-06-29 16:55 UTC (permalink / raw)
  To: Enric Balletbo i Serra
  Cc: linux-kernel, Collabora Kernel ML, groeck, bleung, dtor, gwendal,
	kernel test robot, Heikki Krogerus

Hi Enric,

Thanks for the patch.

On Mon, Jun 29, 2020 at 12:32:23PM +0200, Enric Balletbo i Serra wrote:
> As reported by the kernel test robot the cros_ec_typec driver fails to
> build if the USB_ROLE_SWITCH is not selected, to fix that, add a
> dependency on that symbol. This fixes the following build error:
> 
>    drivers/platform/chrome/cros_ec_typec.c:133: undefined reference to `usb_role_switch_put'
>    ld: drivers/platform/chrome/cros_ec_typec.o: in function `cros_typec_get_switch_handles':
>    drivers/platform/chrome/cros_ec_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: kernel test robot <lkp@intel.com>
> Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Acked-by: Prashant Malani <pmalani@chromium.org>

> ---
> 
>  drivers/platform/chrome/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/platform/chrome/Kconfig b/drivers/platform/chrome/Kconfig
> index cf072153bdc5..a056031dee81 100644
> --- a/drivers/platform/chrome/Kconfig
> +++ b/drivers/platform/chrome/Kconfig
> @@ -218,6 +218,7 @@ config CROS_EC_TYPEC
>  	tristate "ChromeOS EC Type-C Connector Control"
>  	depends on MFD_CROS_EC_DEV && TYPEC
>  	depends on CROS_USBPD_NOTIFY
> +	depends on USB_ROLE_SWITCH
>  	default MFD_CROS_EC_DEV
>  	help
>  	  If you say Y here, you get support for accessing Type C connector
> -- 
> 2.27.0
> 

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

* Re: [PATCH] platform/chrome: cros_ec_typec: Add a dependency on USB_ROLE_SWITCH
  2020-06-29 10:32 [PATCH] platform/chrome: cros_ec_typec: Add a dependency on USB_ROLE_SWITCH Enric Balletbo i Serra
  2020-06-29 16:55 ` Prashant Malani
@ 2020-07-01  9:10 ` Enric Balletbo i Serra
  1 sibling, 0 replies; 3+ messages in thread
From: Enric Balletbo i Serra @ 2020-07-01  9:10 UTC (permalink / raw)
  To: linux-kernel
  Cc: Collabora Kernel ML, groeck, bleung, dtor, gwendal, pmalani,
	kernel test robot, Heikki Krogerus

Hi Prashant,

Thank you for you ack

On 29/6/20 12:32, Enric Balletbo i Serra wrote:
> As reported by the kernel test robot the cros_ec_typec driver fails to
> build if the USB_ROLE_SWITCH is not selected, to fix that, add a
> dependency on that symbol. This fixes the following build error:
> 
>    drivers/platform/chrome/cros_ec_typec.c:133: undefined reference to `usb_role_switch_put'
>    ld: drivers/platform/chrome/cros_ec_typec.o: in function `cros_typec_get_switch_handles':
>    drivers/platform/chrome/cros_ec_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: kernel test robot <lkp@intel.com>
> Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>

Applied for 5.9

> ---
> 
>  drivers/platform/chrome/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/platform/chrome/Kconfig b/drivers/platform/chrome/Kconfig
> index cf072153bdc5..a056031dee81 100644
> --- a/drivers/platform/chrome/Kconfig
> +++ b/drivers/platform/chrome/Kconfig
> @@ -218,6 +218,7 @@ config CROS_EC_TYPEC
>  	tristate "ChromeOS EC Type-C Connector Control"
>  	depends on MFD_CROS_EC_DEV && TYPEC
>  	depends on CROS_USBPD_NOTIFY
> +	depends on USB_ROLE_SWITCH
>  	default MFD_CROS_EC_DEV
>  	help
>  	  If you say Y here, you get support for accessing Type C connector
> 

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

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

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-29 10:32 [PATCH] platform/chrome: cros_ec_typec: Add a dependency on USB_ROLE_SWITCH Enric Balletbo i Serra
2020-06-29 16:55 ` Prashant Malani
2020-07-01  9:10 ` Enric Balletbo i Serra

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).