From 6c8bf0424a794c4fb622c22a6fd61655a2712b21 Mon Sep 17 00:00:00 2001 From: Srinivas Kandagatla Date: Sun, 17 Jul 2011 20:54:09 +0000 Subject: [PATCH] --- yaml --- r: 256499 b: refs/heads/master c: 61b8013a114cb041db2c56f747953cac69637f26 h: refs/heads/master i: 256497: 4281164275532c41a094075380d8439f261fe29d 256495: ab526d2a99aad8b63b24aa4811e6a83936a78937 v: v3 --- [refs] | 2 +- trunk/drivers/net/stmmac/stmmac_main.c | 8 +++++--- trunk/include/linux/stmmac.h | 1 + 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/[refs] b/[refs] index 4eb8139102d6..2efc42e72b9a 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: eb0dc4bb2e22c04964d6e9545e86f629f117108b +refs/heads/master: 61b8013a114cb041db2c56f747953cac69637f26 diff --git a/trunk/drivers/net/stmmac/stmmac_main.c b/trunk/drivers/net/stmmac/stmmac_main.c index c8c9e5bc6608..d37ebc80623a 100644 --- a/trunk/drivers/net/stmmac/stmmac_main.c +++ b/trunk/drivers/net/stmmac/stmmac_main.c @@ -557,9 +557,11 @@ static void free_dma_desc_resources(struct stmmac_priv *priv) */ static void stmmac_dma_operation_mode(struct stmmac_priv *priv) { - if (likely((priv->plat->tx_coe) && (!priv->no_csum_insertion))) { - /* In case of GMAC, SF mode has to be enabled - * to perform the TX COE. This depends on: + if (likely(priv->plat->force_sf_dma_mode || + ((priv->plat->tx_coe) && (!priv->no_csum_insertion)))) { + /* + * In case of GMAC, SF mode can be enabled + * to perform the TX COE in HW. This depends on: * 1) TX COE if actually supported * 2) There is no bugged Jumbo frame support * that needs to not insert csum in the TDES. diff --git a/trunk/include/linux/stmmac.h b/trunk/include/linux/stmmac.h index 9529e49b0385..05d775690b72 100644 --- a/trunk/include/linux/stmmac.h +++ b/trunk/include/linux/stmmac.h @@ -40,6 +40,7 @@ struct plat_stmmacenet_data { int tx_coe; int bugged_jumbo; int pmt; + int force_sf_dma_mode; void (*fix_mac_speed)(void *priv, unsigned int speed); void (*bus_setup)(void __iomem *ioaddr); int (*init)(struct platform_device *pdev);