Re: [PATCH v3 0/8] net: macb: add support for sama7g5

2020-12-17 Thread Nicolas Ferre
ilure dt-bindings: add documentation for sama7g5 ethernet interface dt-bindings: add documentation for sama7g5 gigabit ethernet interface net: macb: add support for sama7g5 gem interface net: macb: add support for sama7g5 emac interface For the whole series: Acked-by: Nicolas Ferre

Re: [PATCH] ethernet: select CONFIG_CRC32 as needed

2020-12-04 Thread Nicolas Ferre
-- drivers/net/ethernet/agere/Kconfig | 1 + drivers/net/ethernet/cadence/Kconfig| 1 + For Cadence macb driver: Acked-by: Nicolas Ferre drivers/net/ethernet/faraday/Kconfig| 1 + drivers/net/ethernet/freescale/Kconfig | 1 + drivers/net/ethernet/free

Re: [PATCH net v2] net: macb: Add default usrio config to default gem config

2021-01-12 Thread Nicolas Ferre
c63861db7 ("net: macb: Add default usrio config to default gem config") Signed-off-by: Atish Patra Indeed. Acked-by: Nicolas Ferre Thanks! Best regards, Nicolas --- Changes from v1->v2: 1. Fixed that fixes tag. --- drivers/net/ethernet/cadence/macb_main.c | 1 + 1 file c

Re: [PATCH] net: macb: fix NULL dereference due to no pcs_config method

2020-11-05 Thread Nicolas Ferre
not refer to it like this. Reported-by: Nicolas Ferre Link: https://lkml.org/lkml/2020/11/4/482 You might need to change this to a "lore" link: https://lore.kernel.org/netdev/2db854c7-9ffb-328a-f346-f68982723...@microchip.com/ Signed-off-by: Parshuram Thombare This fix looks a bi

Re: [PATCH] net: macb: fix NULL dereference due to no pcs_config method

