Re: [PATCH 6/6] net: stmmac: revert "support future possible different internal phy mode"

2017-07-06 Thread Corentin Labbe
On Sun, Jul 02, 2017 at 02:31:59PM +0200, Corentin Labbe wrote: > Since internal phy-mode is reserved for non-xMII protocol we cannot use > it with dwmac-sun8i > This reverts commit 1c2fa5f84683 ("net: stmmac: support future possible > different internal phy mode") >

[PATCH] net: stmmac: revert "support future possible different internal phy mode"

2017-07-12 Thread Corentin Labbe
mode") Fixes: 1c2fa5f84683 ("net: stmmac: support future possible different internal phy mode") Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c | 10 +++--- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/drivers/net/ethernet/

Re: [PATCH v2 05/11] net: stmmac: dwmac-rk: Add internal phy support

2017-07-27 Thread Corentin Labbe
g: "internal-rmii" > which describes that, either way would probably be fine, but the former > scales better > Hello We have the same problem on Allwinner SoCs for dwmac-sun8i, we need to set a syscon for chossing between internal/external PHY. Having this phy-is-internal would be very helpfull. (adding internal-xmii will add too many flags in our case) Thanks Regards Corentin Labbe

[PATCH 3/3] net-next: stmmac: dwmac-sun8i: choose internal PHY via compatible

2017-07-28 Thread Corentin Labbe
the phy_mode of the internal PHY does need to be know, the variant internal_phy member is converted to a boolean. Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c | 16 ++-- 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/drivers/net

[PATCH 1/3] dt-bindings: net: add compatible for internal sun8i-h3/sun8i-v3s PHYs

2017-07-28 Thread Corentin Labbe
The internal PHYs for H3 ans V3S now need to have their own compatible. This patch rename them in the binding documentation. Signed-off-by: Corentin Labbe --- Documentation/devicetree/bindings/net/dwmac-sun8i.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a

[PATCH 2/3] ARM: sunxi: h3/h5: Add sun8i-h3-ephy compatible

2017-07-28 Thread Corentin Labbe
This patch adds the sun8i-h3-ephy compatible to the internal PHY. Signed-off-by: Corentin Labbe --- arch/arm/boot/dts/sunxi-h3-h5.dtsi | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/arm/boot/dts/sunxi-h3-h5.dtsi b/arch/arm/boot/dts/sunxi-h3-h5.dtsi index

[PATCH 0/3] net-next: stmmac: support future possible different internal phy mode

2017-07-28 Thread Corentin Labbe
compatible. Corentin Labbe (3): dt-bindings: net: add compatible for internal sun8i-h3/sun8i-v3s PHYs ARM: sunxi: h3/h5: Add sun8i-h3-ephy compatible net-next: stmmac: dwmac-sun8i: choose internal PHY via compatible Documentation/devicetree/bindings/net/dwmac-sun8i.txt | 4 ++-- arch/arm/boot

Re: [PATCH 3/3] net-next: stmmac: dwmac-sun8i: choose internal PHY via compatible

2017-07-28 Thread Corentin Labbe
On Fri, Jul 28, 2017 at 05:49:55PM +0800, Chen-Yu Tsai wrote: > On Fri, Jul 28, 2017 at 5:28 PM, Corentin Labbe > wrote: > > The current way to find if the phy is internal is to compare DT phy-mode > > and emac_variant/internal_phy. > > But it will negate a possible futu

Re: [PATCH 0/3] net-next: stmmac: support future possible different internal phy mode

2017-07-28 Thread Corentin Labbe
On Fri, Jul 28, 2017 at 03:55:44PM +0200, Andrew Lunn wrote: > On Fri, Jul 28, 2017 at 11:28:15AM +0200, Corentin Labbe wrote: > > Hello > > > > The current way to find if the phy is internal is to compare DT phy-mode > > and emac_variant/internal_phy. > > But it

Re: [PATCH 0/3] net-next: stmmac: support future possible different internal phy mode

2017-07-28 Thread Corentin Labbe
On Fri, Jul 28, 2017 at 04:36:00PM +0200, Andrew Lunn wrote: > > > I've probably asked this before: Does the internal PHY use a different > > > PHY ID in registers 2 and 3? > > > > > > > yes > > > > reg2: 0x0044 > > reg3: 0X1500 Copy/paste error, its 1400 > > So this is not about loading the

Re: [PATCH v4 4/5] net: stmmac: dwmac-sun8i: choose internal PHY via phy-is-integrated

2017-08-29 Thread Corentin Labbe
On Sat, Aug 26, 2017 at 11:20:51PM +0200, Andrew Lunn wrote: > Hi Corentin > > I think we have now all agreed this is an mdio-mux, plus it is also an > MII mux. We should represent that in device tree. This patchset does > this. However, as it is now, the mux structure in DT is ignored. All > it d

Re: [PATCH] net: stmmac: dwmac-sun8i: Use reset exclusive

2017-08-30 Thread Corentin Labbe
On Fri, Aug 25, 2017 at 07:12:33PM +0200, Maxime Ripard wrote: > On Fri, Aug 25, 2017 at 05:17:33PM +0200, Corentin Labbe wrote: > > On Fri, Aug 25, 2017 at 04:48:32PM +0200, Maxime Ripard wrote: > > > On Fri, Aug 25, 2017 at 04:38:05PM +0200, Corentin Labbe wrote: > > >

[PATCH 5/5] net: mdio-mux: fix unbalanced put_device

2017-08-30 Thread Corentin Labbe
nch of "if (mux_bus)". Signed-off-by: Corentin Labbe --- drivers/net/phy/mdio-mux.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/phy/mdio-mux.c b/drivers/net/phy/mdio-mux.c index 9a889a529b9c..0b7d3d30ae97 100644 --- a/drivers/net/phy/mdio-mux.c +++ b/

[PATCH 4/5] net: mdio-mux-mmioreg: Can handle 8/16/32 bits registers

2017-08-30 Thread Corentin Labbe
This patch fix an old information that mdio-mux-mmioreg can only handle 8bit registers. This is not true anymore. Signed-off-by: Corentin Labbe --- drivers/net/phy/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig index

[PATCH 2/5] net: mdio-mux: Remove unnecessary 'out of memory' message

2017-08-30 Thread Corentin Labbe
This patch fix checkpatch warning about unnecessary 'out of memory' message. Signed-off-by: Corentin Labbe --- drivers/net/phy/mdio-mux.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/drivers/net/phy/mdio-mux.c b/drivers/net/phy/mdio-mux.c index b18ad7082b88..5e08e8946

[PATCH 0/5] net: mdio-mux: Misc fix

2017-08-30 Thread Corentin Labbe
Hello This patch series fix minor problems found when working on the dwmac-sun8i syscon mdio-mux. Regards Corentin Labbe (5): net: mdio-mux: Fix NULL Comparison style net: mdio-mux: Remove unnecessary 'out of memory' message net: mdio-mux: printing driver version is useless

[PATCH 3/5] net: mdio-mux: printing driver version is useless

2017-08-30 Thread Corentin Labbe
Remove the driver version information because this information is not useful in an upstream kernel driver. Signed-off-by: Corentin Labbe --- drivers/net/phy/mdio-mux.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/net/phy/mdio-mux.c b/drivers/net/phy/mdio-mux.c index 5e08e89465c5

[PATCH 1/5] net: mdio-mux: Fix NULL Comparison style

2017-08-30 Thread Corentin Labbe
This patch fix checkpatch warning about NULL Comparison style. Signed-off-by: Corentin Labbe --- drivers/net/phy/mdio-mux.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/phy/mdio-mux.c b/drivers/net/phy/mdio-mux.c index 942ceaf3fd3f..b18ad7082b88 100644

Re: [PATCH 0/5] net: mdio-mux: Misc fix

2017-09-01 Thread Corentin Labbe
On Wed, Aug 30, 2017 at 09:01:19PM +0200, Andrew Lunn wrote: > On Wed, Aug 30, 2017 at 07:46:46PM +0200, Corentin Labbe wrote: > > Hello > > > > This patch series fix minor problems found when working on the > > dwmac-sun8i syscon mdio-mux. > > Hi Corentin

[PATCH v2 2/5] net: mdio-mux: Remove unnecessary 'out of memory' message

2017-09-01 Thread Corentin Labbe
This patch fix checkpatch warning about unnecessary 'out of memory' message. Signed-off-by: Corentin Labbe Reviewed-by: Andrew Lunn --- drivers/net/phy/mdio-mux.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/drivers/net/phy/mdio-mux.c b/drivers/net/phy/mdio-mux.c index b1

[PATCH v2 5/5] net: mdio-mux: fix unbalanced put_device

2017-09-01 Thread Corentin Labbe
nch of "if (mux_bus)". Signed-off-by: Corentin Labbe --- drivers/net/phy/mdio-mux.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/net/phy/mdio-mux.c b/drivers/net/phy/mdio-mux.c index 282828551bdd..6f75e9f27fed 100644 --- a/drivers/net/phy/mdio-mux.c +++ b/

[PATCH v2 3/5] net: mdio-mux: printing driver version is useless

2017-09-01 Thread Corentin Labbe
Remove the driver version information because this information is not useful in an upstream kernel driver. Signed-off-by: Corentin Labbe --- drivers/net/phy/mdio-mux.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/net/phy/mdio-mux.c b/drivers/net/phy/mdio-mux.c index

[PATCH v2 4/5] net: mdio-mux-mmioreg: Can handle 8/16/32 bits registers

2017-09-01 Thread Corentin Labbe
This patch fix an old information that mdio-mux-mmioreg can only handle 8bit registers. This is not true anymore. Signed-off-by: Corentin Labbe Reviewed-by: Andrew Lunn --- drivers/net/phy/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/phy/Kconfig b

[PATCH v2 0/5] net: mdio-mux: Misc fix

2017-09-01 Thread Corentin Labbe
Hello This patch series fix minor problems found when working on the dwmac-sun8i syscon mdio-mux. Regards Changes since v1: - Removed obsolete comment about of_mdio_find_bus/put_device - removed more DRV_VERSION Corentin Labbe (5): net: mdio-mux: Fix NULL Comparison style net: mdio-mux

[PATCH v2 1/5] net: mdio-mux: Fix NULL Comparison style

2017-09-01 Thread Corentin Labbe
This patch fix checkpatch warning about NULL Comparison style. Signed-off-by: Corentin Labbe Reviewed-by: Andrew Lunn --- drivers/net/phy/mdio-mux.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/phy/mdio-mux.c b/drivers/net/phy/mdio-mux.c index

