Info about the GSO support

2007-01-26 Thread Giuseppe Cavallaro
I’m working on an embedded network interface (core by Synopsys) and I’ve already written my first Linux network device driver. My hardware has an internal DMA so I’ve used the scatter gather implementation. Moreover, this HW doesn’t support the TSO feature. I’m wondering if I can use the new GSO

Re: [RFC][PATCH] net: stmmac: use msleep instead of udelay for gpio reset

2015-04-20 Thread Giuseppe CAVALLARO
On 4/19/2015 6:11 AM, Michael Trimarchi wrote: Hi On Apr 19, 2015 1:37 AM, Fabio Estevam feste...@gmail.com mailto:feste...@gmail.com wrote: On Sat, Apr 18, 2015 at 12:02 PM, Michael Trimarchi mich...@amarulasolutions.com mailto:mich...@amarulasolutions.com wrote:

Re: [PATCH net 0/5] stmmac: Correct flow control configuration

2015-04-16 Thread Giuseppe CAVALLARO
Hi Vince On 4/15/2015 6:17 PM, Vince Bridgers wrote: This series of patches corrects flow control configuration for the Synopsys GMAC driver. Thx for these patches For the series Acked-by: Giuseppe Cavallaro peppe.cavall...@st.com peppe Flow control is configured based on a configurable

Re: linux-4.2-rc2/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c:1993: possible bad error checking ?

2015-07-14 Thread Giuseppe CAVALLARO
Hello David thx to have looked at this. I'll check the code and eventually fix it, unless you already have a patch to propose. Kind Regards Peppe On 7/13/2015 11:48 AM, David Binderman wrote: Hello there, [linux-4.2-rc2/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c:1993]: (style)

Re: [PATCH (net.git)] stmmac: fix resource management when resume

2015-12-03 Thread Giuseppe CAVALLARO
Hi David This is the v2, sorry I missed it in the subject. Re-based on top of net.git. peppe On 12/4/2015 7:21 AM, Giuseppe Cavallaro wrote: There is a memleak when suspend/resume this driver version. Currently the stmmac, during resume step, reallocates all the resources

[PATCH (net.git)] stmmac: fix resource management when resume

2015-12-03 Thread Giuseppe Cavallaro
and reallocate all from scratch because the memory data will be always preserved. As final solution, the patch just reinit the descriptors and the rx/tx pointers only when resume. Tested done on STi boxes. Reported-by: ZhengShunQian <zhen...@rock-chips.com> Signed-off-by: Giuseppe Cavallaro <pep

[PATCH (net-next.git) 06/18] stmmac: add last_segment field to dma data

2015-12-09 Thread Giuseppe Cavallaro
com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/chain_mode.c |3 ++- drivers/net/ethernet/stmicro/stmmac/stmmac.h |1 + drivers/net/ethernet/stmicro/stmmac/stmmac_main.c |5 - 3 files changed, 7 insertions(+),

[PATCH (net-next.git) 00/18] stmmac: enhance driver performances and update the version.

2015-12-09 Thread Giuseppe Cavallaro
): stmmac: merge get_rx_owner into rx_status routine. stmmac: optimize tx clean function stmmac: fix phy init when attached to a phy Giuseppe Cavallaro (15): stmmac: share reset function between dwmac100 and dwmac1000 stmmac: rework DMA bus setting and introduce new platform AXI structure

[PATCH (net-next.git) 03/18] stmmac: change descriptor layout

2015-12-09 Thread Giuseppe Cavallaro
This patch completely changes the descriptor layout to improve the whole performances due to the single read usage of the descriptors in critical paths. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/descs.h

[PATCH (net-next.git) 04/18] stmmac: remove modulo in stmmac_xmit()

2015-12-09 Thread Giuseppe Cavallaro
urt trying to cope with huge numbers This patch replaces the modulo with a simple if clamp. Signed-off-by: David McKay <david.mc...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/chain_mode.c | 15 ++ drivers/net/e

[PATCH (net-next.git) 02/18] stmmac: rework DMA bus setting and introduce new platform AXI structure

2015-12-09 Thread Giuseppe Cavallaro
removed. It makes sense to provide the AAL parameter from DT to Address-Aligned Beats inside the Register0 and review the PBL settings when initialize the engine. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- Documentation/devicetree/bindings/net/stmmac.txt

[PATCH (net-next.git) 05/18] stmmac: add length field to dma data

2015-12-09 Thread Giuseppe Cavallaro
. Signed-off-by: Fabrice Gasnier <fabrice.gasn...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/chain_mode.c |3 +++ drivers/net/ethernet/stmicro/stmmac/ring_mode.c |5 + drivers/net/ethernet/stmicro/stmmac/stmmac.h

[PATCH (net-next.git) 15/18] stmmac: fix phy init when attached to a phy

2015-12-09 Thread Giuseppe Cavallaro
er <fabrice.gasn...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c |5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ether

[PATCH (net-next.git) 09/18] stmmac: optimize tx desc management

2015-12-09 Thread Giuseppe Cavallaro
This patch is to optimize the way to manage the TDES inside the xmit function. When prepare the frame, some settings (e.g. OWN bit) can be merged. This has been reworked to improve the tx performances. Signed-off-by: Fabrice Gasnier <fabrice.gasn...@st.com> Signed-off-by: Giuseppe Cav

