Rayagond Kokatanur <rayagond@xxxxxxxxxxxxxxx> wrote: > On Wed, Mar 19, 2014 at 11:02 AM, Byungho An <bh74.an@xxxxxxxxxxx> wrote: [snip] > > > > /* save the skb address */ > > tqueue->tx_skbuff[entry] = skb; > > > > if (!is_jumbo) { > > - tx_desc->tdes01 = dma_map_single(priv->device, skb->data, > > - no_pagedlen, DMA_TO_DEVICE); > > - if (dma_mapping_error(priv->device, tx_desc->tdes01)) > > - pr_err("%s: TX dma mapping failed!!\n", __func__); > > - > > - priv->hw->desc->prepare_tx_desc(tx_desc, 1, no_pagedlen, > > - no_pagedlen); > > + if (likely(skb_is_gso(skb))) { > > + /* TSO support */ > > + mss = skb_shinfo(skb)->gso_size; > > + > > + priv->hw->desc->tx_ctxt_desc_set_mss(ctxt_desc, mss); > > No need to issue context descriptor for every TSO packets. Program context descriptor only if MSS value is value is changed compared > to previous TSO packet MSS value. By this way we can reduce the one extra descriptor fetch by device and improve the performance. OK. This will be applied in the next post. [snip] > > @@ -1893,7 +1943,9 @@ struct sxgbe_priv_data *sxgbe_dvr_probe(struct > > device *device, > > > > ndev->netdev_ops = &sxgbe_netdev_ops; > > > > - ndev->hw_features = NETIF_F_SG | NETIF_F_RXCSUM; > > + ndev->hw_features = NETIF_F_SG | NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM | > > + NETIF_F_RXCSUM | NETIF_F_TSO | NETIF_F_TSO6 | > > + NETIF_F_GRO; > > Enable TSO only if HW supports, hence we have to check for HW feature/capability registers here also. OK. Thanks > > > ndev->features |= ndev->hw_features | NETIF_F_HIGHDMA; > > ndev->watchdog_timeo = msecs_to_jiffies(TX_TIMEO); > > > > @@ -1905,6 +1957,13 @@ struct sxgbe_priv_data *sxgbe_dvr_probe(struct device *device, > > if (flow_ctrl) > > priv->flow_ctrl = SXGBE_FLOW_AUTO; /* RX/TX pause on */ > > > > + /* Enable TCP segmentation offload for all DMA channels */ > > + if (priv->hw_cap.tcpseg_offload) { > > + SXGBE_FOR_EACH_QUEUE(SXGBE_TX_QUEUES, queue_num) { > > + priv->hw->dma->enable_tso(priv->ioaddr, queue_num); > > + } > > + } > > + > > /* Rx Watchdog is available, enable depend on platform data */ > > if (!priv->plat->riwt_off) { > > priv->use_riwt = 1; > > -- > > 1.7.10.4 > > > > > > -- > > To unsubscribe from this list: send the line "unsubscribe netdev" in > > the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info > > at http://vger.kernel.org/majordomo-info.html > -- > To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@xxxxxxxxxxxxxxx More > majordomo info at http://vger.kernel.org/majordomo-info.html -- To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html