public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Heikki Krogerus <heikki.krogerus@linux.intel.com>
To: Ren Zhijie <renzhijie2@huawei.com>
Cc: gregkh@linuxfoundation.org, cy_huang@richtek.com,
	linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH -next] usb: typec: rt1719: Fix build error without CONFIG_POWER_SUPPLY
Date: Wed, 20 Apr 2022 12:06:36 +0300	[thread overview]
Message-ID: <Yl/NHAaXFh1UzFdI@kuha.fi.intel.com> (raw)
In-Reply-To: <20220418082425.41566-1-renzhijie2@huawei.com>

Mon, Apr 18, 2022 at 04:24:25PM +0800, Ren Zhijie kirjoitti:
> Building without CONFIG_POWER_SUPPLY will fail:
> 
> drivers/usb/typec/rt1719.o: In function `rt1719_psy_set_property':
> rt1719.c:(.text+0x10a): undefined reference to `power_supply_get_drvdata'
> drivers/usb/typec/rt1719.o: In function `rt1719_psy_get_property':
> rt1719.c:(.text+0x2c8): undefined reference to `power_supply_get_drvdata'
> drivers/usb/typec/rt1719.o: In function `devm_rt1719_psy_register':
> rt1719.c:(.text+0x3e9): undefined reference to `devm_power_supply_register'
> drivers/usb/typec/rt1719.o: In function `rt1719_irq_handler':
> rt1719.c:(.text+0xf9f): undefined reference to `power_supply_changed'
> drivers/usb/typec/rt1719.o: In function `rt1719_update_pwr_opmode.part.9':
> rt1719.c:(.text+0x657): undefined reference to `power_supply_changed'
> drivers/usb/typec/rt1719.o: In function `rt1719_attach':
> rt1719.c:(.text+0x83e): undefined reference to `power_supply_changed'
> 
> Add POWER_SUPPLY dependency to Kconfig.
> 
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Fixes: 25d29b980912 ("usb: typec: rt1719: Add support for Richtek RT1719")
> Signed-off-by: Ren Zhijie <renzhijie2@huawei.com>

Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>

> ---
>  drivers/usb/typec/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/usb/typec/Kconfig b/drivers/usb/typec/Kconfig
> index 8f921213b17d..ba24847fb245 100644
> --- a/drivers/usb/typec/Kconfig
> +++ b/drivers/usb/typec/Kconfig
> @@ -56,6 +56,7 @@ config TYPEC_RT1719
>  	tristate "Richtek RT1719 Sink Only Type-C controller driver"
>  	depends on USB_ROLE_SWITCH || !USB_ROLE_SWITCH
>  	depends on I2C
> +	depends on POWER_SUPPLY
>  	select REGMAP_I2C
>  	help
>  	  Say Y or M here if your system has Richtek RT1719 sink only
> -- 
> 2.17.1

-- 
heikki

  reply	other threads:[~2022-04-20  9:06 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-18  8:24 [PATCH -next] usb: typec: rt1719: Fix build error without CONFIG_POWER_SUPPLY Ren Zhijie
2022-04-20  9:06 ` Heikki Krogerus [this message]
2022-04-21  1:00   ` cy_huang(黃啟原)
2022-04-21  1:47   ` ChiYuan Huang
2022-04-21  0:46 ` Ren Zhijie
2022-04-21 16:25   ` Greg KH

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Yl/NHAaXFh1UzFdI@kuha.fi.intel.com \
    --to=heikki.krogerus@linux.intel.com \
    --cc=cy_huang@richtek.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=renzhijie2@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox