bna: Add software timestamping support
authorRasesh Mody <rmody@brocade.com>
Wed, 18 Dec 2013 01:07:31 +0000 (17:07 -0800)
committerDavid S. Miller <davem@davemloft.net>
Wed, 18 Dec 2013 05:30:33 +0000 (00:30 -0500)
- Invoke skb_tx_timestamp() API just before invoking txq_doorbell()
 - Add ethtool (-T) support

Signed-off-by: Rasesh Mody <rmody@brocade.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/brocade/bna/bnad.c
drivers/net/ethernet/brocade/bna/bnad_ethtool.c

index f1a516bc31c1a27dd8d1dbaad21f69cd65c0eaef..1790959c2b733d0919ddac7d8db7f0e7c2659d40 100644 (file)
@@ -2911,6 +2911,8 @@ bnad_start_xmit(struct sk_buff *skb, struct net_device *netdev)
        if (unlikely(!test_bit(BNAD_TXQ_TX_STARTED, &tcb->flags)))
                return NETDEV_TX_OK;
 
+       skb_tx_timestamp(skb);
+
        bna_txq_prod_indx_doorbell(tcb);
        smp_mb();
 
index 455b5a2e59d496b64d8c90f327dc4539e7ade67c..f9e150825bb58bf0ef9e3568a1084cb8ebc61d37 100644 (file)
@@ -1131,6 +1131,7 @@ static const struct ethtool_ops bnad_ethtool_ops = {
        .get_eeprom = bnad_get_eeprom,
        .set_eeprom = bnad_set_eeprom,
        .flash_device = bnad_flash_device,
+       .get_ts_info = ethtool_op_get_ts_info,
 };
 
 void