Hello,
I am trying to use ptp4l with software timestamping on my raspberry pi
with a RT5370 wireless adapter. The driver is rt2800usb found in
drivers/net/wireless/ralink/rt2x00 of the raspberry kernel and it
doesn't support software timestamp transmitting. 
I have added skb_tx_timestamp(skb) into the transmit path and a
ethtool_ops struct. Ethtool still reports no software transmitting.
Could I ask for help with this driver or general instructions?

Thanks,
Simon Wernisch
@@ -23,6 +23,7 @@

 #include <linux/kernel.h>
 #include <linux/module.h>
+#include <linux/ethtool.h>

 #include "rt2x00.h"
 #include "rt2x00lib.h"
@@ -148,6 +149,8 @@ void rt2x00mac_tx(struct ieee80211_hw *hw,
                if (rt2x00mac_tx_rts_cts(rt2x00dev, queue, skb))
                        goto exit_fail;
        }
+  /* Transmit timestamping */
+  skb_tx_timestamp(skb);

        if (unlikely(rt2x00queue_write_tx_frame(queue, skb, control->sta, 
false)))
                goto exit_fail;
@@ -839,3 +842,9 @@ bool rt2x00mac_tx_frames_pending(struct ieee80211_hw *hw)
        return false;
 }
 EXPORT_SYMBOL_GPL(rt2x00mac_tx_frames_pending);
+
+static const struct ethtool_ops rt2x00_ethtool_ops = {
+  .get_ts_info = ethtool_op_get_ts_info,
+  .get_link = ethtool_op_get_link
+};
+
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Linuxptp-users mailing list
Linuxptp-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxptp-users

Reply via email to