linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] net: dsa: microchip: ptp: add one more PTP dependency
@ 2023-01-27 22:13 Arnd Bergmann
  2023-01-27 23:58 ` Richard Cochran
  0 siblings, 1 reply; 3+ messages in thread
From: Arnd Bergmann @ 2023-01-27 22:13 UTC (permalink / raw)
  To: Woojung Huh, UNGLinuxDriver, Andrew Lunn
  Cc: Arnd Bergmann, Florian Fainelli, Vladimir Oltean,
	David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Richard Cochran, Arun Ramadoss, Jacob Keller, netdev,
	linux-kernel

From: Arnd Bergmann <arnd@arndb.de>

When only NET_DSA_MICROCHIP_KSZ8863_SMI is built-in but
PTP is a loadable module, the ksz_ptp support still causes
a link failure:

ld.lld-16: error: undefined symbol: ptp_clock_index
>>> referenced by ksz_ptp.c
>>>               drivers/net/dsa/microchip/ksz_ptp.o:(ksz_get_ts_info) in archive vmlinux.a

Add the same dependency here that exists with the KSZ9477_I2C
and KSZ_SPI drivers.

Fixes: eac1ea20261e ("net: dsa: microchip: ptp: add the posix clock support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/net/dsa/microchip/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/dsa/microchip/Kconfig b/drivers/net/dsa/microchip/Kconfig
index 0546c573668a..11920939b6d8 100644
--- a/drivers/net/dsa/microchip/Kconfig
+++ b/drivers/net/dsa/microchip/Kconfig
@@ -36,6 +36,7 @@ config NET_DSA_MICROCHIP_KSZ_PTP
 config NET_DSA_MICROCHIP_KSZ8863_SMI
 	tristate "KSZ series SMI connected switch driver"
 	depends on NET_DSA_MICROCHIP_KSZ_COMMON
+	depends on PTP_1588_CLOCK_OPTIONAL
 	select MDIO_BITBANG
 	help
 	  Select to enable support for registering switches configured through
-- 
2.39.0


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

* Re: [PATCH] net: dsa: microchip: ptp: add one more PTP dependency
  2023-01-27 22:13 [PATCH] net: dsa: microchip: ptp: add one more PTP dependency Arnd Bergmann
@ 2023-01-27 23:58 ` Richard Cochran
  2023-01-28 21:44   ` Arnd Bergmann
  0 siblings, 1 reply; 3+ messages in thread
From: Richard Cochran @ 2023-01-27 23:58 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Woojung Huh, UNGLinuxDriver, Andrew Lunn, Arnd Bergmann,
	Florian Fainelli, Vladimir Oltean, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Arun Ramadoss, Jacob Keller, netdev,
	linux-kernel

On Fri, Jan 27, 2023 at 11:13:03PM +0100, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
> 
> When only NET_DSA_MICROCHIP_KSZ8863_SMI is built-in but
> PTP is a loadable module, the ksz_ptp support still causes
> a link failure:
> 
> ld.lld-16: error: undefined symbol: ptp_clock_index
> >>> referenced by ksz_ptp.c
> >>>               drivers/net/dsa/microchip/ksz_ptp.o:(ksz_get_ts_info) in archive vmlinux.a
> 
> Add the same dependency here that exists with the KSZ9477_I2C
> and KSZ_SPI drivers.
> 
> Fixes: eac1ea20261e ("net: dsa: microchip: ptp: add the posix clock support")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Acked-by: Richard Cochran <richardcochran@gmail.com>

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

* Re: [PATCH] net: dsa: microchip: ptp: add one more PTP dependency
  2023-01-27 23:58 ` Richard Cochran
@ 2023-01-28 21:44   ` Arnd Bergmann
  0 siblings, 0 replies; 3+ messages in thread
From: Arnd Bergmann @ 2023-01-28 21:44 UTC (permalink / raw)
  To: Richard Cochran, Arnd Bergmann
  Cc: Woojung Huh, UNGLinuxDriver, Andrew Lunn, Florian Fainelli,
	Vladimir Oltean, David S . Miller, Eric Dumazet, Jakub Kicinski,
	Paolo Abeni, Arun Ramadoss, Jacob Keller, Netdev, linux-kernel

On Sat, Jan 28, 2023, at 00:58, Richard Cochran wrote:
> On Fri, Jan 27, 2023 at 11:13:03PM +0100, Arnd Bergmann wrote:
>> From: Arnd Bergmann <arnd@arndb.de>
>> 
>> When only NET_DSA_MICROCHIP_KSZ8863_SMI is built-in but
>> PTP is a loadable module, the ksz_ptp support still causes
>> a link failure:
>> 
>> ld.lld-16: error: undefined symbol: ptp_clock_index
>> >>> referenced by ksz_ptp.c
>> >>>               drivers/net/dsa/microchip/ksz_ptp.o:(ksz_get_ts_info) in archive vmlinux.a
>> 
>> Add the same dependency here that exists with the KSZ9477_I2C
>> and KSZ_SPI drivers.
>> 
>> Fixes: eac1ea20261e ("net: dsa: microchip: ptp: add the posix clock support")
>> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
>
> Acked-by: Richard Cochran <richardcochran@gmail.com>

The randconfig builder just found another regression in the same
driver, I'll have to send a new version, so please disregard this one
for now.

      Arnd

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

end of thread, other threads:[~2023-01-28 21:44 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-27 22:13 [PATCH] net: dsa: microchip: ptp: add one more PTP dependency Arnd Bergmann
2023-01-27 23:58 ` Richard Cochran
2023-01-28 21:44   ` Arnd Bergmann

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