From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> To: "David S. Miller" <davem@davemloft.net> Cc: Francois Romieu <romieu@fr.zoreil.com>, Lennert Buytenhek <kernel@wantstofly.org>, netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Jason Cooper <jason@lakedaemon.net>, Andrew Lunn <andrew@lunn.ch>, Gregory Clement <gregory.clement@free-electrons.com>, Lior Amsalem <alior@marvell.com>, Dmitri Epshtein <dima@marvell.com> Subject: [PATCH v7] Network driver for the Armada 370 and Armada XP ARM Marvell SoCs Date: Wed, 14 Nov 2012 15:56:44 +0100 [thread overview] Message-ID: <1352905010-24172-1-git-send-email-thomas.petazzoni@free-electrons.com> (raw) David, This patch set adds a new network driver for the network unit available in the newest Marvell ARM SoCs Armada 370 and Armada XP, as well as the necessary Device Tree information to use this driver in the two evaluation platforms of those SoCs. The previous versions of this patch set have been sent on September 4th (v1), October 11th (v2), October 23rd (v3), October 26th (v4), November 12th (v5), November 13th (v6) and now comes the v7 of the driver. The number of comments over the last versions have been really small, and I would really appreciate if this driver could land into the 3.8 kernel release. People interested in testing this driver can find it at: git@github.com:MISL-EBU-System-SW/mainline-public.git marvell-neta-v7 In details: * Patch 1 contains a small driver for the MDIO interface of this Ethernet controller. Having a separate driver is useful to more easily handle concurrent accesses on this MDIO interface that is shared between all Ethernet ports. * Patch 3 contains the driver itself. The commit log contains a detailed explanation about why a new driver is needed for this new Marvell SoC, compared to older Marvell SoCs (Orion, Kirkwood, Dove) that use the mv643xx_eth driver. * Patch 4 adds the necessary entry to the MAINTAINERS file. * Patch 5 adds the SoC-level Device Tree information for Armada 370 and Armada XP. * Patch 6 adds the board-level Device Tree information for the Marvell evaluation boards of Armada 370 and Armada XP. * Patch 6 adds the board-level Device Tree information for the PlatHome OpenBlocks AX3-4 platform (based on the Armada XP SoC). * Patch 7 adds the board-level Device Tree information for the GlobalScale Mirabox platform (based on the Armada 370 SoC). Changes since v6: * Add more macros to make the MVNETA_RX_PKT_SIZE() math easier to understand. * Use ETH_FCS_LEN instead of our custom MVNETA_ETH_CRC_SIZE. Suggested by François Romieu. * Add a comment explaining why we have MVNETA_MH_SIZE. * Added missing newlines at the end of some error/info messages. Suggested by Joe Perches. * Removed the useless error handling of mvneta_mac_addr_set(), and tested once for all the value of rxq_def at probe() time. Suggested by Francois Romieu. * Use napi_schedule() instead of an hand-crafted version of time. Suggested by Francois Romieu. * Don't use IRQF_DISABLED. Suggested by Francois Romieu. * Fix leak in mvneta_probe() on an error path (missing call to mvneta_deinit()). Re-arranged the goto labels for better clarity. Suggested by Francois Romieu. * Use the return value of mvneta_init() and register_netdev() as the return value of the ->probe() function on failure. Suggested by Francois Romieu. Changes since v5: * Take into account comments from François Romieu (mainly coding style fixes + addition of a mvneta_rxq_desc_is_first_last() helper function) * Fix a wrong argument passed to dma_alloc_coherent(): DMA_BIDIRECTIONAL should have been GFP_KERNEL. Thanks to François Romieu for having pointed the issue in his review. * Removed calls to smp_call_function_many() that were useless. * Ordered alphabetically entries in the Kconfig and Makefile. Changes since v4: * Added a separate MDIO driver, which allow to easily handle concurrent accesses to the MDIO interface. * The Device Tree now has separate nodes for the PHY devices, which belong to the MDIO bus handled by the separate MDIO driver. * Fix tabulation issues in some Device Tree files. * Rebased on top of 3.7-rc5 * Added the Device Tree code necessary for the GlobalScale Mirabox platform and the PlatHome OpenBlocks AX3-4 platform. Changes since v3: * Use phy_find_first() to get the correct PHY. Suggested by Florian Fainelli. * Make pp->cause_rx_tx a simple variable instead of a per-CPU array since it is not useful. Fixes a comment raised by David Miller. Changes since v2: * Change compatible string from 'marvell,neta' to 'marvell,armada-370-neta'. Requested by Rob Herring. * Rename Ethernet DT nodes from eth@... to ethernet@... Requested by Rob Herring. * Remove device_type DT property. Requested by Rob Herring. * Change the PHY interface for eth0/eth1 to be rgmii-id, which allows to enable TX/RX delay mechanisms at the PHY level. This fixes CRC errors on received packets during iperf tests (it was a bug in v2). * Remove the mvneta_ prefix from module parameters. Requested by Baruch Siach. * Many code style improvements suggested by François Romieu. * Properly stop/restart the TX queue when the number of TX descriptors available becomes low, instead of returning NETDEV_TX_BUSY. Requested by François Romieu. * Properly drop packets on the TX path when DMA mapping functions return an error, instead of returning NETDEV_TX_BUSY. Requested by François Romieu. * Rebased on top of Linux 3.7-rc2. Changes since v1: * Reduced the Cc: list in order to make the patch set acceptable for the netdev@ mailing list. * Merge the mvneta.h contents into mvneta.c, since the header was only used by the driver. Requested by Arnd Bergmann. * Completely reorganize the organization of the register list and register values, in order to make it more consistent, and hopefully easier to read (especially easier to match register values with the corresponding register). * Integrate with the phylib, as suggested by Florian Fainelli, and remove the link management code that has become useless as the result of this integration * Fix many small details suggested by Florian Fainelli in his review of the first driver * Simplify various parts of the driver (descriptors array allocation, data structures, etc.) Thanks, Thomas Petazzoni
WARNING: multiple messages have this Message-ID (diff)
From: thomas.petazzoni@free-electrons.com (Thomas Petazzoni) To: linux-arm-kernel@lists.infradead.org Subject: [PATCH v7] Network driver for the Armada 370 and Armada XP ARM Marvell SoCs Date: Wed, 14 Nov 2012 15:56:44 +0100 [thread overview] Message-ID: <1352905010-24172-1-git-send-email-thomas.petazzoni@free-electrons.com> (raw) David, This patch set adds a new network driver for the network unit available in the newest Marvell ARM SoCs Armada 370 and Armada XP, as well as the necessary Device Tree information to use this driver in the two evaluation platforms of those SoCs. The previous versions of this patch set have been sent on September 4th (v1), October 11th (v2), October 23rd (v3), October 26th (v4), November 12th (v5), November 13th (v6) and now comes the v7 of the driver. The number of comments over the last versions have been really small, and I would really appreciate if this driver could land into the 3.8 kernel release. People interested in testing this driver can find it at: git at github.com:MISL-EBU-System-SW/mainline-public.git marvell-neta-v7 In details: * Patch 1 contains a small driver for the MDIO interface of this Ethernet controller. Having a separate driver is useful to more easily handle concurrent accesses on this MDIO interface that is shared between all Ethernet ports. * Patch 3 contains the driver itself. The commit log contains a detailed explanation about why a new driver is needed for this new Marvell SoC, compared to older Marvell SoCs (Orion, Kirkwood, Dove) that use the mv643xx_eth driver. * Patch 4 adds the necessary entry to the MAINTAINERS file. * Patch 5 adds the SoC-level Device Tree information for Armada 370 and Armada XP. * Patch 6 adds the board-level Device Tree information for the Marvell evaluation boards of Armada 370 and Armada XP. * Patch 6 adds the board-level Device Tree information for the PlatHome OpenBlocks AX3-4 platform (based on the Armada XP SoC). * Patch 7 adds the board-level Device Tree information for the GlobalScale Mirabox platform (based on the Armada 370 SoC). Changes since v6: * Add more macros to make the MVNETA_RX_PKT_SIZE() math easier to understand. * Use ETH_FCS_LEN instead of our custom MVNETA_ETH_CRC_SIZE. Suggested by Fran?ois Romieu. * Add a comment explaining why we have MVNETA_MH_SIZE. * Added missing newlines at the end of some error/info messages. Suggested by Joe Perches. * Removed the useless error handling of mvneta_mac_addr_set(), and tested once for all the value of rxq_def at probe() time. Suggested by Francois Romieu. * Use napi_schedule() instead of an hand-crafted version of time. Suggested by Francois Romieu. * Don't use IRQF_DISABLED. Suggested by Francois Romieu. * Fix leak in mvneta_probe() on an error path (missing call to mvneta_deinit()). Re-arranged the goto labels for better clarity. Suggested by Francois Romieu. * Use the return value of mvneta_init() and register_netdev() as the return value of the ->probe() function on failure. Suggested by Francois Romieu. Changes since v5: * Take into account comments from Fran?ois Romieu (mainly coding style fixes + addition of a mvneta_rxq_desc_is_first_last() helper function) * Fix a wrong argument passed to dma_alloc_coherent(): DMA_BIDIRECTIONAL should have been GFP_KERNEL. Thanks to Fran?ois Romieu for having pointed the issue in his review. * Removed calls to smp_call_function_many() that were useless. * Ordered alphabetically entries in the Kconfig and Makefile. Changes since v4: * Added a separate MDIO driver, which allow to easily handle concurrent accesses to the MDIO interface. * The Device Tree now has separate nodes for the PHY devices, which belong to the MDIO bus handled by the separate MDIO driver. * Fix tabulation issues in some Device Tree files. * Rebased on top of 3.7-rc5 * Added the Device Tree code necessary for the GlobalScale Mirabox platform and the PlatHome OpenBlocks AX3-4 platform. Changes since v3: * Use phy_find_first() to get the correct PHY. Suggested by Florian Fainelli. * Make pp->cause_rx_tx a simple variable instead of a per-CPU array since it is not useful. Fixes a comment raised by David Miller. Changes since v2: * Change compatible string from 'marvell,neta' to 'marvell,armada-370-neta'. Requested by Rob Herring. * Rename Ethernet DT nodes from eth at ... to ethernet at ... Requested by Rob Herring. * Remove device_type DT property. Requested by Rob Herring. * Change the PHY interface for eth0/eth1 to be rgmii-id, which allows to enable TX/RX delay mechanisms at the PHY level. This fixes CRC errors on received packets during iperf tests (it was a bug in v2). * Remove the mvneta_ prefix from module parameters. Requested by Baruch Siach. * Many code style improvements suggested by Fran?ois Romieu. * Properly stop/restart the TX queue when the number of TX descriptors available becomes low, instead of returning NETDEV_TX_BUSY. Requested by Fran?ois Romieu. * Properly drop packets on the TX path when DMA mapping functions return an error, instead of returning NETDEV_TX_BUSY. Requested by Fran?ois Romieu. * Rebased on top of Linux 3.7-rc2. Changes since v1: * Reduced the Cc: list in order to make the patch set acceptable for the netdev@ mailing list. * Merge the mvneta.h contents into mvneta.c, since the header was only used by the driver. Requested by Arnd Bergmann. * Completely reorganize the organization of the register list and register values, in order to make it more consistent, and hopefully easier to read (especially easier to match register values with the corresponding register). * Integrate with the phylib, as suggested by Florian Fainelli, and remove the link management code that has become useless as the result of this integration * Fix many small details suggested by Florian Fainelli in his review of the first driver * Simplify various parts of the driver (descriptors array allocation, data structures, etc.) Thanks, Thomas Petazzoni
next reply other threads:[~2012-11-14 14:57 UTC|newest] Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top 2012-11-14 14:56 Thomas Petazzoni [this message] 2012-11-14 14:56 ` [PATCH v7] Network driver for the Armada 370 and Armada XP ARM Marvell SoCs Thomas Petazzoni 2012-11-14 14:56 ` [PATCH v7 1/6] net: mvmdio: new Marvell MDIO driver Thomas Petazzoni 2012-11-14 14:56 ` Thomas Petazzoni 2012-11-14 14:56 ` [PATCH v7 2/6] net: mvneta: driver for Marvell Armada 370/XP network unit Thomas Petazzoni 2012-11-14 14:56 ` Thomas Petazzoni 2012-11-16 23:04 ` Ben Hutchings 2012-11-16 23:04 ` Ben Hutchings 2012-11-14 14:56 ` [PATCH v7 3/6] net: mvneta: update MAINTAINERS file for the mvneta maintainers Thomas Petazzoni 2012-11-14 14:56 ` Thomas Petazzoni 2012-11-14 14:56 ` [PATCH v7 4/6] arm: mvebu: add Ethernet controllers using mvneta driver for Armada 370/XP Thomas Petazzoni 2012-11-14 14:56 ` Thomas Petazzoni 2012-11-14 14:56 ` [PATCH v7 5/6] arm: mvebu: enable Ethernet controllers on Armada 370/XP eval boards Thomas Petazzoni 2012-11-14 14:56 ` Thomas Petazzoni 2012-11-14 14:56 ` [PATCH v7 6/6] arm: mvebu: enable Ethernet controllers on OpenBlocks AX3-4 platform Thomas Petazzoni 2012-11-14 14:56 ` Thomas Petazzoni 2012-11-15 2:59 ` [PATCH v7] Network driver for the Armada 370 and Armada XP ARM Marvell SoCs David Miller 2012-11-15 2:59 ` David Miller 2012-11-15 7:33 ` Thomas Petazzoni 2012-11-15 7:33 ` Thomas Petazzoni 2012-11-15 7:42 ` David Miller 2012-11-15 7:42 ` David Miller 2012-11-15 8:02 ` Thomas Petazzoni 2012-11-15 8:02 ` Thomas Petazzoni 2012-11-17 6:48 ` Willy Tarreau 2012-11-17 6:48 ` Willy Tarreau
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=1352905010-24172-1-git-send-email-thomas.petazzoni@free-electrons.com \ --to=thomas.petazzoni@free-electrons.com \ --cc=alior@marvell.com \ --cc=andrew@lunn.ch \ --cc=davem@davemloft.net \ --cc=dima@marvell.com \ --cc=gregory.clement@free-electrons.com \ --cc=jason@lakedaemon.net \ --cc=kernel@wantstofly.org \ --cc=linux-arm-kernel@lists.infradead.org \ --cc=netdev@vger.kernel.org \ --cc=romieu@fr.zoreil.com \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.