[PATCH (net-next.git) 12/18] stmmac: first frame prep at the end of xmit routine

2015-12-09 Thread Giuseppe Cavallaro
e. Signed-off-by: Fabrice Gasnier <fabrice.gasn...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/common.h |7 +- drivers/net/ethernet/stmicro/stmmac/enh_desc.c | 25 +++-- drivers/net/ethernet/stmicro/stmmac

[PATCH (net-next.git) 17/18] stmmac: tune rx copy via threshold.

2015-12-09 Thread Giuseppe Cavallaro
There is a threshold now used to also limit the skb allocation when use zero-copy. This is to avoid that there are incoherence in the ring due to a failure on skb allocation under very aggressive testing and under low memory conditions. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.

[PATCH (net-next.git) 10/18] stmmac: optimize tx clean function

2015-12-09 Thread Giuseppe Cavallaro
inside TX clean loop for enhanced descriptors but not for normal ones because the des1 must be read in any case. Signed-off-by: Fabrice Gasnier <fabrice.gasn...@st.com> Acked-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/common.h |8

[PATCH (net-next.git) 14/18] stmmac: do not poll phy handler when attach a switch

2015-12-09 Thread Giuseppe Cavallaro
ote that the stmmac_adjust_link will be called just one time and this guarantees that the ST glue logic will be setup according to the mode and speed fixed. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c |5 + 1 files changed, 5 i

[PATCH (net-next.git) 18/18] stmmac: update version to Oct_2015

2015-12-09 Thread Giuseppe Cavallaro
This patch just updates the driver to the version fully tested on STi platforms. This version is Oct_2015. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac.h |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/d

[PATCH (net-next.git) 11/18] stmmac: set dirty index out of the loop

2015-12-09 Thread Giuseppe Cavallaro
The dirty index can be updated out of the loop where all the tx resources are claimed. This will help on performances too. Also a useless debug printk has been removed from the main loop. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/

[PATCH (net-next.git) 01/18] stmmac: share reset function between dwmac100 and dwmac1000

2015-12-09 Thread Giuseppe Cavallaro
This patch is to share the same reset procedure between dwmac100 and dwmac1000 chips. This will also help on enhancing the driver and support new chips. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/common.h |3 +- drive

[PATCH (net-next.git) 08/18] stmmac: merge get_rx_owner into rx_status routine.

2015-12-09 Thread Giuseppe Cavallaro
rice.gasn...@st.com> Acked-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/common.h | 10 +- drivers/net/ethernet/stmicro/stmmac/enh_desc.c|9 +++-- drivers/net/ethernet/stmicro/stmmac/norm_desc.c |9 +++-- drivers/ne

[PATCH (net-next.git) 13/18] stmmac: perf, remove modulo in stmmac_rx()

2015-12-09 Thread Giuseppe Cavallaro
Signed-off-by: Fabrice Gasnier <fabrice.gasn...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 28 ++--- 1 files changed, 24 insertions(+), 4 deletions(-) diff --git a/drivers/net/e

[PATCH (net-next.git) 16/18] stmmac: do not perform zero-copy for rx frames

2015-12-09 Thread Giuseppe Cavallaro
This patch is to allow this driver to copy tiny frames during the reception process. This is giving more stability while stressing the driver on STi embedded systems. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c

[PATCH (net-next.git) 07/18] stmmac: add is_jumbo field to dma data

2015-12-09 Thread Giuseppe Cavallaro
<fabrice.gasn...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/chain_mode.c |3 ++- drivers/net/ethernet/stmicro/stmmac/ring_mode.c | 11 ++- drivers/net/ethernet/stmicro/stmmac/stmmac.h |1 + drivers/net/ethe

Re: [PATCH (net-next.git) 13/18] stmmac: perf, remove modulo in stmmac_rx()

2015-12-09 Thread Giuseppe CAVALLARO
On 12/10/2015 6:11 AM, Giuseppe CAVALLARO wrote: On 12/9/2015 6:21 PM, David Laight wrote: From: Giuseppe Cavallaro Sent: 09 December 2015 08:38 The indexes into the ring buffer are always incremented, and the entry is accessed via doing a modulo to find the "real" ind

Re: [PATCH (net-next.git) 13/18] stmmac: perf, remove modulo in stmmac_rx()

2015-12-09 Thread Giuseppe CAVALLARO
On 12/9/2015 6:21 PM, David Laight wrote: From: Giuseppe Cavallaro Sent: 09 December 2015 08:38 The indexes into the ring buffer are always incremented, and the entry is accessed via doing a modulo to find the "real" index. Modulo is an expensive operation. This patch replaces

Re: [PATCH v5 1/4] stmmac: create of compatible mdio bus for stmacc driver

2015-12-11 Thread Giuseppe CAVALLARO
Hello Phil On 12/11/2015 2:44 AM, Phil Reid wrote: G'day Giuseppe, On 11/12/2015 1:16 AM, Giuseppe CAVALLARO wrote: Hi also pls fix this typo stmmac: create of compatible mdio bus for stmacc driver

