sfc: Check firmware supports Ethernet PTP filter
authorAlex Austin <alex.austin@amd.com>
Thu, 24 Aug 2023 16:46:57 +0000 (17:46 +0100)
committerJakub Kicinski <kuba@kernel.org>
Sat, 26 Aug 2023 01:57:34 +0000 (18:57 -0700)
Not all firmware variants support RSS filters. Do not fail all PTP
functionality when raw ethernet PTP filters fail to insert.

Fixes: e4616f64726b ("sfc: support PTP over Ethernet")
Signed-off-by: Alex Austin <alex.austin@amd.com>
Acked-by: Edward Cree <ecree.xilinx@gmail.com>
Reviewed-by: Pieter Jansen van Vuuren <pieter.jansen-van-vuuren@amd.com>
Link: https://lore.kernel.org/r/20230824164657.42379-1-alex.austin@amd.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/sfc/ptp.c

index 0c40571..00cf6de 100644 (file)
@@ -1485,7 +1485,9 @@ static int efx_ptp_insert_multicast_filters(struct efx_nic *efx)
                        goto fail;
 
                rc = efx_ptp_insert_eth_multicast_filter(efx);
-               if (rc < 0)
+
+               /* Not all firmware variants support this filter */
+               if (rc < 0 && rc != -EPROTONOSUPPORT)
                        goto fail;
        }