[PATCH 0/1] net: mdio-mux: add mdio_mux parameter to mdio_mux_init()

2017-09-04 Thread Corentin Labbe
acceptable. Regards Corentin Labbe (1): net: mdio-mux: add mdio_mux parameter to mdio_mux_init() drivers/net/phy/mdio-mux-bcm-iproc.c | 2 +- drivers/net/phy/mdio-mux-gpio.c | 2 +- drivers/net/phy/mdio-mux-mmioreg.c | 3 ++- drivers/net/phy/mdio-mux.c | 7 --- include/linux/

[PATCH 1/1] net: mdio-mux: add mdio_mux parameter to mdio_mux_init()

2017-09-04 Thread Corentin Labbe
direct owning device. For example a mdio-mux which is a subnode of a real device. Signed-off-by: Corentin Labbe --- drivers/net/phy/mdio-mux-bcm-iproc.c | 2 +- drivers/net/phy/mdio-mux-gpio.c | 2 +- drivers/net/phy/mdio-mux-mmioreg.c | 3 ++- drivers/net/phy/mdio-mux.c | 7

[PATCH v5 10/10] net: stmmac: dwmac-sun8i: Handle integrated/external MDIOs

2017-09-08 Thread Corentin Labbe
The Allwinner H3 SoC have two distinct MDIO bus, only one could be active at the same time. The selection of the active MDIO bus are done via some bits in the EMAC register of the system controller. This patch implement this MDIO switch via a custom MDIO-mux. Signed-off-by: Corentin Labbe

[PATCH v5 09/10] net: stmmac: snps,dwmac-mdio MDIOs are automatically registered

2017-09-08 Thread Corentin Labbe
d to be in need_mdio_ids. Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c | 4 1 file changed, 4 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c index a366b3747eeb..3de5501e3

[PATCH v5 08/10] net: stmmac: dwmac-sun8i: choose internal PHY via phy-is-integrated

2017-09-08 Thread Corentin Labbe
property. Since the internal_phy variable does not need anymore to contain the xMII mode used by the internal PHY, it is still used for knowing the presence of an internal PHY, so it is modified to a boolean soc_has_internal_phy. Signed-off-by: Corentin Labbe Acked-by: Chen-Yu Tsai Reviewed-by

[PATCH v5 07/10] arm64: dts: allwinner: add snps,dwmac-mdio compatible to emac/mdio

2017-09-08 Thread Corentin Labbe
stmmac bindings docs said that its mdio node must have compatible = "snps,dwmac-mdio"; Since dwmac-sun8i does not have any good reasons to not doing it, all their MDIO node must have it. Signed-off-by: Corentin Labbe --- arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 1 + 1 file

[PATCH v5 06/10] ARM: dts: sunxi: h3/h5: represent the mdio switch used by sun8i-h3-emac

2017-09-08 Thread Corentin Labbe
Since dwmac-sun8i could use either an integrated PHY or an external PHY (which could be at same MDIO address), we need to represent this selection by a MDIO switch. Signed-off-by: Corentin Labbe --- arch/arm/boot/dts/sunxi-h3-h5.dtsi | 30 +- 1 file changed, 25

[PATCH v5 05/10] dt-bindings: net: dwmac-sun8i: update documentation about integrated PHY

2017-09-08 Thread Corentin Labbe
This patch add documentation about the MDIO switch used on sun8i-h3-emac for integrated PHY. Signed-off-by: Corentin Labbe --- .../devicetree/bindings/net/dwmac-sun8i.txt| 127 +++-- 1 file changed, 120 insertions(+), 7 deletions(-) diff --git a/Documentation/devicetree

[PATCH v5 02/10] dt-bindings: net: Restore sun8i dwmac binding

2017-09-08 Thread Corentin Labbe
This patch restore dt-bindings documentation about dwmac-sun8i This reverts commit 8aa33ec2f481 ("dt-bindings: net: Revert sun8i dwmac binding") Signed-off-by: Corentin Labbe --- .../devicetree/bindings/net/dwmac-sun8i.txt| 84 ++ 1 file changed, 84

[PATCH v5 03/10] arm: dts: sunxi: Restore EMAC changes

2017-09-08 Thread Corentin Labbe
This patch restore arm DT about dwmac-sun8i This reverts commit fe45174b72ae ("arm: dts: sunxi: Revert EMAC changes") Signed-off-by: Corentin Labbe --- arch/arm/boot/dts/sun8i-h2-plus-orangepi-zero.dts | 9 arch/arm/boot/dts/sun8i-h3-bananapi-m2-plus.dts | 19 +

[PATCH v5 04/10] net: stmmac: sun8i: Restore the compatibles

2017-09-08 Thread Corentin Labbe
This patch restore compatibles about dwmac-sun8i This reverts commit ad4540cc5aa3 ("net: stmmac: sun8i: Remove the compatibles") Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c | 8 1 file changed, 8 insertions(+) diff --git a/drivers/ne

[PATCH v5 00/10] net: stmmac: dwmac-sun8i: Handle integrated PHY

2017-09-08 Thread Corentin Labbe
oC dtsi to final board DT. Corentin Labbe (10): arm64: dts: allwinner: Restore EMAC changes dt-bindings: net: Restore sun8i dwmac binding arm: dts: sunxi: Restore EMAC changes net: stmmac: sun8i: Restore the compatibles dt-bindings: net: dwmac-sun8i: update documentation about integrated

