]> git.baikalelectronics.ru Git - kernel.git/commit
ionic: catch no ptp support earlier
authorShannon Nelson <snelson@pensando.io>
Fri, 23 Jul 2021 18:02:46 +0000 (11:02 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 23 Jul 2021 20:57:41 +0000 (21:57 +0100)
commit2f2fd3a1e216f1e7943c3e0cd52b0fdb0cf77c1c
tree60fdafba1e1a3787ab8517bb81d218d7316e647f
parenta2f6239fab071c2f80254c440a88f90fe61e1d2e
ionic: catch no ptp support earlier

If PTP configuration is attempted on ports that don't support
it, such as VF ports, the driver will return an error status
-95, or EOPNOSUPP and print an error message
    enp98s0: hwstamp set failed: -95

Because some daemons can retry every few seconds, this can end
up filling the dmesg log and pushing out other more useful
messages.

We can catch this issue earlier in our handling and return
the error without a log message.

Fixes: b4c044b51682 ("ionic: add ts_config replay")
Signed-off-by: Shannon Nelson <snelson@pensando.io>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/pensando/ionic/ionic_lif.h
drivers/net/ethernet/pensando/ionic/ionic_phc.c