Re: [PATCH (net-next.git) 16/18] stmmac: do not perform zero-copy for rx frames

2015-12-16 Thread Giuseppe CAVALLARO
On 12/12/2015 2:09 AM, David Miller wrote: From: Giuseppe Cavallaro <peppe.cavall...@st.com> Date: Wed, 9 Dec 2015 09:37:52 +0100 @@ -98,6 +98,10 @@ static int buf_sz = DEFAULT_BUFSIZE; module_param(buf_sz, int, S_IRUGO | S_IWUSR); MODULE_PARM_DESC(buf_sz, "DMA buffer size"

Re: [PATCH v5 1/4] stmmac: create of compatible mdio bus for stmacc driver

2015-12-10 Thread Giuseppe CAVALLARO
Hi also pls fix this typo stmmac: create of compatible mdio bus for stmacc driver stmmac On 12/9/2015 9:39 AM, Phil Reid wrote: The DSA driver needs to be passed a reference to an mdio bus. Typically

[PATCH (net-next.git) 08/18] stmmac: merge get_rx_owner into rx_status routine.

2016-01-04 Thread Giuseppe Cavallaro
rice.gasn...@st.com> Acked-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/common.h | 10 +- drivers/net/ethernet/stmicro/stmmac/enh_desc.c|9 +++-- drivers/net/ethernet/stmicro/stmmac/norm_desc.c |9 +++-- drivers/ne

[PATCHv2 (net-next.git) 00/18] stmmac: enhance driver performances and update the version

2016-01-04 Thread Giuseppe Cavallaro
attached to a phy Giuseppe Cavallaro (15): stmmac: share reset function between dwmac100 and dwmac1000 stmmac: rework DMA bus setting and introduce new platform AXI structure stmmac: change descriptor layout stmmac: remove modulo in stmmac_xmit() stmmac: add length field to dma data

[PATCH (net-next.git) 01/18] stmmac: share reset function between dwmac100 and dwmac1000

2016-01-04 Thread Giuseppe Cavallaro
This patch is to share the same reset procedure between dwmac100 and dwmac1000 chips. This will also help on enhancing the driver and support new chips. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/common.h |3 +- drive

[PATCH (net-next.git) 02/18] stmmac: rework DMA bus setting and introduce new platform AXI structure

2016-01-04 Thread Giuseppe Cavallaro
removed. It makes sense to provide the AAL parameter from DT to Address-Aligned Beats inside the Register0 and review the PBL settings when initialize the engine. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- Documentation/devicetree/bindings/net/stmmac.txt

[PATCH (net-next.git) 14/18] stmmac: do not poll phy handler when attach a switch

2016-01-04 Thread Giuseppe Cavallaro
ote that the stmmac_adjust_link will be called just one time and this guarantees that the ST glue logic will be setup according to the mode and speed fixed. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c |5 + 1 files changed, 5 i

[PATCH (net-next.git) 11/18] stmmac: set dirty index out of the loop

2016-01-04 Thread Giuseppe Cavallaro
The dirty index can be updated out of the loop where all the tx resources are claimed. This will help on performances too. Also a useless debug printk has been removed from the main loop. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/

[PATCH (net-next.git) 03/18] stmmac: change descriptor layout

2016-01-04 Thread Giuseppe Cavallaro
This patch completely changes the descriptor layout to improve the whole performances due to the single read usage of the descriptors in critical paths. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/descs.h

[PATCH (net-next.git) 13/18] stmmac: perf, remove modulo in stmmac_rx()

2016-01-04 Thread Giuseppe Cavallaro
Signed-off-by: Fabrice Gasnier <fabrice.gasn...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 28 ++--- 1 files changed, 24 insertions(+), 4 deletions(-) diff --git a/drivers/net/e

[PATCH (net-next.git) 04/18] stmmac: remove modulo in stmmac_xmit()

2016-01-04 Thread Giuseppe Cavallaro
urt trying to cope with huge numbers This patch replaces the modulo with a simple if clamp. Signed-off-by: David McKay <david.mc...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/chain_mode.c | 15 ++ drivers/net/e

[PATCH (net-next.git) 06/18] stmmac: add last_segment field to dma data

2016-01-04 Thread Giuseppe Cavallaro
com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/chain_mode.c |3 ++- drivers/net/ethernet/stmicro/stmmac/stmmac.h |1 + drivers/net/ethernet/stmicro/stmmac/stmmac_main.c |5 - 3 files changed, 7 insertions(+),

[PATCH (net-next.git) 12/18] stmmac: first frame prep at the end of xmit routine

2016-01-04 Thread Giuseppe Cavallaro
e. Signed-off-by: Fabrice Gasnier <fabrice.gasn...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/common.h |7 +- drivers/net/ethernet/stmicro/stmmac/enh_desc.c | 25 +++-- drivers/net/ethernet/stmicro/stmmac

[PATCH (net-next.git) 09/18] stmmac: optimize tx desc management

2016-01-04 Thread Giuseppe Cavallaro
This patch is to optimize the way to manage the TDES inside the xmit function. When prepare the frame, some settings (e.g. OWN bit) can be merged. This has been reworked to improve the tx performances. Signed-off-by: Fabrice Gasnier <fabrice.gasn...@st.com> Signed-off-by: Giuseppe Cav

[PATCHv2 (net-next.git) 16/18] stmmac: do not perform zero-copy for rx frames

2016-01-04 Thread Giuseppe Cavallaro
This patch is to allow this driver to copy tiny frames during the reception process. This is giving more stability while stressing the driver on STi embedded systems. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- V2: rx_copybreak tunable by using ethtool drivers/net/et

[PATCH (net-next.git) 18/18] stmmac: update version to Oct_2015

2016-01-04 Thread Giuseppe Cavallaro
This patch just updates the driver to the version fully tested on STi platforms. This version is Oct_2015. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac.h |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/d

[PATCH (net-next.git) 17/18] stmmac: tune rx copy via threshold.

2016-01-04 Thread Giuseppe Cavallaro
There is a threshold now used to also limit the skb allocation when use zero-copy. This is to avoid that there are incoherence in the ring due to a failure on skb allocation under very aggressive testing and under low memory conditions. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.

[PATCH (net-next.git) 15/18] stmmac: fix phy init when attached to a phy

2016-01-04 Thread Giuseppe Cavallaro
er <fabrice.gasn...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c |5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ether

[PATCH (net-next.git) 05/18] stmmac: add length field to dma data

2016-01-04 Thread Giuseppe Cavallaro
. Signed-off-by: Fabrice Gasnier <fabrice.gasn...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/chain_mode.c |3 +++ drivers/net/ethernet/stmicro/stmmac/ring_mode.c |5 + drivers/net/ethernet/stmicro/stmmac/stmmac.h

[PATCH (net-next.git) 10/18] stmmac: optimize tx clean function

2016-01-04 Thread Giuseppe Cavallaro
inside TX clean loop for enhanced descriptors but not for normal ones because the des1 must be read in any case. Signed-off-by: Fabrice Gasnier <fabrice.gasn...@st.com> Acked-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/common.h |8

[PATCH (net-next.git) 07/18] stmmac: add is_jumbo field to dma data

2016-01-04 Thread Giuseppe Cavallaro
<fabrice.gasn...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/chain_mode.c |3 ++- drivers/net/ethernet/stmicro/stmmac/ring_mode.c | 11 ++- drivers/net/ethernet/stmicro/stmmac/stmmac.h |1 + drivers/net/ethe

Re: [PATCH (net-next.git) 01/18] stmmac: share reset function between dwmac100 and dwmac1000

2016-01-05 Thread Giuseppe CAVALLARO
On 1/5/2016 4:25 AM, David Miller wrote: From: Giuseppe Cavallaro <peppe.cavall...@st.com> Date: Mon, 4 Jan 2016 14:06:46 +0100 @@ -376,7 +376,8 @@ extern const struct stmmac_desc_ops ndesc_ops; /* Specific DMA helpers */ struct stmmac_dma_ops { /* DMA core initiali

Re: [PATCH (net-next.git) 04/18] stmmac: remove modulo in stmmac_xmit()

2016-01-05 Thread Giuseppe CAVALLARO
Hi David On 1/5/2016 4:34 AM, David Miller wrote: From: Giuseppe Cavallaro <peppe.cavall...@st.com> Date: Mon, 4 Jan 2016 14:06:49 +0100 @@ -2056,7 +2068,10 @@ static netdev_tx_t stmmac_xmit(struct sk_buff *skb, struct net_device *dev) priv->hw->desc->set_tx_owner(firs

Re: [PATCH (net-next.git) 09/18] stmmac: optimize tx desc management

2016-01-05 Thread Giuseppe CAVALLARO
On 1/5/2016 4:39 AM, David Miller wrote: From: Giuseppe Cavallaro <peppe.cavall...@st.com> Date: Mon, 4 Jan 2016 14:06:54 +0100 @@ -334,12 +334,11 @@ struct stmmac_desc_ops { /* Invoked by the xmit function to prepare the tx descriptor */ void (*prepare_tx_desc) (

Re: [PATCH (net-next.git) 02/18] stmmac: rework DMA bus setting and introduce new platform AXI structure

2016-01-05 Thread Giuseppe CAVALLARO
On 1/5/2016 4:29 AM, David Miller wrote: From: Giuseppe Cavallaro <peppe.cavall...@st.com> Date: Mon, 4 Jan 2016 14:06:47 +0100 @@ -81,7 +81,7 @@ static void stmmac_default_data(struct plat_stmmacenet_data *plat) plat->mdio_bus_data->phy_mask = 0; plat->dm

Re: [PATCH v1] net: stmmac: Free rx_skbufs before realloc

2015-11-25 Thread Giuseppe CAVALLARO
Hello On 11/24/2015 7:09 PM, David Miller wrote: From: Shunqian Zheng Date: Sun, 22 Nov 2015 16:44:18 +0800 From: ZhengShunQian The init_dma_desc_rings() may realloc the rx_skbuff[] when suspend and resume. This patch free the rx_skbuff[]

[PATCH (net.git) 0/5] Spare stmmac fixes

2015-11-25 Thread Giuseppe Cavallaro
These are some fixes for the stmmac d.d. tested on STi platforms. They are for some part of the PM, STi glue and rx path when test Jumbo. Giuseppe Cavallaro (5): stmmac: fix a filter problem after resuming. stmmac: fix csr clock divisor for 300MHz stmmac: dwmac-sti: fix st,tx-retime-src

[PATCH (net.git) 3/5] stmmac: dwmac-sti: fix st,tx-retime-src check

2015-11-25 Thread Giuseppe Cavallaro
nitialized and the compiler, depending on the options adopted, could take it in some different part of the stack generating the hang in such configuration. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/dwmac-sti.c | 13 +++-- 1

[PATCH (net.git) 5/5] stmmac: fix oversized frame reception

2015-11-25 Thread Giuseppe Cavallaro
, from the DMA, an Jumbo frame and the Sw must check if the allocated buffer is enough to store the frame. Signed-off-by: Alexandre TORGUE <alexandre.tor...@st.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c |6 +++

[PATCH (net.git) 4/5] stmmac: fix PHY reset during resume

2015-11-25 Thread Giuseppe Cavallaro
com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c | 28 +--- 1 files changed, 13 insertions(+), 15 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c b/drivers/net/ethernet/st

[PATCH (net.git) 1/5] stmmac: fix a filter problem after resuming.

2015-11-25 Thread Giuseppe Cavallaro
When resume the HW is re-configured but some settings can be lost. For example, the MAC Address_X High/Low Registers used for VLAN tagging.. So, while resuming, the set_filter callback needs to be invoked to re-program perfect and hash-table registers. Signed-off-by: Giuseppe Cavallaro

[PATCH (net.git) 2/5] stmmac: fix csr clock divisor for 300MHz

2015-11-25 Thread Giuseppe Cavallaro
This patch is to fix the csr clock in case of 300MHz is provided. Reported-by: Kent Borg <kent.b...@csr.com> Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-)

[PATCH (net-next.git)] stmmac: support Reg_9 to get HW level information

2015-11-30 Thread Giuseppe Cavallaro
For GMAC newer than 3.40a there is a new register (Reg_9) that provides the status of all modules of the transmit and receive paths and FIFO status. These can be exposed via ethtool. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/co

[PATCH (net.git)] stmmac: fix resource management when resume

2015-11-26 Thread Giuseppe Cavallaro
and reallocate all from scratch because the memory data will be always preserved. As final solution, the patch just reinit the descriptors and the rx/tx pointers only when resume. Tested done on STi boxes. Reported-by: ZhengShunQian <zhen...@rock-chips.com> Signed-off-by: Giuseppe Cavallaro <pep

Re: [PATCH v1] net: stmmac: Free rx_skbufs before realloc

2015-11-26 Thread Giuseppe CAVALLARO
On 11/25/2015 4:13 PM, Giuseppe CAVALLARO wrote: Hello On 11/24/2015 7:09 PM, David Miller wrote: From: Shunqian Zheng <zhen...@rock-chips.com> Date: Sun, 22 Nov 2015 16:44:18 +0800 From: ZhengShunQian <zhen...@rock-chips.com> The init_dma_desc_rings() may realloc the rx_s

Re: [PATCH] net: stmmac: dwmac-rk: keep PHY up for WoL

2016-06-07 Thread Giuseppe CAVALLARO
Hello On 6/3/2016 7:29 PM, Vincent Palatin wrote: Do not shutdown the PHY if Wake-on-Lan is enabled, else it cannot wake us up. I do not understand why you need that. This is done inside the PHY layer and it is tested on our platforms he idea is: If the parent wants to Wake the system then

Re: [PATCH v3 1/1] net: ethernet: Add TSE PCS support to dwmac-socfpga

2016-06-07 Thread Giuseppe CAVALLARO
Hello On 6/7/2016 5:01 AM, th...@altera.com wrote: From: Tien Hock Loh This adds support for TSE PCS that uses SGMII adapter when the phy-mode of the dwmac is set to sgmii Signed-off-by: Tien Hock Loh --- v2: - Refactored the TSE PCS out from the

Re: net: stmmac: dwmac-rk: fixes for Wake-on-Lan on RK3288

2016-06-13 Thread Giuseppe CAVALLARO
On 6/11/2016 3:00 AM, Vincent Palatin wrote: In order to support Wake-On-Lan when using the RK3288 integrated MAC (with an external RGMII PHY), we need to avoid shutting down the regulator of the external PHY when the MAC is suspended as it's currently done in the MAC platform code. As a first

Re: [PATCH v3 1/1] net: ethernet: Add TSE PCS support to dwmac-socfpga

2016-06-10 Thread Giuseppe CAVALLARO
Hello Tien Hock On 6/10/2016 8:12 AM, Tien Hock Loh wrote: Yeah the PCS support for TSE is Altera. To avoid confusion, let's rename > > them, would altr_tse_pcs.[hc] be good? I don't think creating a > > sub-directory with only 2 files is necessary though. > > ok for two files w/o sub-dir. >

Re: [PATCH] net: stmmac: dwmac-rk: keep PHY up for WoL

2016-06-10 Thread Giuseppe CAVALLARO
Hello Vincent On 6/10/2016 1:00 AM, Vincent Palatin wrote: On Wed, Jun 8, 2016 at 5:17 PM, Andrew Lunn <and...@lunn.ch> wrote: On Wed, Jun 08, 2016 at 03:25:38PM -0700, Vincent Palatin wrote: On Tue, Jun 7, 2016 at 12:23 AM, Giuseppe CAVALLARO <peppe.cavall...@st.com> wrote: H

Re: [PATCH] stmmac: fix parameter to dwmac4_set_umac_addr()

2016-06-08 Thread Giuseppe CAVALLARO
any hardware with it in. Signed-off-by: Ben Dooks <ben.do...@codethink.co.uk> --- Cc: Giuseppe Cavallaro <peppe.cavall...@st.com> Cc: Alexandre Torgue <alexandre.tor...@st.com> Cc: netdev@vger.kernel.org Acked-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- driv

Re: [PATCH v3 1/1] net: ethernet: Add TSE PCS support to dwmac-socfpga

2016-06-09 Thread Giuseppe CAVALLARO
Hello Tien Hock On 6/9/2016 7:48 AM, Tien Hock Loh wrote: [snip] .../devicetree/bindings/net/socfpga-dwmac.txt | 4 + drivers/net/ethernet/stmicro/stmmac/Makefile | 2 +- .../net/ethernet/stmicro/stmmac/dwmac-socfpga.c| 140 +--

Re: [PATCH 1/1] net: ethernet: Add SGMII support to dwmac-socfpga

2016-05-31 Thread Giuseppe CAVALLARO
be refactored out as well for consistency purposes. yes agree. Just an info to better understand the case; after enabling the SGMII on Altera, do you test in some way the PCS SGMII mode in the main layer? Regards Peppe Thanks On Fri, May 13, 2016 at 3:47 PM, Giuseppe CAVALLARO <peppe.cavall...@st.

Re: [PATCH V4 1/1] net: ethernet: Add TSE PCS support to dwmac-socfpga

2016-06-22 Thread Giuseppe CAVALLARO
Hello Tien Hock On 6/21/2016 10:46 AM, th...@altera.com wrote: From: Tien Hock Loh This adds support for TSE PCS that uses SGMII adapter when the phy-mode of the dwmac is set to sgmii Signed-off-by: Tien Hock Loh IIUC, you are keeping the two timers w/o

Re: net: stmmac: dwmac-rk: fixes for Wake-on-Lan on RK3288

2016-06-16 Thread Giuseppe CAVALLARO
Hi Vincent On 6/15/2016 7:04 PM, Vincent Palatin wrote: On Sun, Jun 12, 2016 at 11:46 PM, Giuseppe CAVALLARO <peppe.cavall...@st.com> wrote: On 6/11/2016 3:00 AM, Vincent Palatin wrote: In order to support Wake-On-Lan when using the RK3288 integrated MAC (with an external RGMII PHY), w

Re: [PATCH V4 1/1] net: ethernet: Add TSE PCS support to dwmac-socfpga

2016-06-23 Thread Giuseppe CAVALLARO
On 6/23/2016 3:38 AM, Tien Hock Loh wrote: Hi Peppe, On Wed, 2016-06-22 at 11:00 +0200, Giuseppe CAVALLARO wrote: Hello Tien Hock On 6/21/2016 10:46 AM, th...@altera.com wrote: From: Tien Hock Loh <th...@altera.com> This adds support for TSE PCS that uses SGMII adapter when the ph

[PATCH (net-next.git) 2/3] drivers: net: stmmac: rework core ISR to better manage PCS and PMT

2016-06-24 Thread Giuseppe Cavallaro
capability register reports. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/common.h | 2 ++ drivers/net/ethernet/stmicro/stmmac/dwmac1000.h| 30 ++ .../net/ethernet/stmicro/stmmac/dwmac1000_core.c

[PATCH (net-next.git) 1/3] drivers: net: stmmac: reworking the PCS code.

2016-06-24 Thread Giuseppe Cavallaro
to support new features. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- Documentation/networking/stmmac.txt| 1 + drivers/net/ethernet/stmicro/stmmac/common.h | 16 ++- drivers/net/ethernet/stmicro/stmmac/dwmac1000.h| 56 +++- .../net/ethernet/s

[PATCH (net-next.git) 0/3] stmmac: rework and enhance the PCS support

2016-06-24 Thread Giuseppe Cavallaro
and, as for the previous version, not fully tested. Giuseppe Cavallaro (3): drivers: net: stmmac: reworking the PCS code. drivers: net: stmmac: rework core ISR to better manage PCS and PMT drivers: net: stmmac: add port selection programming Documentation/devicetree/bindings/net/stmmac.txt | 3

[PATCH (net-next.git) 3/3] drivers: net: stmmac: add port selection programming

2016-06-24 Thread Giuseppe Cavallaro
to use it. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- Documentation/devicetree/bindings/net/stmmac.txt | 3 +++ drivers/net/ethernet/stmicro/stmmac/common.h | 1 + drivers/net/ethernet/stmicro/stmmac/dwmac1000_core.c | 15 +++ drivers/net/et

Re: [PATCH] net: stmmac: Fix null-function call in ISR on stmmac1000

2016-06-26 Thread Giuseppe CAVALLARO
-by: Matt Corallo <g...@bluematt.me> Acked-by: Giuseppe Cavallaro <peppe.cavall...@st.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/st

Re: net: stmmac: dwmac-rk: fixes for Wake-on-Lan on RK3288

2016-06-16 Thread Giuseppe CAVALLARO
On 6/16/2016 4:51 PM, Vincent Palatin wrote: Hi Giuseppe, On Thu, Jun 16, 2016 at 6:37 AM, Giuseppe CAVALLARO <peppe.cavall...@st.com> wrote: Hi Vincent On 6/15/2016 7:04 PM, Vincent Palatin wrote: On Sun, Jun 12, 2016 at 11:46 PM, Giuseppe CAVALLARO <peppe.cavall...@st.com> w

Re: [PATCH 0/4] Add Ethernet support on STM32F429

2016-02-03 Thread Giuseppe CAVALLARO
that DT patches are not present because STM32 pinctrl code is not yet avalaible. patches look ok for me Acked-by: Giuseppe Cavallaro <peppe.cavall...@st.com> Regards Alexandre Alexandre TORGUE (4): net: ethernet: dwmac: add Ethernet glue logic for stm32 chip Documentation: Binding

Re: [PATCH (net-next.git) 01/18] stmmac: share reset function between dwmac100 and dwmac1000

2016-02-01 Thread Giuseppe CAVALLARO
On 1/5/2016 7:45 PM, David Miller wrote: From: Giuseppe CAVALLARO <peppe.cavall...@st.com> Date: Tue, 5 Jan 2016 10:03:28 +0100 On 1/5/2016 4:25 AM, David Miller wrote: From: Giuseppe Cavallaro <peppe.cavall...@st.com> Date: Mon, 4 Jan 2016 14:06:46 +0100 @@ -376,7 +376,8 @@

Re: [PATCH v3 00/17] stmmac: enhance driver performances and update the version

2016-02-29 Thread Giuseppe CAVALLARO
and chain. == Fabrice Gasnier (3): stmmac: merge get_rx_owner into rx_status routine. stmmac: optimize tx clean function stmmac: fix phy init when attached to a phy Giuseppe Cavallaro (14): stmmac: share reset

Re: [PATCH v3 00/17] stmmac: enhance driver performances and update the version

2016-02-29 Thread Giuseppe CAVALLARO
: optimize tx clean function stmmac: fix phy init when attached to a phy Giuseppe Cavallaro (14): stmmac: share reset function between dwmac100 and dwmac1000 stmmac: rework DMA bus setting and introduce new platform AXI structure stmmac: change descriptor layout stmmac: review RX/TX

Re: [PATCH v3 0/4] Add Ethernet support on STM32F429

2016-02-29 Thread Giuseppe CAVALLARO
and remove driver is no more driven in stmmac_pltfr but directly in dwmac-stm32 glue driver. -Take into account Joachim review. Regards. Alexandre. thanks Alex, for the series please consider my: Acked-by: Giuseppe Cavallaro <peppe.cavall...@st.com> Alexandre TORGUE (4): net: ethernet:

Re: [PATCH v3 00/17] stmmac: enhance driver performances and update the version

2016-03-01 Thread Giuseppe CAVALLARO
patches on top of this subset for net-next branch. For sure, we will work together to have the best solution for these chips. Regards Peppe - Lars On 02/29/2016 05:50 PM, Giuseppe CAVALLARO wrote: Gents on top of these patches, there is a new train to enhance the stmmac to support the DWMAC_4

Re: [PATCH v3 0/8] arm64: rockchip: Initial GeekBox enablement

2016-03-10 Thread Giuseppe CAVALLARO
On 3/9/2016 5:31 PM, Dinh Nguyen wrote: On Wed, Mar 9, 2016 at 8:53 AM, Giuseppe CAVALLARO <peppe.cavall...@st.com> wrote: Hi Tomeu, Dinh, Andreas I need a sum and help from you to go ahead on the tx timeout. The "stmmac: MDIO fixes" seems to be the candidate to fix the phy

Re: [PATCH v3 0/8] arm64: rockchip: Initial GeekBox enablement

2016-03-14 Thread Giuseppe CAVALLARO
Hi Tomeu On 3/14/2016 12:43 PM, Tomeu Vizoso wrote: Hi Peppe, with that patch I don't see any difference at all in my setup. So to be clear, with these commits on top of next-20160314, I still get the hang during boot: 209afef6f0cd ARM: dts: rockchip: Add mdio node to ethernet node

Re: [PATCH (net-next.git) 2/2] stmmac: fix MDIO settings

2016-03-18 Thread Giuseppe CAVALLARO
Hello On 3/16/2016 12:03 PM, Andreas Färber wrote: Am 16.03.2016 um 12:01 schrieb Gabriel Fernandez: Hi Pepe, i have a kernel crash [2.714097] Unable to handle kernel NULL pointer dereference at virtual address 01d6 [2.722188] pgd = c0204000 [2.724886] [01d6]

[PATCHv2 (net.git) 1/2] Revert "stmmac: Fix 'eth0: No PHY found' regression"

2016-03-10 Thread Giuseppe Cavallaro
This reverts commit 88f8b1bb41c6208f81b6a480244533ded7b59493. due to problems on GeekBox and Banana Pi M1 board when connected to a real transceiver instead of a switch via fixed-link. Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> Cc: Gabriel Fernandez <gabriel.fernan...@l

[PATCHv2 (net.git) 2/2] stmmac: fix MDIO settings

2016-03-10 Thread Giuseppe Cavallaro
to be managed by using fixed-link). Signed-off-by: Giuseppe Cavallaro <peppe.cavall...@st.com> Reviewed-by: Andreas Färber <afaer...@suse.de> Tested-by: Frank Schäfer <fschaefer@googlemail.com> Cc: Gabriel Fernandez <gabriel.fernan...@linaro.org> Cc: Dinh Nguyen <dinh.l

[PATCHv2 (net.git) 0/2] stmmac: MDIO fixes

2016-03-10 Thread Giuseppe Cavallaro
These two patches are to fix the recent regressions raised when test the stmmac on some platforms due to broken MDIO management. V2: use is_pseudo_fixed_link Giuseppe Cavallaro (2): Revert "stmmac: Fix 'eth0: No PHY found' regression" stmmac: fix MDIO settings drivers/net/ethern

Re: [PATCHv2 (net.git) 2/2] stmmac: fix MDIO settings

2016-03-11 Thread Giuseppe CAVALLARO
On 3/11/2016 9:16 AM, Phil Reid wrote: G'day Giuseppe, Sorry for delay in responding. I feel responsible for starting the changes breaking this. See below. On 11/03/2016 3:44 PM, Giuseppe Cavallaro wrote: Initially the phy_bus_name was added to manipulate the driver name but It was recently

Re: [PATCH v3 0/8] arm64: rockchip: Initial GeekBox enablement

2016-03-11 Thread Giuseppe CAVALLARO
On 3/10/2016 5:47 PM, Dinh Nguyen wrote: On Thu, Mar 10, 2016 at 3:13 AM, Giuseppe CAVALLARO <peppe.cavall...@st.com> wrote: On 3/9/2016 5:31 PM, Dinh Nguyen wrote: On Wed, Mar 9, 2016 at 8:53 AM, Giuseppe CAVALLARO <peppe.cavall...@st.com> wrote: Hi Tomeu, Dinh, Andreas

Re: [PATCHv3 (net.git) 2/2] stmmac: fix MDIO settings

2016-03-14 Thread Giuseppe CAVALLARO
On 3/14/2016 10:14 AM, Gabriel Fernandez wrote: Hi Peppe, Just one remark below diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c index 6a52fa1..d2322e9 100644 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c

Re: [PATCH v3 0/8] arm64: rockchip: Initial GeekBox enablement

2016-03-15 Thread Giuseppe CAVALLARO
Hello Tomeu On 3/15/2016 8:23 AM, Tomeu Vizoso wrote: Thanks. Btw, I have rebased on top of 4.5 this morning and I have noticed that 88f8b1bb41c6 ("stmmac: Fix 'eth0: No PHY found' regression") got in there, so I guess we have now a bunch of boards with broken network on that release:( This

Re: [PATCHv3 (net.git) 2/2] stmmac: fix MDIO settings

2016-03-15 Thread Giuseppe CAVALLARO
Hi Andreas On 3/15/2016 1:54 AM, Andreas Färber wrote: Hi Peppe, Am 11.03.2016 um 14:33 schrieb Giuseppe Cavallaro: Initially the phy_bus_name was added to manipulate the driver name but It was recently just used to manage the "it" fixed-link and then to take some decision a

Re: [PATCH v3 0/8] arm64: rockchip: Initial GeekBox enablement

2016-03-08 Thread Giuseppe CAVALLARO
Hi Dinh On 3/8/2016 4:45 PM, Dinh Nguyen wrote: On Tue, Mar 8, 2016 at 1:24 AM, Giuseppe CAVALLARO <peppe.cavall...@st.com> wrote: Hi Dinh, On 3/8/2016 12:22 AM, Dinh Nguyen wrote: [snip] I'm seeing the same issue on the SoCFPGA platform: libphy: PHY stmmac-0: not foun

Re: [PATCH (net.git) 2/2] stmmac: fix MDIO settings

2016-03-09 Thread Giuseppe CAVALLARO
ode is not present. I will propose a patch for net-next later. I'd like to try to fix the new regression on xmit. thx to have spot this. Regards peppe Best regards Gabriel On 9 March 2016 at 10:00, Giuseppe Cavallaro <peppe.cavall...@st.com> wrote: Initially the phy_bus_name

Re: [PATCH v3 0/8] arm64: rockchip: Initial GeekBox enablement

2016-03-09 Thread Giuseppe CAVALLARO
Hello Tomeu, Andreas, On 3/9/2016 10:52 AM, Giuseppe CAVALLARO wrote: * today's linux-next: probe failed * today's linux-next + revert of 88f8b1bb41c6 stmmac: Fix 'eth0: No PHY found' regression: probe succeeded but no network at all * today's linux-next + revert of 88f8b1bb41c6 (stmmac: Fix

  1   2   3   >