[PATCH v5 01/10] arm64: dts: allwinner: Restore EMAC changes

2017-09-08 Thread Corentin Labbe
This patch restore arm64 DT about dwmac-sun8i This reverts commit 87e1f5e8bb4b ("arm64: dts: allwinner: Revert EMAC changes") Signed-off-by: Corentin Labbe --- .../boot/dts/allwinner/sun50i-a64-bananapi-m64.dts | 16 .../boot/dts/allwinner/sun50i-a64-pine64-plus.d

Re: [PATCH v5 01/10] arm64: dts: allwinner: Restore EMAC changes

2017-09-08 Thread Corentin Labbe
On Fri, Sep 08, 2017 at 09:19:54AM +0200, Maxime Ripard wrote: > On Fri, Sep 08, 2017 at 09:11:47AM +0200, Corentin Labbe wrote: > > diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h5-nanopi-neo2.dts > > b/arch/arm64/boot/dts/allwinner/sun50i-h5-nanopi-neo2.dts > &g

Re: [PATCH v5 05/10] dt-bindings: net: dwmac-sun8i: update documentation about integrated PHY

2017-09-08 Thread Corentin Labbe
On Fri, Sep 08, 2017 at 09:25:38AM +0200, Maxime Ripard wrote: > On Fri, Sep 08, 2017 at 09:11:51AM +0200, Corentin Labbe wrote: > > This patch add documentation about the MDIO switch used on sun8i-h3-emac > > for integrated PHY. > > > > Signed-off-by: Corentin Labbe

Re: [PATCH v5 10/10] net: stmmac: dwmac-sun8i: Handle integrated/external MDIOs

2017-09-08 Thread Corentin Labbe
On Fri, Sep 08, 2017 at 03:05:20PM +0200, Andrew Lunn wrote: > > +#define DWMAC_sUN8I_MDIO_MUX_INTERNAL_ID 0 > > +#define DWMAC_sUN8I_MDIO_MUX_EXTERNAL_ID 1 > > > > /* H3/A64 specific bits */ > > #define SYSCON_RMII_EN BIT(13) /* 1: enable RMII (overrides > > EPIT) */ > > @@ -6

Re: [PATCH v5 10/10] net: stmmac: dwmac-sun8i: Handle integrated/external MDIOs

2017-09-08 Thread Corentin Labbe
On Fri, Sep 08, 2017 at 04:00:20PM +0200, Andrew Lunn wrote: > > > > +static int mdio_mux_syscon_switch_fn(int current_child, int > > > > desired_child, > > > > +void *data) > > > > +{ > > > > + struct stmmac_priv *priv = data; > > > > + struct sunxi

Re: [PATCH v5 10/10] net: stmmac: dwmac-sun8i: Handle integrated/external MDIOs

2017-09-08 Thread Corentin Labbe
e reality is that with nothing connected to it, the reset of the MAC timeout. Certainly, the MAC does not support finding no PHY. So, to prevent an error message, and a "freeze" of the net process, the need_reset trick is necessary. Regards Corentin Labbe

Re: [PATCH v5 01/10] arm64: dts: allwinner: Restore EMAC changes

2017-09-10 Thread Corentin Labbe
On Fri, Sep 08, 2017 at 03:39:04PM +0800, Chen-Yu Tsai wrote: > On Fri, Sep 8, 2017 at 3:36 PM, Corentin Labbe > wrote: > > On Fri, Sep 08, 2017 at 09:19:54AM +0200, Maxime Ripard wrote: > >> On Fri, Sep 08, 2017 at 09:11:47AM +0200, Corentin Labbe wrote: > >> >

Re: [PATCH v5 10/10] net: stmmac: dwmac-sun8i: Handle integrated/external MDIOs

2017-09-11 Thread Corentin Labbe
On Mon, Sep 11, 2017 at 06:11:24PM +0200, Andrew Lunn wrote: > On Fri, Sep 08, 2017 at 04:28:25PM +0200, Corentin Labbe wrote: > > On Fri, Sep 08, 2017 at 04:17:36PM +0200, Andrew Lunn wrote: > > > > > Do you know why the reset times out/fails? > > > > > >

Re: [PATCH v5 10/10] net: stmmac: dwmac-sun8i: Handle integrated/external MDIOs

2017-09-12 Thread Corentin Labbe
On Mon, Sep 11, 2017 at 10:19:20PM +0200, Andrew Lunn wrote: > > Even with CLK_BUS_EPHY/RST_BUS_EPHY enabled, the MAC reset timeout. > > So no the CLK/RST are really for the PHY. > > Thanks for trying that. > > You said it was probably during scanning of the bus it times out. What > address is ca

Re: [PATCH v5 02/10] dt-bindings: net: Restore sun8i dwmac binding

2017-09-14 Thread Corentin Labbe
On Wed, Sep 13, 2017 at 01:07:34PM -0500, Rob Herring wrote: > On Fri, Sep 08, 2017 at 09:11:48AM +0200, Corentin Labbe wrote: > > This patch restore dt-bindings documentation about dwmac-sun8i > > This reverts commit 8aa33ec2f481 ("dt-bindings: net: Revert sun8i dwmac &g

Re: [PATCH v5 05/10] dt-bindings: net: dwmac-sun8i: update documentation about integrated PHY

2017-09-14 Thread Corentin Labbe
On Wed, Sep 13, 2017 at 01:20:04PM -0500, Rob Herring wrote: > On Fri, Sep 08, 2017 at 09:43:25AM +0200, Corentin Labbe wrote: > > On Fri, Sep 08, 2017 at 09:25:38AM +0200, Maxime Ripard wrote: > > > On Fri, Sep 08, 2017 at 09:11:51AM +0200, Corentin Labbe wrote: >

[PATCH] vhost: remove unneeded linux/miscdevice.h include

2017-09-18 Thread Corentin Labbe
drivers/vhost/vhost.c does not use any miscdevice, so this patch remove this unnecessary inclusion. Signed-off-by: Corentin Labbe --- drivers/vhost/vhost.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/vhost/vhost.c b/drivers/vhost/vhost.c index 33ac2b186b85..33ab839696f9 100644

[PATCH] vsock: vmci: Remove unneeded linux/miscdevice.h include

2017-09-18 Thread Corentin Labbe
net/vmw_vsock/vmci_transport.c does not use any miscdevice so this patch remove this unnecessary inclusion. Signed-off-by: Corentin Labbe --- net/vmw_vsock/vmci_transport.c | 1 - 1 file changed, 1 deletion(-) diff --git a/net/vmw_vsock/vmci_transport.c b/net/vmw_vsock/vmci_transport.c index

[PATCH v2] net: stmmac: dwmac-sun8i: Use reset exclusive

2017-09-18 Thread Corentin Labbe
not in the device node. Signed-off-by: Corentin Labbe --- Changes since v1: - added a note about devm_reset_control_get in commit message drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/stmicro/stmmac

Re: [PATCH v5 05/10] dt-bindings: net: dwmac-sun8i: update documentation about integrated PHY

2017-09-18 Thread Corentin Labbe
> > Andrew Hello Rob, could you anwser/confirm please. I wait on this for sending the next version. Thanks Regards Corentin Labbe

[PATCH] net: ethernet: i40e: remove i40e_fcoe files

2018-01-28 Thread Corentin Labbe
i40e_fcoe support was removed via commit 9eed69a9147c ("i40e: Drop FCoE code from core driver files") But this left files in place but uncompilable. Let's finish the cleaning. Signed-off-by: Corentin Labbe --- drivers/net/ethernet/intel/i40e/i40

Re: [PATCH 0/3] net-next: stmmac: support future possible different internal phy mode

2017-07-28 Thread Corentin Labbe
On Fri, Jul 28, 2017 at 10:54:30AM -0700, Florian Fainelli wrote: > On 07/28/2017 07:44 AM, Corentin Labbe wrote: > > On Fri, Jul 28, 2017 at 04:36:00PM +0200, Andrew Lunn wrote: > >>>> I've probably asked this before: Does the internal PHY use a different >

Re: [PATCH 0/3] net-next: stmmac: support future possible different internal phy mode

2017-07-31 Thread Corentin Labbe
On Mon, Jul 31, 2017 at 08:19:40PM +0800, Chen-Yu Tsai wrote: > On Sat, Jul 29, 2017 at 2:48 PM, Corentin Labbe > wrote: > > On Fri, Jul 28, 2017 at 10:54:30AM -0700, Florian Fainelli wrote: > >> On 07/28/2017 07:44 AM, Corentin Labbe wrote: > >> > On Fri, Jul 28,

Re: [PATCH v3 01/11] net: phy: Add rockchip phy driver support

2017-08-01 Thread Corentin Labbe
+module_phy_driver(rockchip_phy_driver); > + > +static struct mdio_device_id __maybe_unused rockchip_phy_tbl[] = { > + { 0x1234d400, 0xfff0 }, Same comment for phy_id, use a define Regards Corentin Labbe

Re: [PATCH v3 05/11] net: stmmac: dwmac-rk: Add internal phy support

2017-08-09 Thread Corentin Labbe
On Thu, Aug 03, 2017 at 07:06:33PM +0800, Chen-Yu Tsai wrote: > On Thu, Aug 3, 2017 at 1:38 AM, Florian Fainelli wrote: > > On 08/01/2017 11:21 PM, David Wu wrote: > >> To make internal phy work, need to configure the phy_clock, > >> phy cru_reset and related registers. > >> > >> Signed-off-by: Da

[PATCH 1/3] Documentation: bindings: Add documentation for phy-is-integrated

2017-08-10 Thread Corentin Labbe
internal and external, the only way to detect the location of the PHY is via this property. Signed-off-by: Corentin Labbe --- Documentation/devicetree/bindings/net/phy.txt | 4 1 file changed, 4 insertions(+) diff --git a/Documentation/devicetree/bindings/net/phy.txt b/Documentation

[PATCH 3/3] net: stmmac: dwmac-sun8i: choose internal PHY via phy-is-integrated

2017-08-10 Thread Corentin Labbe
property. Since the internal_phy variable does not need anymore to contain the xMII mode used by the internal PHY, it is still used for knowing the presence of an internal PHY, so it is modified to a boolean soc_has_internal_phy. Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro

[PATCH 2/3] ARM: sun8i: sunxi-h3-h5: add phy-is-integrated property to internal PHY

2017-08-10 Thread Corentin Labbe
This patch add the new phy-is-integrated property to the internal PHY node. Signed-off-by: Corentin Labbe --- arch/arm/boot/dts/sunxi-h3-h5.dtsi | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/boot/dts/sunxi-h3-h5.dtsi b/arch/arm/boot/dts/sunxi-h3-h5.dtsi index 4b599b5d26f6

[PATCH 0/3] net: stmmac: Detect PHY location with phy-is-integrated

2017-08-10 Thread Corentin Labbe
-is-integrated DT property. The first and third patch should go via the net tree. the second via the sunxi tree. Thanks Regards Corentin Labbe (3): Documentation: bindings: Add documentation for phy-is-integrated ARM: sun8i: sunxi-h3-h5: add phy-is-integrated property to internal PHY net

Re: [PATCH 2/3] ARM: sun8i: sunxi-h3-h5: add phy-is-integrated property to internal PHY

2017-08-11 Thread Corentin Labbe
On Fri, Aug 11, 2017 at 10:42:51AM +0800, Chen-Yu Tsai wrote: > Hi, > > On Thu, Aug 10, 2017 at 4:51 PM, Corentin Labbe > wrote: > > This patch add the new phy-is-integrated property to the internal PHY > > node. > > > > Signed-off-by: Corentin Labbe > &

Re: [PATCH 2/3] ARM: sun8i: sunxi-h3-h5: add phy-is-integrated property to internal PHY

2017-08-11 Thread Corentin Labbe
On Fri, Aug 11, 2017 at 04:11:13PM +0800, Chen-Yu Tsai wrote: > On Fri, Aug 11, 2017 at 4:05 PM, Corentin Labbe > wrote: > > On Fri, Aug 11, 2017 at 10:42:51AM +0800, Chen-Yu Tsai wrote: > >> Hi, > >> > >> On Thu, Aug 10, 2017 at 4:51 PM, Corentin Labbe >

Re: [PATCH 2/3] ARM: sun8i: sunxi-h3-h5: add phy-is-integrated property to internal PHY

2017-08-11 Thread Corentin Labbe
On Fri, Aug 11, 2017 at 04:22:11PM +0800, Chen-Yu Tsai wrote: > On Fri, Aug 11, 2017 at 4:19 PM, Corentin Labbe > wrote: > > On Fri, Aug 11, 2017 at 04:11:13PM +0800, Chen-Yu Tsai wrote: > >> On Fri, Aug 11, 2017 at 4:05 PM, Corentin Labbe > >> wrote: > >&g

Re: [PATCH 2/3] ARM: sun8i: sunxi-h3-h5: add phy-is-integrated property to internal PHY

2017-08-11 Thread Corentin Labbe
On Fri, Aug 11, 2017 at 04:22:11PM +0800, Chen-Yu Tsai wrote: > On Fri, Aug 11, 2017 at 4:19 PM, Corentin Labbe > wrote: > > On Fri, Aug 11, 2017 at 04:11:13PM +0800, Chen-Yu Tsai wrote: > >> On Fri, Aug 11, 2017 at 4:05 PM, Corentin Labbe > >> wrote: > >&g

Re: [PATCH 0/5] net-next: ethernet: add sun8i-emac driver

2017-05-12 Thread Corentin Labbe
(1 year!). The best way to check for support of your board is linux-sunxi.org Anyway, I will update this week my github branch dwmac-sun8i branch with a DT patch for your board. If it works, contact me directly. Regards Corentin Labbe

[PATCH 2/2] net-next: stmmac: remove struct mac_link

2017-05-15 Thread Corentin Labbe
With the usage of adjust_link(), the struct mac_link is now useless. This patch remove it. Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/common.h | 7 --- drivers/net/ethernet/stmicro/stmmac/dwmac1000_core.c | 3 --- drivers/net/ethernet/stmicro/stmmac

[PATCH 1/2] net-next: stmmac: add adjust_link function

2017-05-15 Thread Corentin Labbe
of stmmac_adjust_link to it. Removing in the process stmmac_mac_flow_ctrl/stmmac_hw_fix_mac_speed since there not used anymore. Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/common.h | 3 + .../net/ethernet/stmicro/stmmac/dwmac1000_core.c | 54

Re: [PATCH 1/2] net-next: stmmac: add adjust_link function

2017-05-16 Thread Corentin Labbe
On Tue, May 16, 2017 at 09:43:04AM -0700, Florian Fainelli wrote: > On 05/15/2017 04:41 AM, Corentin Labbe wrote: > > My dwmac-sun8i serie will add some if (has_sun8i) to > > stmmac_adjust_link() > > Since the current stmmac_adjust_link() alreaady have lots of if > >

Re: [PATCH 1/2] net-next: stmmac: add adjust_link function

2017-05-17 Thread Corentin Labbe
On Tue, May 16, 2017 at 09:43:04AM -0700, Florian Fainelli wrote: > On 05/15/2017 04:41 AM, Corentin Labbe wrote: > > My dwmac-sun8i serie will add some if (has_sun8i) to > > stmmac_adjust_link() > > Since the current stmmac_adjust_link() alreaady have lots of if > >

[PATCH 1/4] net-next: stmmac: Convert new_state to bool

2017-05-19 Thread Corentin Labbe
This patch convert new_state from int to bool since it store only 1 or 0 Signed-off-by: Corentin Labbe --- 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

[PATCH 4/4] net-next: stmmac: rework the speed selection

2017-05-19 Thread Corentin Labbe
combined for writing speed. So this patch replace speed/port by simpler speed10/speed100/speed1000/speed_mask variables. In dwmac4_core_init and dwmac1000_core_init, port/speed value was used directly without using the struct link. This patch convert also their usage to speedxxx. Signed-off-by: Corentin

[PATCH 2/4] net-next: stmmac: Remove unnecessary parenthesis

2017-05-19 Thread Corentin Labbe
Signed-off-by: Corentin Labbe --- 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/stmicro/stmmac/stmmac_main.c index 2b778f63d1d5..e008cded388e 100644

[PATCH 0/4] net-next: stmmac: rework the speed selection

2017-05-19 Thread Corentin Labbe
Fainelli in my previous serie. The last patch is the real work. This serie is tested on cubieboard2 (dwmac1000) and opipc (dwmac-sun8i). Regards Corentin Labbe (4): net-next: stmmac: Convert new_state to bool net-next: stmmac: Remove unnecessary parenthesis net-next: stmmac: use SPEED_xxx

[PATCH 3/4] net-next: stmmac: use SPEED_xxx instead of raw value

2017-05-19 Thread Corentin Labbe
Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c index e008cded388e..a1ab52e29359

[PATCH v2 1/4] net-next: stmmac: Convert new_state to bool

2017-05-22 Thread Corentin Labbe
This patch convert new_state from int to bool since it store only 1 or 0 Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b

[PATCH v2 2/4] net-next: stmmac: Remove unnecessary parenthesis

2017-05-22 Thread Corentin Labbe
Signed-off-by: Corentin Labbe --- 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/stmicro/stmmac/stmmac_main.c index 94b37323844b..190686e39835 100644

[PATCH v2 4/4] net-next: stmmac: rework the speed selection

2017-05-22 Thread Corentin Labbe
combined for writing speed. So this patch replace speed/port by simpler speed10/speed100/speed1000/speed_mask variables. In dwmac4_core_init and dwmac1000_core_init, port/speed value was used directly without using the struct link. This patch convert also their usage to speedxxx. Signed-off-by: Corentin

[PATCH v2 0/4] net-next: stmmac: rework the speed selection

2017-05-22 Thread Corentin Labbe
Fainelli in my previous serie. The last patch is the real work. This serie is tested on cubieboard2 (dwmac1000) and opipc (dwmac-sun8i). Regards Changes since v2: - use true/false for new_state in patch #1 Corentin Labbe (4): net: stmmac: Convert new_state to bool net: stmmac: Remove

[PATCH v2 3/4] net-next: stmmac: use SPEED_xxx instead of raw value

2017-05-22 Thread Corentin Labbe
Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c index 190686e39835..9bf09100c199

Re: [PATCH v2 4/4] net-next: stmmac: rework the speed selection

2017-05-23 Thread Corentin Labbe
On Mon, May 22, 2017 at 02:49:44PM -0400, David Miller wrote: > From: Corentin Labbe > Date: Mon, 22 May 2017 14:33:47 +0200 > > > - mac->link.port = GMAC_CONTROL_PS; > > mac->link.duplex = GMAC_CONTROL_DM; > > - mac->link.speed = GMAC_CO

[PATCH v3 1/5] net-next: stmmac: Convert new_state to bool

2017-05-24 Thread Corentin Labbe
This patch convert new_state from int to bool since it store only 1 or 0 Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b

[PATCH v3 5/5] net-next: stmmac: rework the speed selection

2017-05-24 Thread Corentin Labbe
combined for writing speed. So this patch replace speed/port by simpler speed10/speed100/speed1000/speed_mask variables. In dwmac4_core_init and dwmac1000_core_init, port/speed value was used directly without using the struct link. This patch convert also their usage to speedxxx. Signed-off-by: Corentin

[PATCH v3 4/5] net-next: stmmac: Convert old_link to bool

2017-05-24 Thread Corentin Labbe
This patch convert old_link from int to bool since it store only 1 or 0 Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/stmmac.h | 2 +- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 8 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a

[PATCH v3 0/5] net-next: stmmac: rework the speed selection

2017-05-24 Thread Corentin Labbe
true/false for new_state in patch #1 Corentin Labbe (5): net: stmmac: Convert new_state to bool net: stmmac: Remove unnecessary parenthesis net: stmmac: use SPEED_xxx instead of raw value net: stmmac: Convert old_link to bool net: stmmac: rework the speed selection drivers/net/ethern

[PATCH v3 3/5] net-next: stmmac: use SPEED_xxx instead of raw value

2017-05-24 Thread Corentin Labbe
Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c index 1fb46c124ab1..5643a5c916b6

[PATCH v3 2/5] net-next: stmmac: Remove unnecessary parenthesis

2017-05-24 Thread Corentin Labbe
Signed-off-by: Corentin Labbe --- 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/stmicro/stmmac/stmmac_main.c index 9579592b6b6f..1fb46c124ab1 100644

[PATCH v6 10/21] arm: sun8i: orangepi-one: Enable dwmac-sun8i

2017-05-31 Thread Corentin Labbe
The dwmac-sun8i hardware is present on the Orange PI One. It uses the internal PHY. This patch create the needed emac node. Signed-off-by: Corentin Labbe --- arch/arm/boot/dts/sun8i-h3-orangepi-one.dts | 8 1 file changed, 8 insertions(+) diff --git a/arch/arm/boot/dts/sun8i-h3

[PATCH v6 21/21] arm64: defconfig: Enable dwmac-sun8i driver on defconfig

2017-05-31 Thread Corentin Labbe
Enable the dwmac-sun8i ethernet driver as a module in the ARM64 defconfig. Signed-off-by: Corentin Labbe --- arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig index 000de61802a1..fd7d22b8480c 100644 --- a

[PATCH v6 20/21] arm: multi_v7: Enable dwmac-sun8i driver on multi_v7_defconfig

2017-05-31 Thread Corentin Labbe
Enable the dwmac-sun8i driver in the multi_v7 default configuration Signed-off-by: Corentin Labbe --- arch/arm/configs/multi_v7_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/configs/multi_v7_defconfig b/arch/arm/configs/multi_v7_defconfig index 705d908e004a

[PATCH v6 17/21] arm64: allwinner: pine64-plus: Enable dwmac-sun8i

2017-05-31 Thread Corentin Labbe
The dwmac-sun8i hardware is present on the pine64 plus. It uses an external PHY rtl8211e via RGMII. Signed-off-by: Corentin Labbe --- .../arm64/boot/dts/allwinner/sun50i-a64-pine64-plus.dts | 17 - 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts

[PATCH v6 19/21] arm: sunxi: Enable dwmac-sun8i driver on sunxi_defconfig

2017-05-31 Thread Corentin Labbe
Enable the dwmac-sun8i driver in the sunxi default configuration Signed-off-by: Corentin Labbe --- arch/arm/configs/sunxi_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/configs/sunxi_defconfig b/arch/arm/configs/sunxi_defconfig index 5cd5dd70bc83..504e02238031 100644

[PATCH v6 13/21] arm: sun8i: nanopi-neo: Enable dwmac-sun8i

2017-05-31 Thread Corentin Labbe
The dwmac-sun8i hardware is present on the NanoPi Neo. It uses the internal PHY. This patch create the needed emac node. Signed-off-by: Corentin Labbe --- arch/arm/boot/dts/sun8i-h3-nanopi-neo.dts | 7 +++ 1 file changed, 7 insertions(+) diff --git a/arch/arm/boot/dts/sun8i-h3-nanopi

[PATCH v6 18/21] arm64: allwinner: bananapi-m64: Enable dwmac-sun8i

2017-05-31 Thread Corentin Labbe
The dwmac-sun8i hardware is present on the BananaPi M64. It uses an external PHY rtl8211e via RGMII. Signed-off-by: Corentin Labbe --- arch/arm64/boot/dts/allwinner/sun50i-a64-bananapi-m64.dts | 15 +++ 1 file changed, 15 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner

[PATCH v6 16/21] arm64: allwinner: pine64: Enable dwmac-sun8i

2017-05-31 Thread Corentin Labbe
The dwmac-sun8i hardware is present on the pine64 It uses an external PHY via RMII. Signed-off-by: Corentin Labbe --- arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts | 16 1 file changed, 16 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pine64.dts b

[PATCH v6 15/21] arm64: allwinner: sun50i-a64: add dwmac-sun8i Ethernet driver

2017-05-31 Thread Corentin Labbe
level. Signed-off-by: Corentin Labbe --- arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 35 +++ 1 file changed, 35 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi index 2eeba0d44074..7a07353ac1f6

[PATCH v6 12/21] arm: sun8i: orangepi-pc-plus: Set EMAC activity LEDs to active high

2017-05-31 Thread Corentin Labbe
On the Orange Pi PC Plus, the polarity of the LEDs on the RJ45 Ethernet port were changed from active low to active high. Signed-off-by: Chen-Yu Tsai Signed-off-by: Corentin Labbe --- arch/arm/boot/dts/sun8i-h3-orangepi-pc-plus.dts | 5 + 1 file changed, 5 insertions(+) diff --git a/arch

[PATCH v6 14/21] arm64: allwinner: sun50i-a64: Add dt node for the syscon control module

2017-05-31 Thread Corentin Labbe
This patch add the dt node for the syscon register present on the Allwinner A64. Only two register are present in this syscon and the only one useful is the one dedicated to EMAC clock. Signed-off-by: Corentin Labbe --- arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 6 ++ 1 file changed

[PATCH v6 11/21] arm: sun8i: orangepi-2: Enable dwmac-sun8i

2017-05-31 Thread Corentin Labbe
The dwmac-sun8i hardware is present on the Orange PI 2. It uses the internal PHY. This patch create the needed emac node. Signed-off-by: Corentin Labbe --- arch/arm/boot/dts/sun8i-h3-orangepi-2.dts | 8 1 file changed, 8 insertions(+) diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi

[PATCH v6 05/21] net-next: stmmac: Add dwmac-sun8i

2017-05-31 Thread Corentin Labbe
The dwmac-sun8i is a heavy hacked version of stmmac hardware by allwinner. In fact the only common part is the descriptor management and the first register function. Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/Kconfig| 11 + drivers/net/ethernet/stmicro/stmmac

<    1   2   3   4   5   >