1# SPDX-License-Identifier: GPL-2.0-only 2# 3# PTP clock support configuration 4# 5 6menu "PTP clock support" 7 8config PTP_1588_CLOCK 9 tristate "PTP clock support" 10 depends on NET && POSIX_TIMERS 11 default ETHERNET 12 select PPS 13 select NET_PTP_CLASSIFY 14 help 15 The IEEE 1588 standard defines a method to precisely 16 synchronize distributed clocks over Ethernet networks. The 17 standard defines a Precision Time Protocol (PTP), which can 18 be used to achieve synchronization within a few dozen 19 microseconds. In addition, with the help of special hardware 20 time stamping units, it can be possible to achieve 21 synchronization to within a few hundred nanoseconds. 22 23 This driver adds support for PTP clocks as character 24 devices. If you want to use a PTP clock, then you should 25 also enable at least one clock driver as well. 26 27 To compile this driver as a module, choose M here: the module 28 will be called ptp. 29 30config PTP_1588_CLOCK_OPTIONAL 31 tristate 32 default y if PTP_1588_CLOCK=n 33 default PTP_1588_CLOCK 34 help 35 Drivers that can optionally use the PTP_1588_CLOCK framework 36 should depend on this symbol to prevent them from being built 37 into vmlinux while the PTP support itself is in a loadable 38 module. 39 If PTP support is disabled, this dependency will still be 40 met, and drivers refer to dummy helpers. 41 42config PTP_1588_CLOCK_DTE 43 tristate "Broadcom DTE as PTP clock" 44 depends on PTP_1588_CLOCK 45 depends on NET && HAS_IOMEM 46 depends on ARCH_BCM_MOBILE || (ARCH_BCM_IPROC && !(ARCH_BCM_NSP || ARCH_BCM_5301X)) || COMPILE_TEST 47 default y if ARCH_BCM_MOBILE || ARCH_BCM_IPROC 48 help 49 This driver adds support for using the Digital timing engine 50 (DTE) in the Broadcom SoC's as a PTP clock. 51 52 The clock can be used in both wired and wireless networks 53 for PTP purposes. 54 55 To compile this driver as a module, choose M here: the module 56 will be called ptp_dte. 57 58config PTP_1588_CLOCK_QORIQ 59 tristate "Freescale QorIQ 1588 timer as PTP clock" 60 depends on GIANFAR || FSL_DPAA_ETH || FSL_DPAA2_ETH || FSL_ENETC || FSL_ENETC_VF || COMPILE_TEST 61 depends on PTP_1588_CLOCK 62 default y if GIANFAR || FSL_DPAA_ETH || FSL_DPAA2_ETH || FSL_ENETC || FSL_ENETC_VF 63 help 64 This driver adds support for using the Freescale QorIQ 1588 65 timer as a PTP clock. This clock is only useful if your PTP 66 programs are getting hardware time stamps on the PTP Ethernet 67 packets using the SO_TIMESTAMPING API. 68 69 To compile this driver as a module, choose M here: the module 70 will be called ptp_qoriq. 71 72comment "Enable PHYLIB and NETWORK_PHY_TIMESTAMPING to see the additional clocks." 73 depends on PHYLIB=n || NETWORK_PHY_TIMESTAMPING=n 74 75config DP83640_PHY 76 tristate "Driver for the National Semiconductor DP83640 PHYTER" 77 depends on NETWORK_PHY_TIMESTAMPING 78 depends on PHYLIB 79 depends on PTP_1588_CLOCK 80 select CRC32 81 select PHY_PACKAGE 82 help 83 Supports the DP83640 PHYTER with IEEE 1588 features. 84 85 This driver adds support for using the DP83640 as a PTP 86 clock. This clock is only useful if your PTP programs are 87 getting hardware time stamps on the PTP Ethernet packets 88 using the SO_TIMESTAMPING API. 89 90 In order for this to work, your MAC driver must also 91 implement the skb_tx_timestamp() function. 92 93config PTP_1588_CLOCK_INES 94 tristate "ZHAW InES PTP time stamping IP core" 95 depends on NETWORK_PHY_TIMESTAMPING 96 depends on HAS_IOMEM 97 depends on PHYLIB 98 depends on PTP_1588_CLOCK 99 help 100 This driver adds support for using the ZHAW InES 1588 IP 101 core. This clock is only useful if the MII bus of your MAC 102 is wired up to the core. 103 104config PTP_1588_CLOCK_PCH 105 tristate "Intel PCH EG20T as PTP clock" 106 depends on MIPS_GENERIC || X86_32 || COMPILE_TEST 107 depends on HAS_IOMEM && PCI 108 depends on NET 109 depends on PTP_1588_CLOCK 110 help 111 This driver adds support for using the PCH EG20T as a PTP 112 clock. The hardware supports time stamping of PTP packets 113 when using the end-to-end delay (E2E) mechanism. The peer 114 delay mechanism (P2P) is not supported. 115 116 This clock is only useful if your PTP programs are getting 117 hardware time stamps on the PTP Ethernet packets using the 118 SO_TIMESTAMPING API. 119 120 To compile this driver as a module, choose M here: the module 121 will be called ptp_pch. 122 123config PTP_1588_CLOCK_KVM 124 tristate "KVM virtual PTP clock" 125 depends on PTP_1588_CLOCK 126 depends on (KVM_GUEST && X86) || (HAVE_ARM_SMCCC_DISCOVERY && ARM_ARCH_TIMER) 127 default y 128 help 129 This driver adds support for using kvm infrastructure as a PTP 130 clock. This clock is only useful if you are using KVM guests. 131 132 To compile this driver as a module, choose M here: the module 133 will be called ptp_kvm. 134 135config PTP_1588_CLOCK_VMCLOCK 136 tristate "Virtual machine PTP clock" 137 depends on X86_TSC || ARM_ARCH_TIMER 138 depends on PTP_1588_CLOCK && ARCH_SUPPORTS_INT128 139 default PTP_1588_CLOCK_KVM 140 help 141 This driver adds support for using a virtual precision clock 142 advertised by the hypervisor. This clock is only useful in virtual 143 machines where such a device is present. 144 145 Unlike the KVM virtual PTP clock, the VMCLOCK device offers support 146 for reliable timekeeping even across live migration. So this driver 147 is enabled by default whenever the KVM PTP clock is. 148 149 To compile this driver as a module, choose M here: the module 150 will be called ptp_vmclock. 151 152config PTP_1588_CLOCK_IDT82P33 153 tristate "IDT 82P33xxx PTP clock" 154 depends on PTP_1588_CLOCK && I2C 155 default n 156 help 157 This driver adds support for using the IDT 82P33xxx as a PTP 158 clock. This clock is only useful if your time stamping MAC 159 is connected to the IDT chip. 160 161 To compile this driver as a module, choose M here: the module 162 will be called ptp_idt82p33. 163 164config PTP_1588_CLOCK_IDTCM 165 tristate "IDT CLOCKMATRIX as PTP clock" 166 depends on PTP_1588_CLOCK && I2C 167 default n 168 help 169 This driver adds support for using IDT CLOCKMATRIX(TM) as a PTP 170 clock. This clock is only useful if your time stamping MAC 171 is connected to the IDT chip. 172 173 To compile this driver as a module, choose M here: the module 174 will be called ptp_clockmatrix. 175 176config PTP_1588_CLOCK_FC3W 177 tristate "RENESAS FemtoClock3 Wireless as PTP clock" 178 depends on PTP_1588_CLOCK && I2C 179 default n 180 help 181 This driver adds support for using Renesas FemtoClock3 Wireless 182 as a PTP clock. This clock is only useful if your time stamping 183 MAC is connected to the RENESAS chip. 184 185 To compile this driver as a module, choose M here: the module 186 will be called ptp_fc3. 187 188config PTP_1588_CLOCK_MOCK 189 tristate "Mock-up PTP clock" 190 depends on PTP_1588_CLOCK 191 help 192 This driver offers a set of PTP clock manipulation operations over 193 the system monotonic time. It can be used by virtual network device 194 drivers to emulate PTP capabilities. 195 196 To compile this driver as a module, choose M here: the module 197 will be called ptp_mock. 198 199config PTP_1588_CLOCK_VMW 200 tristate "VMware virtual PTP clock" 201 depends on ACPI && HYPERVISOR_GUEST && X86 202 depends on PTP_1588_CLOCK 203 help 204 This driver adds support for using VMware virtual precision 205 clock device as a PTP clock. This is only useful in virtual 206 machines running on VMware virtual infrastructure. 207 208 To compile this driver as a module, choose M here: the module 209 will be called ptp_vmw. 210 211config PTP_1588_CLOCK_OCP 212 tristate "OpenCompute TimeCard as PTP clock" 213 depends on PTP_1588_CLOCK 214 depends on HAS_IOMEM && PCI 215 depends on I2C && MTD 216 depends on SERIAL_8250 217 depends on !S390 218 depends on COMMON_CLK 219 select NET_DEVLINK 220 select CRC16 221 select DPLL 222 help 223 This driver adds support for an OpenCompute time card. 224 225 The OpenCompute time card is an atomic clock along with 226 a GPS receiver that provides a Grandmaster clock source 227 for a PTP enabled network. 228 229 More information is available at http://www.timingcard.com/ 230 231config PTP_DFL_TOD 232 tristate "FPGA DFL ToD Driver" 233 depends on FPGA_DFL 234 depends on PTP_1588_CLOCK 235 help 236 The DFL (Device Feature List) device driver for the Intel ToD 237 (Time-of-Day) device in FPGA card. The ToD IP within the FPGA 238 is exposed as PTP Hardware Clock (PHC) device to the Linux PTP 239 stack to synchronize the system clock to its ToD information 240 using phc2sys utility of the Linux PTP stack. 241 242 To compile this driver as a module, choose M here: the module 243 will be called ptp_dfl_tod. 244 245config PTP_S390 246 tristate "S390 PTP driver" 247 depends on PTP_1588_CLOCK 248 depends on S390 249 help 250 This driver adds support for S390 time steering via the PtP 251 interface. This works by adding a in-kernel clock delta value, 252 which is always added to time values used in the kernel. The PtP 253 driver provides the raw clock value without the delta to 254 userspace. That way userspace programs like chrony could steer 255 the kernel clock. 256 257config PTP_NETC_V4_TIMER 258 tristate "NXP NETC V4 Timer PTP Driver" 259 depends on PTP_1588_CLOCK 260 depends on PCI_MSI 261 help 262 This driver adds support for using the NXP NETC V4 Timer as a PTP 263 clock, the clock is used by ENETC V4 or NETC V4 Switch for PTP time 264 synchronization. It also supports periodic output signal (e.g. PPS) 265 and external trigger timestamping. 266 267endmenu 268