diff options
author | Vladimir Oltean <[email protected]> | 2024-12-05 16:55:19 +0200 |
---|---|---|
committer | Jakub Kicinski <[email protected]> | 2024-12-07 17:56:46 -0800 |
commit | 43a4166349a254446e7a3db65f721c6a30daccf3 (patch) | |
tree | 716da66e5c8df5acc5edd1db009036a01de68279 /drivers/fpga/fpga-mgr.c | |
parent | b454abfab52543c44b581afc807b9f97fc1e7a3a (diff) |
net: mscc: ocelot: perform error cleanup in ocelot_hwstamp_set()
An unsupported RX filter will leave the port with TX timestamping still
applied as per the new request, rather than the old setting. When
parsing the tx_type, don't apply it just yet, but delay that until after
we've parsed the rx_filter as well (and potentially returned -ERANGE for
that).
Similarly, copy_to_user() may fail, which is a rare occurrence, but
should still be treated by unwinding what was done.
Fixes: 96ca08c05838 ("net: mscc: ocelot: set up traps for PTP packets")
Signed-off-by: Vladimir Oltean <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>
Diffstat (limited to 'drivers/fpga/fpga-mgr.c')
0 files changed, 0 insertions, 0 deletions