2020-11-05 Thread Nicolas Ferre
On 05/11/2020 at 16:48, Russell King - ARM Linux admin wrote: On Thu, Nov 05, 2020 at 04:22:18PM +0100, Nicolas Ferre wrote: On 05/11/2020 at 15:37, Parshuram Thombare wrote: This patch fixes NULL pointer dereference due to NULL pcs_config in pcs_ops. Fixes: e4e143e26ce8 ("net: macb

Re: [RESEND PATCH] net: macb: fix NULL dereference due to no pcs_config method

2020-11-06 Thread Nicolas Ferre
On 05/11/2020 at 18:58, Parshuram Thombare wrote: This patch fixes NULL pointer dereference due to NULL pcs_config in pcs_ops. Reported-by: Nicolas Ferre Link: https://lore.kernel.org/netdev/2db854c7-9ffb-328a-f346-f68982723...@microchip.com/ Signed-off-by: Parshuram Thombare Acked-by

Re: [PATCH 1/1] net: macb: restore cmp registers on resume path

2021-04-02 Thread Nicolas Ferre
On 02/04/2021 at 14:42, Claudiu Beznea wrote: Restore CMP screener registers on resume path. Fixes: c1e85c6ce57ef ("net: macb: save/restore the remaining registers and features") Signed-off-by: Claudiu Beznea Acked-by: Nicolas Ferre Thanks for this fix Claudiu. Best regards,

Re: [PATCH] net: macb: simplify clk_init with dev_err_probe

2021-03-17 Thread Nicolas Ferre
and hide it for -EPROBE_DEFER. Signed-off-by: Michael Tretter Looks good to me: Acked-by: Nicolas Ferre Thanks Michael, regards, Nicolas --- drivers/net/ethernet/cadence/macb_main.c | 20 +--- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/drivers/net

Re: [PATCH v3 2/2] net: macb: Try to retrieve MAC addess from nvmem provider

2018-03-28 Thread Nicolas Ferre
: Nicolas Ferre --- drivers/net/ethernet/cadence/macb_main.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/cadence/macb_main.c b/drivers/net/ethernet/cadence/macb_main.c index e84afcf..eabe14f 100644 --- a/drivers/net/ethernet/cadence

Re: [RFC PATCH 0/2] net: macb: Disable TX checksum offloading on all Zynq

2018-06-04 Thread Nicolas Ferre
eird things with TX CSUM in the code 2/ the hw is unable to handle these particular cases. Best regards, Nicolas ``` Jennifer Dahm (1): net/macb: Disable TX checksum offloading on all Zynq-7000 drivers/net/ethernet/cadence/macb.h | 1 + drivers/net/ethernet/cadence/macb_main.c | 11 --- 2 files changed, 9 insertions(+), 3 deletions(-) -- Nicolas Ferre

Re: [RFC PATCH 2/2] net: macb: Disable TX checksum offloading on all Zynq

2018-06-04 Thread Nicolas Ferre
fig = { - .caps = MACB_CAPS_GIGABIT_MODE_AVAILABLE | MACB_CAPS_NO_GIGABIT_HALF, + .caps = MACB_CAPS_GIGABIT_MODE_AVAILABLE | MACB_CAPS_NO_GIGABIT_HALF + | MACB_CAPS_DISABLE_TX_HW_CSUM, .dma_burst_length = 16, .clk_init = macb_clk_init, .init = macb_init, -- Nico

Re: [RFC PATCH 1/2] net: macb: Add CAP to disable hardware TX checksum offloading

2018-06-04 Thread Nicolas Ferre
dev->hw_features |= NETIF_F_RXCSUM; + } if (bp->caps & MACB_CAPS_SG_DISABLED) dev->hw_features &= ~NETIF_F_SG; dev->features = dev->hw_features; -- Nicolas Ferre

Re: [PATCH net v1] net: macb: fix an issue about leak related system resources

2020-04-28 Thread Nicolas Ferre
vice *pdev) if (!res) return -ENODEV; - mgmt->reg = ioremap(res->start, resource_size(res)); + mgmt->reg = devm_ioremap(&pdev->dev, res->start, resource_size(res)); if (!mgmt->reg) return -ENOMEM; -- Nicolas Ferre

Re: [PATCH net] net: macb: fix for pause frame receive enable bit

2020-09-07 Thread Nicolas Ferre
On 05/09/2020 at 10:21, Parshuram Thombare wrote: PAE bit of NCFGR register, when set, pauses transmission if a non-zero 802.3 classic pause frame is received. Fixes: 7897b071ac3b ("net: macb: convert to phylink") Signed-off-by: Parshuram Thombare For the record: Acked-by: Nic

[PATCH 4/8] net/macb: bindings doc/trivial: fix documentation for sama5d3 10/100 interface

2019-01-16 Thread Nicolas Ferre
This removes a line left while adding the correct compatibility string for sama5d3 10/100 interface. Now use the "atmel,sama5d3-macb" string. Signed-off-by: Nicolas Ferre --- Documentation/devicetree/bindings/net/macb.txt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) di

[PATCH 2/8] dt-bindings: arm: atmel: add new sam9x60 reset controller binding

2019-01-16 Thread Nicolas Ferre
Update the Reset Controller's binding to add new SoC compatibility string. Signed-off-by: Nicolas Ferre --- Documentation/devicetree/bindings/arm/atmel-sysregs.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/arm/atmel-sysregs.txt b/Document

[PATCH 5/8] net/macb: bindings doc: add sam9x60 binding

2019-01-16 Thread Nicolas Ferre
Add the compatibility sting documentation for sam9x60 10/100 interface. Signed-off-by: Nicolas Ferre --- Documentation/devicetree/bindings/net/macb.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/net/macb.txt b/Documentation/devicetree/bindings/net

[PATCH 6/8] power: reset: at91-reset: add support for sam9x60 SoC

2019-01-16 Thread Nicolas Ferre
Add support for additional reset causes and the proper compatibility string for sam9x60 SoC. The restart function is the same as the samx7. Signed-off-by: Nicolas Ferre --- drivers/power/reset/at91-reset.c | 13 + 1 file changed, 13 insertions(+) diff --git a/drivers/power/reset

[PATCH 8/8] net: macb: add sam9x60-macb compatibility string

2019-01-16 Thread Nicolas Ferre
Add a new compatibility string for this product. It's using at91sam9260-macb layout but has a newer hardware revision: it's safer to use its own string. Signed-off-by: Nicolas Ferre --- drivers/net/ethernet/cadence/macb_main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/d

[PATCH 7/8] USB: host: ohci-at91: add sam9x60-sfr definition for ohci

2019-01-16 Thread Nicolas Ferre
Add this SFR compatible definition for the sam9x60 SoC and manage its use in ohci-at91.c driver. Signed-off-by: Nicolas Ferre --- drivers/usb/host/ohci-at91.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/usb/host/ohci-at91.c b/drivers/usb/host/ohci-at91.c

[PATCH 0/8] ARM: at91/dt: update to existing drivers for the sam9x60 SoC

2019-01-16 Thread Nicolas Ferre
: sounds okay to everyone? If okay, I'm ready to collect Ack tags... For the first batch, I send the whole series to everyone. I'll try my best to reduce subsequent message deliveries if one part of the serries needs rework. Best regards, Nicolas Nicolas Ferre (8): dt-bindings:

[PATCH 1/8] dt-bindings: arm: atmel: add missing samx7 to reset controller

2019-01-16 Thread Nicolas Ferre
Add this missing compatibility string to the Reset Controller compatible string chip list. Signed-off-by: Nicolas Ferre --- Documentation/devicetree/bindings/arm/atmel-sysregs.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/arm/atmel

[PATCH 3/8] dt-bindings: arm: atmel: add new sam9x60 SFR binding

2019-01-16 Thread Nicolas Ferre
Add this SFR compatible definition for the sam9x60 SoC. Will be needed in OHCI driver: ohci-at91.c. Signed-off-by: Nicolas Ferre --- Documentation/devicetree/bindings/arm/atmel-sysregs.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/arm/atmel

[PATCH v2 2/3] net/macb: bindings doc: add sam9x60 binding

2019-02-06 Thread Nicolas Ferre
Add the compatibility sting documentation for sam9x60 10/100 interface. Signed-off-by: Nicolas Ferre --- Hi Rob, Your tag is missing for this patch. Documentation/devicetree/bindings/net/macb.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/net

[PATCH v2 3/3] net: macb: add sam9x60-macb compatibility string

2019-02-06 Thread Nicolas Ferre
Add a new compatibility string for this product. It's using at91sam9260-macb layout but has a newer hardware revision: it's safer to use its own string. Signed-off-by: Nicolas Ferre --- v2: applies on top of next-20190206 drivers/net/ethernet/cadence/macb_main.c | 1 + 1 file

[PATCH v2 1/3] net/macb: bindings doc/trivial: fix documentation for sama5d3 10/100 interface

2019-02-06 Thread Nicolas Ferre
This removes a line left while adding the correct compatibility string for sama5d3 10/100 interface. Now use the "atmel,sama5d3-macb" string. Signed-off-by: Nicolas Ferre Reviewed-by: Rob Herring --- Documentation/devicetree/bindings/net/macb.txt | 3 +-- 1 file changed, 1 inser

Re: [PATCH v4 3/5] net: macb: fix macb_get/set_wol() when moving to phylink

2020-05-13 Thread Nicolas Ferre
Russell, Thanks for the feedback. On 13/05/2020 at 15:05, Russell King - ARM Linux admin wrote: On Wed, May 06, 2020 at 01:37:39PM +0200, nicolas.fe...@microchip.com wrote: From: Nicolas Ferre Keep previous function goals and integrate phylink actions to them. phylink_ethtool_get_wol() is

Re: [PATCH v4 1/5] net: macb: fix wakeup test in runtime suspend/resume routines

2020-05-25 Thread Nicolas Ferre
On 07/05/2020 at 12:03, Nicolas Ferre wrote: On 06/05/2020 at 22:18, Jakub Kicinski wrote: EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe On Wed, 6 May 2020 13:37:37 +0200 nicolas.fe...@microchip.com wrote: From: Nicolas Ferre Use the proper

Re: [PATCH net v2] net: macb: fix an issue about leak related system resources

2020-04-29 Thread Nicolas Ferre
remap_resource(pdev, 1); if (!mgmt->reg) Is your test valid then? Please use: if (IS_ERR(base)) return PTR_ERR(base); As advised by: lib/devres.c:156 Regards, Nicolas return -ENOMEM; -- 2.25.0 -- Nicolas Ferre

Re: [PATCH v4 1/5] net: macb: fix wakeup test in runtime suspend/resume routines

2020-05-07 Thread Nicolas Ferre
On 06/05/2020 at 22:18, Jakub Kicinski wrote: EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe On Wed, 6 May 2020 13:37:37 +0200 nicolas.fe...@microchip.com wrote: From: Nicolas Ferre Use the proper struct device pointer to check if the wakeup flag

Re: [PATCH net-next v2 0/4] net: macb: few code cleanups

2020-07-02 Thread Nicolas Ferre
hweight32() to count set bits in queue_mask net: macb: do not initialize queue variable net: macb: remove is_udp variable drivers/net/ethernet/cadence/macb_main.c | 19 +-- 1 file changed, 5 insertions(+), 14 deletions(-) You can add my: Acked-by: Nicolas Ferre For the whole

Re: [PATCH] Replace HTTP links with HTTPS ones: ATMEL MACB ETHERNET DRIVER

2020-07-08 Thread Nicolas Ferre
K and serve the same content: Replace HTTP with HTTPS. Signed-off-by: Alexander A. Klimov The links go to Cadence. If people from Cadence want to change something, don't hesitate to speak out. On my side: Acked-by: Nicolas Ferre --- Continuing my work started at 93431e060

Re: [PATCH] net: macb: reject unsupported rgmii delays

2020-06-17 Thread Nicolas Ferre
return -EINVAL; + } + Otherwise, it looks good to me after reading the associated discussion link in your commit message: thanks for that! Acked-by: Nicolas Ferre if (dn) ret = phylink_of_phy_connect(bp->phylink, dn, 0); -- 2.20.1 -- Nicolas Ferre

Re: [PATCH] net: macb: undo operations in case of failure

2020-06-17 Thread Nicolas Ferre
It must be: Fixes: 7897b071ac3b ("net: macb: convert to phylink") -- Nicolas Ferre

Re: [PATCH v2] net: macb: undo operations in case of failure

2020-06-18 Thread Nicolas Ferre
diu Beznea Acked-by: Nicolas Ferre Thanks Claudiu. Regards, Nicolas --- Changes in v2: - corrected fixes SHA1 drivers/net/ethernet/cadence/macb_main.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/cadence/macb_main.c b/drivers/net/ethern

Re: [PATCH v2] net: macb: add fixed-link node support

2017-11-06 Thread Nicolas Ferre
lse { > for (i = 0; i < PHY_MAX_ADDR; i++) > @@ -3438,6 +3457,7 @@ static int macb_remove(struct platform_device *pdev) > clk_disable_unprepare(bp->hclk); > clk_disable_unprepare(bp->pclk); > clk_disable_unprepare(bp->rx_clk); > + of_node_put(bp->phy_node); > free_netdev(dev); > } > > diff --git a/drivers/net/ethernet/cadence/macb.h > b/drivers/net/ethernet/cadence/macb.h > index ec037b0fa2a4d..2510661102bad 100644 > --- a/drivers/net/ethernet/cadence/macb.h > +++ b/drivers/net/ethernet/cadence/macb.h > @@ -930,6 +930,7 @@ struct macb { > struct macb_or_gem_ops macbgem_ops; > > struct mii_bus *mii_bus; > + struct device_node *phy_node; > int link; > int speed; > int duplex; > -- Nicolas Ferre

Re: [PATCH 1/2] net: macb: add of_phy_deregister_fixed_link to error paths

2017-11-06 Thread Nicolas Ferre
On 06/11/2017 at 12:10, Michael Grzeschik wrote: > We add the call of_phy_deregister_fixed_link to all associated > error paths for memory clean up. > > Signed-off-by: Michael Grzeschik Acked-by: Nicolas Ferre Thanks a lot for your quick answer! Best regards, Nicolas > ---

Re: [PATCH 2/2] net: macb: add of_node_put to error paths

2017-11-07 Thread Nicolas Ferre
ect(dev->phydev); > mdiobus_unregister(bp->mii_bus); > + of_node_put(bp->phy_node); Isn't this call already done some lines below, just before "free_netdev(dev);"? > if ((np) && (of_phy_is_fixed_link(np))) > of_phy_deregister_fixed_link(np); > dev->phydev = NULL; > Thanks for your patch. Regards, -- Nicolas Ferre

Re: [PATCH v2] net: macb: add of_node_put to error paths

2017-11-07 Thread Nicolas Ferre
On 07/11/2017 at 10:59, Michael Grzeschik wrote: > We add the call of_node_put(bp->phy_node) to all associated error > paths for memory clean up. > > Signed-off-by: Michael Grzeschik Thanks for your quick update: Acked-by: Nicolas Ferre Best regards, Nicolas > --- &

Re: [PATCH v2 1/2] net: macb: add of_phy_deregister_fixed_link to error paths

2017-11-08 Thread Nicolas Ferre
On 08/11/2017 at 09:56, Michael Grzeschik wrote: > We add the call of_phy_deregister_fixed_link to all associated > error paths for memory clean up. > > Signed-off-by: Michael Grzeschik Acked-by: Nicolas Ferre > --- > v2: removed extra parenthesis > > drivers/net/ethe

Re: [PATCH v2 2/2] net: macb: add of_node_put to error paths

2017-11-08 Thread Nicolas Ferre
On 08/11/2017 at 09:56, Michael Grzeschik wrote: > We add the call of_node_put(bp->phy_node) to all associated error > paths for memory clean up. > > Signed-off-by: Michael Grzeschik Acked-by: Nicolas Ferre > --- > v2: removed extra of_node_put from macb_remove >

Re: [PATCH] net: macb: add fixed-link node support

2017-06-19 Thread Nicolas Ferre
> struct macb_or_gem_ops macbgem_ops; > - Nit: no need to remove the empty line. > + struct device_node *phy_node; > struct mii_bus *mii_bus; > int link; > int speed; > Thanks for your patch. Best regards, -- Nicolas Ferre

Re: [PATCH][-next] net: macb: remove extraneous return when MACB_EXT_DESC is defined

2017-07-05 Thread Nicolas Ferre
ead code") > > Signed-off-by: Colin Ian King Acked-by: Nicolas Ferre > --- > drivers/net/ethernet/cadence/macb_main.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/drivers/net/ethernet/cadence/macb_main.c > b/drivers/net/ethernet/cadence/macb_main.c &g

[PATCH] net: macb: Adding Support for Jumbo Frames up to 10240 Bytes in SAMA5D3

2017-07-05 Thread Nicolas Ferre
value greater than 1500, it threw error: sudo ifconfig eth1 mtu 9000 SIOCSIFMTU: Invalid argument Add this support to driver so that it works as expected and designed. Signed-off-by: vishnuvardhan [nicolas.fe...@microchip.com: modify slightly commit msg] Signed-off-by: Nicolas Ferre

Re: [PATCH 1/2] net: macb: reduce scope of rx_fs_lock-protected regions

2017-12-05 Thread Nicolas Ferre
nerated patch fixes the problem, the right > solution is to obviate the problem altogether. > > Thanks, >The Other Julia Julia, Thanks for your patch, it seems good indeed. Here is my: Acked-by: Nicolas Ferre As the patch by Julia L. is already in net-next, I suspect that you would ne

Re: [PATCH 2/2] net: macb: kill useless use of list_empty()

2017-12-05 Thread Nicolas Ferre
ff-by: Julia Cartwright > --- > This is an additional cleanup patch found when looking at this code. > >Julia Acked-by: Nicolas Ferre Thanks > > drivers/net/ethernet/cadence/macb_main.c | 34 > > 1 file changed, 13 insertions(+)

Re: [PATCH v2 1/3] net: macb: Document zynq gem dt binding

2015-05-22 Thread Nicolas Ferre
Le 22/05/2015 16:22, Nathan Sullivan a écrit : > Signed-off-by: Nathan Sullivan Acked-by: Nicolas Ferre > --- > Documentation/devicetree/bindings/net/cdns-emac.txt |3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/Documentation/devicetree

Re: [PATCH v2 2/3] net: macb: Disable half duplex gigabit on Zynq

2015-05-22 Thread Nicolas Ferre
Le 22/05/2015 16:22, Nathan Sullivan a écrit : > According to the Zynq TRM, gigabit half duplex is not supported. Add a > new cap and compatible string so Zynq can avoid advertising that mode. > > Signed-off-by: Nathan Sullivan Acked-by: Nicolas Ferre > --- > drivers/ne

[PATCH] ARM: dts: at91: VInCo: fix phy reset gpio flag

2016-04-26 Thread Nicolas Ferre
Fix gpio active flag for the phy reset-gpios property. The line is active low instead of active high. Actually, this flags was never used by the macb driver. Reported-by: Sergei Shtylyov Cc: Andrew Lunn Cc: David Miller Signed-off-by: Nicolas Ferre --- Hi, Thanks for having reported this bug

Re: [PATCH] ARM: dts: at91: VInCo: fix phy reset gpio flag

2016-04-27 Thread Nicolas Ferre
e and basically maintaining this DT file, I think that I'll be informed if people try an unlikely arrangement of patches on this board. So either way, I'm okay. But I do think it's not worth thinking too much about this case. Bye, -- Nicolas Ferre

Re: [PATCH v2] net: macb: do not scan PHYs manually

2016-04-28 Thread Nicolas Ferre
if (IS_ERR(phydev)) { > - err = PTR_ERR(phydev); > - break; > - } > - } > - > - if (err) > - goto err_out_unregister_bus; > - } > } else { > if (pdata) > bp->mii_bus->phy_mask = pdata->phy_mask; > -- Nicolas Ferre

Re: [PATCH RFT v2 2/2] macb: kill PHY reset code

2016-04-29 Thread Nicolas Ferre
Le 29/04/2016 00:15, Sergei Shtylyov a écrit : > With the 'phylib' now being aware of the "reset-gpios" PHY node property, > there should be no need to frob the PHY reset in this driver anymore... > > Signed-off-by: Sergei Shtylyov Acked-by: Nicolas Ferre

Re: [PATCH v2] net: macb: do not scan PHYs manually

2016-04-29 Thread Nicolas Ferre
struct macb *bp) > dev_set_drvdata(&bp->dev->dev, bp->mii_bus); > > np = bp->pdev->dev.of_node; > - if (np) { > - /* try dt phy registration */ > - err = of_mdiobus_register(bp->mii_bus, np); > - > - /* fallback to standard phy registration if no phy were > - * found during dt phy registration > - */ > - if (!err && !phy_find_first(bp->mii_bus)) { > - for (i = 0; i < PHY_MAX_ADDR; i++) { > - struct phy_device *phydev; > - > - phydev = mdiobus_scan(bp->mii_bus, i); > - if (IS_ERR(phydev)) { > - err = PTR_ERR(phydev); > - break; > - } > - } > - > - if (err) > - goto err_out_unregister_bus; > - } > - } else { > - if (pdata) > - bp->mii_bus->phy_mask = pdata->phy_mask; > - > - err = mdiobus_register(bp->mii_bus); > - } > + if (np) > + err = macb_mii_of_init(bp, np); > + else > + err = macb_mii_pdata_init(bp, pdata); > > if (err) > goto err_out_free_mdiobus; I'm okay with this. Thanks for having taken the initiative to implement it. Bye, -- Nicolas Ferre

Re: [PATCH] macb: fix mdiobus_scan() error check

2016-05-02 Thread Nicolas Ferre
b: don't return NULL from get_phy_device()") > Signed-off-by: Sergei Shtylyov Acked-by: Nicolas Ferre Thanks. > > --- > The patch is against DaveM's 'net-next.git' repo. > > drivers/net/ethernet/cadence/macb.c |3 ++- > 1 file changed, 2 inse

Re: [PATCH net] net: macb: Probe MDIO bus before registering netdev

2016-05-03 Thread Nicolas Ferre
this follow-up and the advices you had given to Alexandre during the debug session when you spotted this problem. Acked-by: Nicolas Ferre > --- > Tracking down the exact commit which started doing that was a little > difficult, so I can't really provide a proper Fixes tag yet that d

Re: [PATCH 7/9] net: macb: avoid uninitialized variables

2016-01-27 Thread Nicolas Ferre
clk *pclk, *hclk, *tx_clk; > ^ > > This shuts up the misleading warnings by ensuring that the > macb_clk_init() always stores something into all three pointers. > > Signed-off-by: Arnd Bergmann Okay Arnd, thanks! Acked-by: Nicolas Ferre > --- > driver

Re: [PATCH 7/9] net: macb: avoid uninitialized variables

2016-01-27 Thread Nicolas Ferre
Le 27/01/2016 16:51, Nicolas Ferre a écrit : > Le 27/01/2016 15:04, Arnd Bergmann a écrit : >> The macb_clk_init function returns three clock pointers, unless >> the it fails to get the first ones. We correctly handle the >> failure case by propagating the error from macb_p

Re: [PATCH 0/3] net: macb: Fix coding style issues

2016-03-07 Thread Nicolas Ferre
ischer (3): > net: macb: Fix coding style error message > net: macb: Fix more coding style issues > net: macb: Address checkpatch 'check' suggestions > > drivers/net/ethernet/cadence/macb.c | 157 > ++++---- > 1 file changed, 71 insertions(+), 86 deletions(-) > -- Nicolas Ferre

[PATCH] net: macb: fix default configuration for GMAC on AT91

2016-03-10 Thread Nicolas Ferre
terface (GMII or MII). Reported-by: Romain HENRIET Signed-off-by: Nicolas Ferre --- drivers/net/ethernet/cadence/macb.c | 13 +++-- drivers/net/ethernet/cadence/macb.h | 2 +- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/drivers/net/ethernet/cadence/macb.c b/drivers/net/eth

Re: [PATCH 0/5] net: macb: Checkpatch cleanups

2016-03-18 Thread Nicolas Ferre
ding style error message > net: macb: Fix coding style warnings > net: macb: Address checkpatch 'check' suggestions > net: macb: Use ether_addr_copy over memcpy > net: macb: Fix simple typo. > > drivers/net/ethernet/cadence/macb.c | 153 > +++++--- > 1 file changed, 70 insertions(+), 83 deletions(-) > -- Nicolas Ferre

Re: [PATCH 5/5] net: macb: Fix simple typo.

2016-03-19 Thread Nicolas Ferre
> * descriptor access. >> */ >> static bool hw_is_native_io(void __iomem *addr) >> > > Remove dot at the end of subject and feel free to add my: > Acked-by: Michal Simek Yes, same for me, no dot. But anyway, here is my: Acked-by: Nicolas Ferre Thanks Moritz for the patches and Michal for the reviews. Bye, -- Nicolas Ferre

Re: [PATCH 3/5] net: macb: Address checkpatch 'check' suggestions

2016-03-19 Thread Nicolas Ferre
Le 13/03/2016 20:10, Moritz Fischer a écrit : > This commit deals with a bunch of checkpatch suggestions > that without changing behavior make checkpatch happier. > > Signed-off-by: Moritz Fischer Acked-by: Nicolas Ferre > --- > drivers/net/ethernet/c

Re: [PATCH 4/5] net: macb: Use ether_addr_copy over memcpy

2016-03-19 Thread Nicolas Ferre
Le 13/03/2016 20:10, Moritz Fischer a écrit : > Checkpatch suggests using ether_addr_copy over memcpy > to copy the mac address. > > Signed-off-by: Moritz Fischer Yes: Acked-by: Nicolas Ferre > --- > drivers/net/ethernet/cadence/macb.c | 2 +- > 1 file changed, 1 ins

Re: [PATCH 1/5] net: macb: Fix coding style error message

2016-03-19 Thread Nicolas Ferre
Le 13/03/2016 20:10, Moritz Fischer a écrit : > checkpatch.pl gave the following error: > > ERROR: space required before the open parenthesis '(' > + for(; p < end; p++, offset += 4) > > Signed-off-by: Moritz Fischer Acked-by: Nicolas Ferre > --- >

Re: [PATCH 2/5] net: macb: Fix coding style warnings

2016-03-19 Thread Nicolas Ferre
function comments, to do it in a separate patch (series). > Also splitting this to more patches will be better. Just by categories > but that's just my opinion. Well, yes... but I won't be too picky for such a patch. So here is my: Acked-by: Nicolas Ferre Thank for your feedback, bye, -- Nicolas Ferre

Re: [PATCH] macb: fix PHY reset

2016-03-23 Thread Nicolas Ferre
et in >>> >>> s/wouldn't/may not/, sorry. Do I need to resend? >> >> No need, I fixed it up by hand. >> >> Applied, thanks. > > Oops, forgot another tag: > > Fixes: 270c499f0993 ("net/macb: Update device tree binding for resetting PHY > using GPIO") > >Too late probably... :-( Too late also: Acked-by: Nicolas Ferre Thanks Sergei! Bye, -- Nicolas Ferre

Re: [PATCH 1/1] net: macb: replace macb_writel() call by queue_writel() to update queue ISR

2016-03-24 Thread Nicolas Ferre
nterrupt Disable Register > IMR: Interrupt Mask Register > > Signed-off-by: Cyrille Pitchen > Fixes: bfbb92c44670 ("net: macb: Handle the RXUBR interrupt on all devices") Acked-by: Nicolas Ferre Thanks! > --- > drivers/net/ethernet/cadence/macb.c | 2 +- > 1

Re: [PATCH 1/1] net: macb: remove BUG_ON() and reset the queue to handle RX errors

2016-03-24 Thread Nicolas Ferre
standing for a long time in my backlog ;-). Acked-by: Nicolas Ferre Bye, > --- > drivers/net/ethernet/cadence/macb.c | 59 > ++--- > 1 file changed, 49 insertions(+), 10 deletions(-) > > diff --git a/drivers/net/ethernet/cadence/macb.c >

Re: [PATCH RFT 2/2] macb: kill PHY reset code

2016-04-12 Thread Nicolas Ferre
to it seems correct to me (I mean, with proper flag specification). > property, i.e. active low. The new code in the previous patch does > however take the flags into account. Did you check if there are any > device trees which have flags, which were never used, but are now > going to be used and thus break... Flag was used and you are saying that it's taken into account in new code... So, what's the issue? I see a difference in the way the "value" of gpiod_* functions is used. There may be a misunderstanding here... Bye, -- Nicolas Ferre

Re: [PATCH RFT 2/2] macb: kill PHY reset code

2016-04-12 Thread Nicolas Ferre
ut currently works. > >>> You potentially need to add a new property and deprecate the old one. >> >>I would like to avoid that... > > You will need the agreement from the at91-vinco maintainer. If the at91-vinco has to be modified, you have my agreement that it can be modified. Bye, -- Nicolas Ferre

Re: GMII2RGMII Converter support in macb driver

2016-04-12 Thread Nicolas Ferre
acb_reset_phy(pdev); > >/* IP specific init */ > > @@ -3422,6 +3460,8 @@ static int macb_remove(struct platform_device *pdev) > > bp = netdev_priv(dev); > > if (bp->phy_dev) > >

Re: [PATCH RFT 2/2] macb: kill PHY reset code

2016-04-12 Thread Nicolas Ferre
Le 12/04/2016 15:40, Andrew Lunn a écrit : > On Tue, Apr 12, 2016 at 11:22:10AM +0200, Nicolas Ferre wrote: >> Le 11/04/2016 04:28, Andrew Lunn a écrit : >>> On Sat, Apr 09, 2016 at 01:25:03AM +0300, Sergei Shtylyov wrote: >>>> With the 'phylib' now be

Re: [PATCH RFT 2/2] macb: kill PHY reset code

2016-04-12 Thread Nicolas Ferre
Le 12/04/2016 15:54, Sergei Shtylyov a écrit : > Hello. > > On 4/12/2016 12:22 PM, Nicolas Ferre wrote: > >>>> With the 'phylib' now being aware of the "reset-gpios" PHY node >>>> property, >>>> there should be no need to f

Re: [RFC PATCH 2/2] net: macb: Add gmii2rgmii phy converter support

2016-07-01 Thread Nicolas Ferre
ef _MACB_H > #define _MACB_H > > +#include No, put it in the macb.c. > + > #define MACB_GREGS_NBR 16 > #define MACB_GREGS_VERSION 2 > #define MACB_MAX_QUEUES 8 > @@ -846,6 +848,7 @@ struct macb { > unsigned intjumbo_max_len; > > u32 wol; > + struct gmii2rgmii converter_phy; > }; > > static inline bool macb_is_gem(struct macb *bp) If Florian and phy guys are okay with the approach, I'm fine with this patch, once corrected. Thanks, bye, -- Nicolas Ferre

Re: [RFC PATCH 2/2] net: macb: Add gmii2rgmii phy converter support

2016-07-01 Thread Nicolas Ferre
Le 01/07/2016 11:02, Appana Durga Kedareswara Rao a écrit : > Hi Nicolas Ferre, > > Thanks for the quick review... > >> >> Le 01/07/2016 08:20, Kedareswara rao Appana a écrit : >>> This patch adds support for gmii2rgmii phy converter in the macb >

Re: [RFC PATCH v2 2/4] net: ethernet: xilinx: Add gmii2rgmii converter support

2016-07-04 Thread Nicolas Ferre
struct phy_device *gmii2rgmii_phy_dev; > + void *platform_data; > + int (*mdio_write)(struct mii_bus *bus, int mii_id, int reg, > + u16 val); > + void (*fix_mac_speed)(struct gmii2rgmii *xphy, unsigned int speed); > +}; > + > +extern int gmii2rgmii_phyprobe(struct gmii2rgmii *xphy); > +#endif I see a compilation issue here: You should provide a way to have this function even if the NET_VENDOR_XILINX config option is not selected (test to compile with the sama5_defconfig and you'll see). What about making this function void in case of !XILINX? (so, NACK for the series as it is). Bye, -- Nicolas Ferre

Re: [RFC PATCH v2 2/4] net: ethernet: xilinx: Add gmii2rgmii converter support

2016-07-04 Thread Nicolas Ferre
fig check around phyprobe api in the macb driver. > #ifdef CONFIG_XILINX_GMII2RGMII >gmii2rgmii_phyprobe(&bp->converter_phy); > #endif Nope! > 2) Select NET_VENDOR_XILINX in the macb Kconfig > @ -22,6 +22,7 @@ config MACB > tristate "Cadence MACB/GEM support" > depends on HAS_DMA > select PHYLIB > + select NET_VENDOR_XILINX > Please let me know which one you prefer will fix that and will post v3... First one with my changes is the best. But maybe wait for more feedback... Bye, -- Nicolas Ferre

Re: [PATCH] net/macb: add proper header file

2015-12-17 Thread Nicolas Ferre
100644 > --- a/drivers/net/ethernet/cadence/macb.c > +++ b/drivers/net/ethernet/cadence/macb.c > @@ -19,6 +19,7 @@ > #include > #include > #include > +#include > #include > #include > #include > -- Nicolas Ferre -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH v3 net-next] net: ethernet: cadence-macb: Add disabled usrio caps

2016-01-04 Thread Nicolas Ferre
cadence/macb.h > b/drivers/net/ethernet/cadence/macb.h > index 5c03e81..0d4ecfc 100644 > --- a/drivers/net/ethernet/cadence/macb.h > +++ b/drivers/net/ethernet/cadence/macb.h > @@ -400,6 +400,7 @@ > #define MACB_CAPS_USRIO_HAS_CLKEN0x0002 > #define MACB_CAPS_USRIO_DEFA

Re: [PATCH v4 net-next 2/3] net: macb: Add NPx macb config using USRIO_DISABLED cap

2016-01-04 Thread Nicolas Ferre
at has this configuration and you'll be able to make the NP(x+1) compatible with it. It has proven to be much more future proof and even if in the early days of DT on ARM we accepted some binding with generic strings like this one below, It has proven to be a mistake. > { .co

Re: [PATCH v4 net-next 2/3] net: macb: Add NPx macb config using USRIO_DISABLED cap

2016-01-05 Thread Nicolas Ferre
Le 05/01/2016 13:20, Neil Armstrong a écrit : > On 01/04/2016 11:38 AM, Nicolas Ferre wrote: >> Le 04/01/2016 10:42, Neil Armstrong a écrit : >>> static const struct macb_config zynqmp_config = { >>> .caps = MACB_CAPS_GIGABIT_MODE_AVAILABLE | MACB_CAPS_JUMBO, >&

Re: [PATCH v5 net-next 1/3] net: ethernet: cadence-macb: Add disabled usrio caps

2016-01-05 Thread Nicolas Ferre
to the USRIO > register can trigger some Imprecise External Aborts on ARM platforms. > > Signed-off-by: Neil Armstrong Acked-by: Nicolas Ferre Thanks! > --- > drivers/net/ethernet/cadence/macb.c | 27 +++ > drivers/net/ethernet/cadence/macb.h | 1 + >

Re: [PATCH v5 net-next 2/3] net: macb: Add NP4 macb config using USRIO_DISABLED

2016-01-05 Thread Nicolas Ferre
Le 05/01/2016 14:39, Neil Armstrong a écrit : > Declare a new NP4 SoC variant having USRIO_DISABLED as capability bit. > > Signed-off-by: Neil Armstrong Acked-by: Nicolas Ferre > --- > drivers/net/ethernet/cadence/macb.c | 6 ++ > 1 file changed, 6 insertions(+)

Re: [PATCH v5 net-next 3/3] dt-bindings: net: macb: Add NP4 macb variant

2016-01-05 Thread Nicolas Ferre
Le 05/01/2016 14:39, Neil Armstrong a écrit : > Add NP4 macb SoC variant. > > Signed-off-by: Neil Armstrong Acked-by: Nicolas Ferre Neil, thanks for your understanding and reactivity concerning this patch series. Bye, > --- > Documentation/devicetree/bindings/net/macb.txt

Re: [PATCH 2/3] net: macb: fix build warning

2016-01-25 Thread Nicolas Ferre
they are not used uninitialized as clk_init() will initialize > them, this patch will just silence the warning. > > Signed-off-by: Sudip Mukherjee Acked-by: Nicolas Ferre Thanks for your patch. Bye, > --- > drivers/net/ethernet/cadence/macb.c | 2 +- > 1 file changed, 1 inse

Re: [PATCH net-next 05/14] net: macb: Use net_device_stats from struct net_device

2017-04-07 Thread Nicolas Ferre
ch was left as a legacy, use rtnl_link_stats64 instead Is it still permitted to use it? Would it be to directly move to the most up-to-date code? Regards, > Cc: Nicolas Ferre > Signed-off-by: Tobias Klauser > --- > drivers/net/ethernet/c

Re: [PATCH net-next v2] macb: Common code to enable ptp support for MACB/GEM

2017-01-25 Thread Nicolas Ferre
Le 19/01/2017 à 17:07, Nicolas Ferre a écrit : > Le 19/01/2017 à 08:56, Andrei Pistirica a écrit : >> This patch does the following: >> - MACB/GEM-PTP interface >> - registers and bitfields for TSU >> - capability flags to enable PTP per platform basis >> &

Re: [PATCH net-next v2] macb: Common code to enable ptp support for MACB/GEM

2017-01-27 Thread Nicolas Ferre
and whether the PTP support was adequate. > I think the capability approach gives better control and > it is not really much to add. Yes, absolutely. In fact we already had this discussion and decided that this capability scheme was giving much more control at low cost. Regards, -- Nicolas Ferre

Re: [PATCH net-next v2] macb: Common code to enable ptp support for MACB/GEM

2017-01-27 Thread Nicolas Ferre
tive of the SoC capability >> and whether the PTP support was adequate. >> I think the capability approach gives better control and >> it is not really much to add. >> >> Regards, >> Harini >> > Yes, I'm referring to TSU bit. > What if SoC contains multiple Cadence GEMs, some with PTP support and others > without? Simply define different DT compatibility strings and we're good. > Relevant will be checking both, hardware capabilities and SoC capabilities > from "caps" field. > -- Nicolas Ferre

Re: [PATCH 4.10-rc3 03/13] net: macb: fix build errors when linux/phy*.h is removed from net/dsa.h

2017-02-01 Thread Nicolas Ferre
et/cadence/macb.h:862:2: error: unknown type name > 'phy_interface_t' > phy_interface_t phy_interface; > ^~~ > > Add linux/phy.h to macb.h > > Signed-off-by: Russell King Acked-by: Nicolas Ferre > --- > drivers/net/ethernet/cadence/macb.h

Re: [PATCH net-next] macb: Common code to enable ptp support for SAMA5Dx platforms.

2017-01-18 Thread Nicolas Ferre
dma_burst_length; > @@ -874,6 +941,8 @@ struct macb { > unsigned intjumbo_max_len; > > u32 wol; > + > + struct macb_ptp_info*ptp_info; /* macb-ptp interface */ > }; > > static inline bool macb_is_gem(struct macb *bp) > @@ -881,4 +950,9 @@ static inline bool macb_is_gem(struct macb *bp) > return !!(bp->caps & MACB_CAPS_MACB_IS_GEM); > } > > +static inline bool gem_has_ptp(struct macb *bp) > +{ > + return !!(bp->caps & MACB_CAPS_GEM_HAS_PTP); > +} > + > #endif /* _MACB_H */ Otherwise, I'm okay with the rest. I suggest to people that will keep the ball rolling on this topic to take advantage of the chunks of code that Andrei developed with the help of Richard and the best practices discussed. I think particularly, if it makes sense with HW, about: - gem_ptp_do_[rt]xstamp(bp, skb) dereference scheme - gem_ptp_adjfine() rationale - gem_get_ptp_peer() if needed Regards, -- Nicolas Ferre

Re: [PATCH net-next v2] macb: Common code to enable ptp support for MACB/GEM

2017-01-19 Thread Nicolas Ferre
Le 19/01/2017 à 08:56, Andrei Pistirica a écrit : > This patch does the following: > - MACB/GEM-PTP interface > - registers and bitfields for TSU > - capability flags to enable PTP per platform basis > > Signed-off-by: Andrei Pistirica Acked-by: Nicolas Ferre Thanks, regar

Re: [RFC PATCH net-next v4 1/2] macb: Add 1588 support in Cadence GEM.

2017-01-02 Thread Nicolas Ferre
lready as v4 (thanks to your fruitful contributions BTW) for this series and will try to add features for other IP options & revisions incrementally. I suspect that Rafal tend to jump too quickly to the latest IP revisions and add more options to this series: let's not try to pour too much things into this code right now. FYI, Andrei will be back online next week. Regards, -- Nicolas Ferre

Re: [RFC PATCH net-next v4 1/2] macb: Add 1588 support in Cadence GEM.

2017-01-03 Thread Nicolas Ferre
>> On Mon, Jan 2, 2017 at 9:43 PM, Richard Cochran >> wrote: >>> On Mon, Jan 02, 2017 at 03:47:07PM +0100, Nicolas Ferre wrote: >>>> Le 02/01/2017 à 12:31, Richard Cochran a écrit : >>>>> This Cadence IP core is a complete disaster. >>>> >&

Re: [PATCH] net: macb: fix phy interrupt parsing

2017-04-27 Thread Nicolas Ferre
: macb: Added PCI wrapper for Platform Driver.") Means 4.10+ > Signed-off-by: Alexandre Belloni Acked-by: Nicolas Ferre Seems a good candidate for net stable. Bye, > --- > drivers/net/ethernet/cadence/macb.c | 18 ++ > 1 file changed, 10 insertions(+), 8

Re: [PATCH] net: macb: Increase DMA buffer size

2016-08-24 Thread Nicolas Ferre
acb_dma_desc) * > TX_RING_SIZE) > > /* level of occupied TX descriptors under which we wake up TX process */ > -- Nicolas Ferre

Re: Bug in cadence macb driver

2016-10-27 Thread Nicolas Ferre
gt; µWeb: Embedded Web Framework - http://uweb.workware.net.au/ > WorkWare Systems Pty Ltd > W: www.workware.net.au P: +61 434 921 300 > E: ste...@workware.net.au > > > > > > -- Nicolas Ferre

Re: [PATCH -next] net: macb: fix missing unlock on error in macb_start_xmit()

2016-09-29 Thread Nicolas Ferre
ry I missed that obvious point and for > causing any inconveniences. > > BTW, I see there are obviously quite a few users of MACB > implementations. I'm just curious if anybody else ever encountered the > checksum problem or if this a matter of Zynq implementation only. I've just verified that we are affected by this issue as well on sama5d2 (Microchip / Atmel cortex-A5 MPUs). Thanks for the fix, -- Nicolas Ferre

Re: [PATCH] net: macb: NULL out phydev after removing mdio bus

2016-10-07 Thread Nicolas Ferre
unregister_netdev > will end up calling macb_close. > > Signed-off-by: Xander Huff > Signed-off-by: Nathan Sullivan > Signed-off-by: Brad Mouring Acked-by: Nicolas Ferre > --- > drivers/net/ethernet/cadence/macb.c | 1 + > 1 file changed, 1 insertion(+) > > diff

Re: [RFC PATCH 2/2] Documentation: devictree: Add macb mdio bindings

2016-12-05 Thread Nicolas Ferre
t; or "cdns,sama5d2-gem-mdio" compatibility string. On the other hand, if it's strictly the same, we can use the "xlnx,zynq-gem-mdio" compatibility without any problem... > I'll take care of the other comments in the next version. > > Regards, > Harini > -- Nicolas Ferre

  1   2   >