Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1619765 > unrolled thread

[PATCH] phy: qcom-qusb2: add NVMEM dependency

Started byTobias Regnery <tobias.regnery@gmail.com>
First post2017-04-10 12:00 +0200
Last post2017-04-10 12:40 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] phy: qcom-qusb2: add NVMEM dependency Tobias Regnery <tobias.regnery@gmail.com> - 2017-04-10 12:00 +0200
    Re: [PATCH] phy: qcom-qusb2: add NVMEM dependency Kishon Vijay Abraham I <kishon@ti.com> - 2017-04-10 12:40 +0200

#1619765 — [PATCH] phy: qcom-qusb2: add NVMEM dependency

FromTobias Regnery <tobias.regnery@gmail.com>
Date2017-04-10 12:00 +0200
Subject[PATCH] phy: qcom-qusb2: add NVMEM dependency
Message-ID<tuEh4-7s0-9@gated-at.bofh.it>
With CONFIG_NVMEM=m and CONFIG_PHY_QCOM_QUSB2=y we get a link error from
calls to devm_nvmem_cell_get and nvmem_cell_read:

drivers/built-in.o: In function `qusb2_phy_probe':
binder.c:(.text+0x4750): undefined reference to `devm_nvmem_cell_get'
drivers/built-in.o: In function `qusb2_phy_init':
binder.c:(.text+0x489c): undefined reference to `nvmem_cell_read'

Fix this by adding a Kconfig dependency to ensure we can only have this
driver built in when the nvmem functions are also built in or we see the
empty stub functions. We can still build this driver as a module when the
nvmem core is build as module, too.

Fixes: deffad633413 ("phy: qcom-qusb2: New driver for QUSB2 PHY on Qcom chips")
Signed-off-by: Tobias Regnery <tobias.regnery@gmail.com>
---
 drivers/phy/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
index c120071fd2c8..30a2a612ff20 100644
--- a/drivers/phy/Kconfig
+++ b/drivers/phy/Kconfig
@@ -450,6 +450,7 @@ config PHY_QCOM_QMP
 config PHY_QCOM_QUSB2
 	tristate "Qualcomm QUSB2 PHY Driver"
 	depends on OF && (ARCH_QCOM || COMPILE_TEST)
+	depends on NVMEM || !NVMEM
 	select GENERIC_PHY
 	help
 	  Enable this to support the HighSpeed QUSB2 PHY transceiver for USB
-- 
2.11.0

[toc] | [next] | [standalone]


#1619792

FromKishon Vijay Abraham I <kishon@ti.com>
Date2017-04-10 12:40 +0200
Message-ID<tuETL-7TH-3@gated-at.bofh.it>
In reply to#1619765

On Monday 10 April 2017 03:22 PM, Tobias Regnery wrote:
> With CONFIG_NVMEM=m and CONFIG_PHY_QCOM_QUSB2=y we get a link error from
> calls to devm_nvmem_cell_get and nvmem_cell_read:
> 
> drivers/built-in.o: In function `qusb2_phy_probe':
> binder.c:(.text+0x4750): undefined reference to `devm_nvmem_cell_get'
> drivers/built-in.o: In function `qusb2_phy_init':
> binder.c:(.text+0x489c): undefined reference to `nvmem_cell_read'
> 
> Fix this by adding a Kconfig dependency to ensure we can only have this
> driver built in when the nvmem functions are also built in or we see the
> empty stub functions. We can still build this driver as a module when the
> nvmem core is build as module, too.
> 
> Fixes: deffad633413 ("phy: qcom-qusb2: New driver for QUSB2 PHY on Qcom chips")
> Signed-off-by: Tobias Regnery <tobias.regnery@gmail.com>

merged, thanks!

-Kishon
> ---
>  drivers/phy/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
> index c120071fd2c8..30a2a612ff20 100644
> --- a/drivers/phy/Kconfig
> +++ b/drivers/phy/Kconfig
> @@ -450,6 +450,7 @@ config PHY_QCOM_QMP
>  config PHY_QCOM_QUSB2
>  	tristate "Qualcomm QUSB2 PHY Driver"
>  	depends on OF && (ARCH_QCOM || COMPILE_TEST)
> +	depends on NVMEM || !NVMEM
>  	select GENERIC_PHY
>  	help
>  	  Enable this to support the HighSpeed QUSB2 PHY transceiver for USB
> 

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web