Commit cb4b1207 authored by Raju Lakkaraju's avatar Raju Lakkaraju Committed by David S. Miller
Browse files

eth: lan743x: reject extts for non-pci11x1x devices



Remove PTP_PF_EXTTS support for non-PCI11x1x devices since they do not support
the PTP-IO Input event triggered timestamping mechanisms added

Fixes: 60942c39 ("net: lan743x: Add support for PTP-IO Event Input External Timestamp (extts)")
Signed-off-by: default avatarRaju Lakkaraju <Raju.Lakkaraju@microchip.com>
Reviewed-by: default avatarHoratiu Vultur <horatiu.vultur@microchip.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 9e6fd874
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -1049,6 +1049,10 @@ static int lan743x_ptpci_verify_pin_config(struct ptp_clock_info *ptp,
					   enum ptp_pin_function func,
					   unsigned int chan)
{
	struct lan743x_ptp *lan_ptp =
		container_of(ptp, struct lan743x_ptp, ptp_clock_info);
	struct lan743x_adapter *adapter =
		container_of(lan_ptp, struct lan743x_adapter, ptp);
	int result = 0;

	/* Confirm the requested function is supported. Parameter
@@ -1057,7 +1061,10 @@ static int lan743x_ptpci_verify_pin_config(struct ptp_clock_info *ptp,
	switch (func) {
	case PTP_PF_NONE:
	case PTP_PF_PEROUT:
		break;
	case PTP_PF_EXTTS:
		if (!adapter->is_pci11x1x)
			result = -1;
		break;
	case PTP_PF_PHYSYNC:
	default: