Skip to content

Commit 7d57386

Browse files
hkallweitkuba-moo
authored andcommitted
net: phy: add Kconfig symbol PHY_PACKAGE
Only a handful of PHY drivers needs the PHY package functionality, therefore build the module only if needed. Signed-off-by: Heiner Kallweit <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent a1acde1 commit 7d57386

File tree

4 files changed

+9
-1
lines changed

4 files changed

+9
-1
lines changed

drivers/net/phy/Kconfig

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ if PHYLIB
2525
config SWPHY
2626
bool
2727

28+
config PHY_PACKAGE
29+
tristate
30+
2831
config LED_TRIGGER_PHY
2932
bool "Support LED triggers for tracking link state"
3033
depends on LEDS_TRIGGERS
@@ -157,6 +160,7 @@ config BCM54140_PHY
157160
tristate "Broadcom BCM54140 PHY"
158161
depends on HWMON || HWMON=n
159162
select BCM_NET_PHYLIB
163+
select PHY_PACKAGE
160164
help
161165
Support the Broadcom BCM54140 Quad SGMII/QSGMII PHY.
162166

@@ -292,6 +296,7 @@ source "drivers/net/phy/mediatek/Kconfig"
292296
config MICREL_PHY
293297
tristate "Micrel PHYs"
294298
depends on PTP_1588_CLOCK_OPTIONAL
299+
select PHY_PACKAGE
295300
help
296301
Supports the KSZ9021, VSC8201, KS8001 PHYs.
297302

@@ -323,6 +328,7 @@ config MICROSEMI_PHY
323328
depends on MACSEC || MACSEC=n
324329
depends on PTP_1588_CLOCK_OPTIONAL || !NETWORK_PHY_TIMESTAMPING
325330
select CRYPTO_LIB_AES if MACSEC
331+
select PHY_PACKAGE
326332
help
327333
Currently supports VSC8514, VSC8530, VSC8531, VSC8540 and VSC8541 PHYs
328334

drivers/net/phy/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ obj-$(CONFIG_MDIO_BUS) += mdio-bus.o
1919
obj-$(CONFIG_PHYLINK) += phylink.o
2020
obj-$(CONFIG_PHYLIB) += libphy.o
2121
obj-$(CONFIG_PHYLIB) += mdio_devres.o
22-
obj-$(CONFIG_PHYLIB) += phy_package.o
22+
obj-$(CONFIG_PHY_PACKAGE) += phy_package.o
2323

2424
obj-$(CONFIG_NETWORK_PHY_TIMESTAMPING) += mii_timestamper.o
2525

drivers/net/phy/mediatek/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ config MEDIATEK_GE_SOC_PHY
2727
depends on ARCH_AIROHA || (ARCH_MEDIATEK && NVMEM_MTK_EFUSE) || \
2828
COMPILE_TEST
2929
select MTK_NET_PHYLIB
30+
select PHY_PACKAGE
3031
help
3132
Supports MediaTek SoC built-in Gigabit Ethernet PHYs.
3233

drivers/net/phy/qcom/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ config QCA808X_PHY
2424
config QCA807X_PHY
2525
tristate "Qualcomm QCA807x PHYs"
2626
select QCOM_NET_PHYLIB
27+
select PHY_PACKAGE
2728
depends on OF_MDIO
2829
help
2930
Currently supports the Qualcomm QCA8072, QCA8075 and the PSGMII

0 commit comments

Comments
 (0)