drivers: eth: native: Align to support ptp_clock driver for PTP subsys

Add conditions to enable ptp_clock driver implementation
for native_posix when PTP subsystem is enabled.

Signed-off-by: Adam Wojasinski <awojasinski@baylibre.com>
This commit is contained in:
Adam Wojasinski 2024-06-03 13:29:57 +02:00 committed by Anas Nashif
parent 4a989b736e
commit 34c1fcc939

View file

@ -15,12 +15,13 @@ if ETH_NATIVE_POSIX
config ETH_NATIVE_POSIX_INTERFACE_COUNT
int "Number of network interfaces created"
default NET_GPTP_NUM_PORTS if NET_GPTP
default PTP_NUM_PORTS if PTP
default 1
range 1 32
help
By default only one network interface is created. It is possible
to create multiple interfaces in certain use cases. For example if
multiple ports are defined in gPTP, then multiple network interfaces
multiple ports are defined in gPTP or PTP, then multiple network interfaces
must be created here.
config ETH_NATIVE_POSIX_DRV_NAME
@ -40,9 +41,9 @@ config ETH_NATIVE_POSIX_DEV_NAME
config ETH_NATIVE_POSIX_PTP_CLOCK
bool "PTP clock driver support"
default y if NET_GPTP
default y if NET_GPTP || PTP
select PTP_CLOCK
depends on NET_GPTP
depends on NET_GPTP || PTP
help
Enable PTP clock support.