Re: [PATCH] gpio MIPS/OCTEON: Add a driver for OCTEON's on-chip GPIO pins.

2013-06-24 Thread David Daney
Thanks for looking at this again. I will be away from my office until the middle of July, so I will not be able to generate and test a revised patch until then. David Daney On 06/24/2013 03:06 PM, Linus Walleij wrote: On Thu, Jun 20, 2013 at 8:10 PM, David Daney ddaney.c...@gmail.com

Re: Re: [PATCH] gpio MIPS/OCTEON: Add a driver for OCTEON's on-chip GPIO pins.

2013-06-20 Thread David Daney
Sorry for not responding earlier, but my e-mail system seems to have malfunctioned with respect to this message... On 06/17/2013 01:51 AM, Linus Walleij wrote: On Sat, Jun 15, 2013 at 1:18 AM, David Daney ddaney.c...@gmail.com wrote: From: David Daney david.da...@cavium.com The SOCs

Re: [PATCH] gpio MIPS/OCTEON: Add a driver for OCTEON's on-chip GPIO pins.

2013-06-20 Thread David Daney
On 06/20/2013 11:18 AM, Joe Perches wrote: On Thu, 2013-06-20 at 11:10 -0700, David Daney wrote: Sorry for not responding earlier, but my e-mail system seems to have malfunctioned with respect to this message... [] On 06/17/2013 01:51 AM, Linus Walleij wrote: +static int octeon_gpio_get

Re: [PATCH] gpio MIPS/OCTEON: Add a driver for OCTEON's on-chip GPIO pins.

2013-06-20 Thread David Daney
On 06/20/2013 11:43 AM, Joe Perches wrote: On Thu, 2013-06-20 at 11:27 -0700, David Daney wrote: On 06/20/2013 11:18 AM, Joe Perches wrote: On Thu, 2013-06-20 at 11:10 -0700, David Daney wrote: Sorry for not responding earlier, but my e-mail system seems to have malfunctioned with respect

[PATCH] gpio MIPS/OCTEON: Add a driver for OCTEON's on-chip GPIO pins.

2013-06-14 Thread David Daney
From: David Daney david.da...@cavium.com The SOCs in the OCTEON family have 16 (or in some cases 20) on-chip GPIO pins, this driver handles them all. Configuring the pins as interrupt sources is handled elsewhere (OCTEON's irq handling code). Signed-off-by: David Daney david.da...@cavium.com

Re: [PATCH 1/3] Document: devicetree: add OF documents for MIPS interrupt controller

2013-01-31 Thread David Daney
On 01/31/2013 05:20 AM, John Crispin wrote: Signed-off-by: John Crispin blo...@openwrt.org Acked-by: David Daney david.da...@cavium.com --- Documentation/devicetree/bindings/mips/cpu_irq.txt | 47 1 file changed, 47 insertions(+) create mode 100644 Documentation

Re: [PATCH RESEND] i2c: Add support for device-tree based chip initialization

2012-11-26 Thread David Daney
-init proposal. David Daney g. ___ devicetree-discuss mailing list devicetree-discuss@lists.ozlabs.org https://lists.ozlabs.org/listinfo/devicetree-discuss ___ devicetree-discuss mailing list devicetree

Re: [RFC] MIPS: BCM63XX: add simple Device Tree includes for all SoCs

2012-11-13 Thread David Daney
\*.dts\*` to a top level dts/ directory. David Daney ___ devicetree-discuss mailing list devicetree-discuss@lists.ozlabs.org https://lists.ozlabs.org/listinfo/devicetree-discuss

Re: [PATCH 2/2] misc/at25: Add an .id_table to at25 to facilitate driver loading and binding.

2012-09-17 Thread David Daney
On 09/17/2012 12:49 AM, Ivo Sieben wrote: Hi, 2012/8/22 David Daney ddaney.c...@gmail.com: From: David Daney david.da...@cavium.com /*-*/ +static const struct spi_device_id at25_id[] = { + {at25, 0

Re: patch misc/at25, dt: Improve at25 SPI eeprom device tree bindings. added to char-misc tree

2012-09-05 Thread David Daney
Grant or Rob giving an Acked-by. David Daney. to my char-misc git tree which can be found at git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc.git in the char-misc-next branch. The patch will show up in the next release of the linux-next tree (usually sometime within the next 24

Re: patch misc/at25, dt: Improve at25 SPI eeprom device tree bindings. added to char-misc tree

2012-09-05 Thread David Daney
On 09/05/2012 04:34 PM, Greg KH wrote: On Wed, Sep 05, 2012 at 02:33:58PM -0700, David Daney wrote: On 09/05/2012 02:10 PM, gre...@linuxfoundation.org wrote: This is a note to let you know that I've just added the patch titled misc/at25, dt: Improve at25 SPI eeprom device tree bindings

[RFC] How should the device tree represent multiple Ethernet PHYs in a single package?

2012-08-23 Thread David Daney
*/ inta = 5; }; }; We would then modify of_mdio.c so that when it encountered an ethernet-phy-nexus, it would add all the children of the nexus. Comments? Objections? Thanks, and let me know what you think, David Daney ___ devicetree-discuss

[PATCH 0/2] SPI EEPROM / device tree interaction improvements.

2012-08-22 Thread David Daney
From: David Daney david.da...@cavium.com A couple of patches that make using SPI EEPROMs Real Easy for me. David Daney (2): misc/at25, dt: Improve at25 SPI eeprom device tree bindings. misc/at25: Add an .id_table to at25 to facilitate driver loading and binding. Documentation

[PATCH 2/2] misc/at25: Add an .id_table to at25 to facilitate driver loading and binding.

2012-08-22 Thread David Daney
From: David Daney david.da...@cavium.com With this patch we get automatic driver loading and binding for device tree specified hardware typologies. Also recognize st,m95256 devices as being compatible with the driver. Signed-off-by: David Daney david.da...@cavium.com --- drivers/misc/eeprom

Re: [PATCH] netdev/phy: add MDIO bus multiplexer driven by a memory-mapped FPGA

2012-08-22 Thread David Daney
need a shift too? David Daney ___ devicetree-discuss mailing list devicetree-discuss@lists.ozlabs.org https://lists.ozlabs.org/listinfo/devicetree-discuss

Re: [PATCH] netdev/phy: add MDIO bus multiplexer driven by a memory-mapped FPGA

2012-08-22 Thread David Daney
On 08/22/2012 03:38 PM, Timur Tabi wrote: David Daney wrote: I wonder if *fpga is really a good name for this. It is a general purpose multiplexer with a memory mapped control register. I would call it something like mdio-mux-mmioreg. At one point, I thought of using mdio-mux-bitbang

Re: [PATCH 2/2] spi: Add SPI master controller for OCTEON SOCs.

2012-08-21 Thread David Daney
On 05/19/2012 10:46 PM, Grant Likely wrote: On Fri, 11 May 2012 14:34:46 -0700, David Daney ddaney.c...@gmail.com wrote: From: David Daney david.da...@cavium.com Add the driver, link it into the kbuild system and provide device tree binding documentation. Signed-off-by: David Daney david.da

Re: [2/2] spi: Add SPI master controller for OCTEON SOCs.

2012-08-21 Thread David Daney
On 08/21/2012 12:49 PM, Guenter Roeck wrote: On Fri, May 11, 2012 at 08:34:46PM -, David Daney wrote: From: David Daney david.da...@cavium.com Add the driver, link it into the kbuild system and provide device tree binding documentation. Signed-off-by: David Daney david.da...@cavium.com

Re: [PATCH] netdev/phy: skip disabled mdio-mux nodes

2012-08-07 Thread David Daney
; Although this will get the job done, I don't think it is the cleanest approach. Would it be better to create a new iterator (for_each_available_child_of_node perhaps) that skips the unavailable nodes? This seems like a general problem that is not restricted to mdio multiplexers. David

[PATCH v2 2/4] netdev/phy/of: Handle IEEE802.3 clause 45 Ethernet PHYs in of_mdiobus_register()

2012-06-27 Thread David Daney
From: David Daney david.da...@cavium.com Define two new compatible values for Ethernet PHYs. ethernet-phy-ieee802.3-c22 and ethernet-phy-ieee802.3-c45 are used to indicate a PHY uses the corresponding protocol. If a PHY is compatible with ethernet-phy-ieee802.3-c45, we indicate this so

[PATCH v2 3/4] netdev/phy/of: Add more methods for binding PHY devices to drivers.

2012-06-27 Thread David Daney
From: David Daney david.da...@cavium.com Allow PHY drivers to supply their own device matching function (match_phy_device()), or to be matched OF compatible properties. PHYs following IEEE802.3 clause 45 have more than one device identifier constants, which breaks the default device matching

[PATCH v2 0/4] netdev/phy: 10G PHY support.

2012-06-27 Thread David Daney
From: David Daney david.da...@cavium.com The only non-cosmetic change from v1 is to pass an additional argument to get_phy_device() that indicates that the PHY uses 802.3 clause 45 signaling, previously I had been using a high order bit of the addr parameter for this. There are also changes from

[PATCH v2 1/4] netdev/phy: Handle IEEE802.3 clause 45 Ethernet PHYs

2012-06-27 Thread David Daney
From: David Daney david.da...@cavium.com The IEEE802.3 clause 45 MDIO bus protocol allows for directly addressing PHY registers using a 21 bit address, and is used by many 10G Ethernet PHYS. Already existing is the ability of MDIO bus drivers to use clause 45, with the MII_ADDR_C45 flag. Here

[PATCH v2 4/4] netdev/phy: Add driver for Broadcom BCM87XX 10G Ethernet PHYs

2012-06-27 Thread David Daney
From: David Daney david.da...@cavium.com Add a driver for BCM8706 and BCM8727 devices. These are a 10Gig PHYs which use MII_ADDR_C45 addressing. They are always 10G full duplex, so there is no autonegotiation. All we do is report link state and send interrupts when it changes. If the PHY has

Re: [PATCH 1/4] netdev/phy: Handle IEEE802.3 clause 45 Ethernet PHYs

2012-06-25 Thread David Daney
the correct kerneldoc format to do so. OK. David Daney ___ devicetree-discuss mailing list devicetree-discuss@lists.ozlabs.org https://lists.ozlabs.org/listinfo/devicetree-discuss

Re: [PATCH 1/4] netdev/phy: Handle IEEE802.3 clause 45 Ethernet PHYs

2012-06-25 Thread David Daney
of multiplexing the arguments into a single int. Therefore, I am going to propose that we add a 'flags' parameter to get_phy_device() and change the (two) callers. Does that seem better (or at least acceptable)? Or do you really want to pass the address of a (one bit) structure instead? David Daney

[PATCH 0/4] netdev/phy: 10G PHY support.

2012-06-22 Thread David Daney
From: David Daney david.da...@cavium.com The existing PHY driver infrastructure supports IEEE 802.3 Clause 22 PHYs used with 10/100/1000MB Ethernet. For 10G Ethernet, many PHYs use 802.3 Clause 45. These patches attempt to add core support for this as well as a driver for BCM87XX 10G PHY

[PATCH 2/4] netdev/phy/of: Handle IEEE802.3 clause 45 Ethernet PHYs in of_mdiobus_register()

2012-06-22 Thread David Daney
From: David Daney david.da...@cavium.com Define two new compatible values for Ethernet PHYs. ethernet-phy-ieee802.3-c22 and ethernet-phy-ieee802.3-c45 are used to indicate a PHY uses the corresponding protocol. If a PHY is compatible with ethernet-phy-ieee802.3-c45, we indicate this so

[PATCH 3/4] netdev/phy/of: Add more methods for binding PHY devices to drivers.

2012-06-22 Thread David Daney
From: David Daney david.da...@cavium.com Allow PHY drivers to supply their own device matching function (match_phy_device()), or to be matched OF compatible properties. PHYs following IEEE802.3 clause 45 have more than one device identifier constants, which breaks the default device matching

[PATCH 1/4] netdev/phy: Handle IEEE802.3 clause 45 Ethernet PHYs

2012-06-22 Thread David Daney
From: David Daney david.da...@cavium.com The IEEE802.3 clause 45 MDIO bus protocol allows for directly addressing PHY registers using a 21 bit address, and is used by many 10G Ethernet PHYS. Already existing is the ability of MDIO bus drivers to use clause 45, with the MII_ADDR_C45 flag. Here

[PATCH v8 1/1] of/lib: Allow scripts/dtc/libfdt to be used from kernel code

2012-06-06 Thread David Daney
From: David Daney david.da...@cavium.com libfdt is part of the device tree support in scripts/dtc/libfdt. For some platforms that use the Device Tree, we want to be able to edit the flattened device tree form. We don't want to burden kernel builds that do not require it, so we gate compilation

[PATCH v8 3/4] MIPS: Octeon: Initialize and fixup device tree.

2012-06-06 Thread David Daney
From: David Daney david.da...@cavium.com If a compiled in device tree template is used, trim out unwanted parts based on legacy platform probing. Signed-off-by: David Daney david.da...@cavium.com --- arch/mips/Kconfig |2 + arch/mips/cavium-octeon/Makefile

[PATCH v8 4/4] MIPS: Octeon: Setup irq_domains for interrupts.

2012-06-06 Thread David Daney
From: David Daney david.da...@cavium.com Create two domains. One for the GPIO lines, and the other for on-chip sources. Signed-off-by: David Daney david.da...@cavium.com --- arch/mips/cavium-octeon/octeon-irq.c | 215 -- 1 files changed, 206 insertions(+), 9

[PATCH v8 2/4] MIPS: Octeon: Add device tree source files.

2012-06-06 Thread David Daney
From: David Daney david.da...@cavium.com The two device tree files octeon_3xxx.dts and octeon_68xx.dts are trimmed by code in a subsequent patch to reflect the hardware actually present on the board. To this end several properties that are not part of the declared bindings are added to aid

[PATCH v3 2/5] netdev: mdio-octeon.c: Convert to use device tree.

2012-06-06 Thread David Daney
From: David Daney david.da...@cavium.com Get the MDIO bus controller addresses from the device tree, small clean up in use of devm_* Remove, now unused, platform device setup code. Acked-by: David S. Miller da...@davemloft.net Signed-off-by: David Daney david.da...@cavium.com --- arch/mips

[PATCH v3 1/5] i2c: Convert i2c-octeon.c to use device tree.

2012-06-06 Thread David Daney
From: David Daney david.da...@cavium.com There are three parts to this: 1) Remove the definitions of OCTEON_IRQ_TWSI and OCTEON_IRQ_TWSI2. The interrupts are specified by the device tree and these hard coded irq numbers block the used of the irq lines by the irq_domain code. 2) Remove

[PATCH v3 0/5] MIPS: OCTEON: Convert some device to use Device Tree.

2012-06-06 Thread David Daney
From: David Daney david.da...@cavium.com This patch set depends on the previous set to add Device Tree to OCTEON. That set can be found among other places here: http://www.linux-mips.org/archives/linux-mips/2012-06/msg00081.html For v3: No functional changes, Added more Acked-bys, rebased

[PATCH v3 4/5] staging: octeon_ethernet: Convert to use device tree.

2012-06-06 Thread David Daney
From: David Daney david.da...@cavium.com Get MAC address and PHY connection from the device tree. The driver is converted to a platform driver. Signed-off-by: David Daney david.da...@cavium.com Acked-by: Grant Likely grant.lik...@secretlab.ca --- drivers/staging/octeon/ethernet-mdio.c | 28

[PATCH v3 3/5] netdev: octeon_mgmt: Convert to use device tree.

2012-06-06 Thread David Daney
From: David Daney david.da...@cavium.com The device tree will supply the register bank base addresses, make register addressing relative to those. PHY connection is now described by the device tree. The OCTEON_IRQ_MII{0,1} symbols are also removed as they are now unused and interfere

[PATCH v3 5/5] MIPS: Octeon: Use device tree to register serial ports.

2012-06-06 Thread David Daney
From: David Daney david.da...@cavium.com Switch to using the device tree to register serial ports. Add all the ports with compatible = cavium,octeon-3860-uart. Octeon serial ports have their own device type, required port flags, and I/O functions, so using of_serial.c is not indicated. We need

[PATCH 3/5] netdev/phy/of: Add more methods for binding PHY devices to drivers.

2012-05-22 Thread David Daney
From: David Daney david.da...@cavium.com Allow PHY drivers to supply their own device matching function (match_phy_device()), or to be matched OF compatible properties. PHYs following IEEE802.3 clause 45 have more than one device identifier constants, which breaks the default device matching

[PATCH 2/5] netdev/phy/of: Handle IEEE802.3 clause 45 Ethernet PHYs in of_mdiobus_register()

2012-05-22 Thread David Daney
From: David Daney david.da...@cavium.com Define two new compatible values for Ethernet PHYs. ethernet-phy-ieee802.3-c22 and ethernet-phy-ieee802.3-c45 are used to indicate a PHY uses the corresponding protocol. If a PHY is compatible with ethernet-phy-ieee802.3-c45, we indicate this so

[PATCH 0/5] netdev/phy: 10G PHY support.

2012-05-22 Thread David Daney
From: David Daney david.da...@cavium.com The existing PHY driver infrastructure supports IEEE 802.3 Clause 22 PHYs used with 10/100/1000MB Ethernet. For 10G Ethernet, many PHYs use 802.3 Clause 45. These patches attempt to add core support for this as well as drivers for several different 10G

[PATCH 4/5] netdev/phy: Add driver for Broadcom BCM87XX 10G Ethernet PHYs

2012-05-22 Thread David Daney
From: David Daney david.da...@cavium.com Add a driver for BCM8706 and BCM8727 devices. These are a 10Gig PHYs which use MII_ADDR_C45 addressing. They are always 10G full duplex, so there is no autonegotiation. All we do is report link state and send interrupts when it changes. If the PHY has

[PATCH 1/5] netdev/phy: Handle IEEE802.3 clause 45 Ethernet PHYs

2012-05-22 Thread David Daney
From: David Daney david.da...@cavium.com The IEEE802.3 clause 45 MDIO bus protocol allows for directly addressing PHY registers using a 21 bit address, and is used by many 10G Ethernet PHYS. Already existing is the ability of MDIO bus drivers to use clause 45, with the MII_ADDR_C45 flag. Here

Re: [PATCH 5/5] netdev/phy: Add driver for Cortina cs4321 quad 10G PHY.

2012-05-22 Thread David Daney
On 05/22/2012 11:50 AM, Ben Hutchings wrote: On Tue, May 22, 2012 at 10:59:52AM -0700, David Daney wrote: [...] --- /dev/null +++ b/drivers/net/phy/cs4321-ucode.h @@ -0,0 +1,4378 @@ +/* + *Copyright (C) 2011 by Cortina Systems, Inc. + * + *This program is free software; you can

Re: [PATCH 1/3] of: Add prefix parameter to of_modalias_node().

2012-05-22 Thread David Daney
On 05/19/2012 11:08 PM, Grant Likely wrote: On Sat, 19 May 2012 23:54:36 -0600, Grant Likelygrant.lik...@secretlab.ca wrote: On Fri, 11 May 2012 15:05:21 -0700, David Daneyddaney.c...@gmail.com wrote: From: David Daneydavid.da...@cavium.com When generating MODALIASes, it is convenient to

Re: [PATCH v6 0/3] netdev/of/phy: MDIO bus multiplexer support.

2012-05-18 Thread David Daney
. A sane person would implement a separate MDIO STA controller for each bus, in which case you wouldn't use the multiplexer driver. Only people dealing with insane hardware need the multiplexer. The patch in net-next has a nice ASCII art picture of such an insane design. David Daney ebb6600.dts

Re: [PATCH v6 0/3] netdev/of/phy: MDIO bus multiplexer support.

2012-05-18 Thread David Daney
On 05/18/2012 03:09 PM, Timur Tabi wrote: David Daney wrote: I'm not sure what the parent MDIO bus node is supposed to represent. Is that that device that actually controls the muxing hardware No. It is the device that implements the master 802.3 clause {22,45} MDIO Station Management

Re: [PATCH 2/2] spi: Add SPI master controller for OCTEON SOCs.

2012-05-14 Thread David Daney
to be a problem. David Daney ___ devicetree-discuss mailing list devicetree-discuss@lists.ozlabs.org https://lists.ozlabs.org/listinfo/devicetree-discuss

[PATCH 0/2] MIPS/spi: New driver for SPI master controller for OCTEON SOCs.

2012-05-11 Thread David Daney
From: David Daney david.da...@cavium.com Several members of the OCTEON family have on-chips SPI master controller hardware, so here is a driver for it. I split the register definitions out to a separate patch so that they live with all the other similar files for other OCTEON hardware blocks

[PATCH 1/2] MIPS: OCTEON: Add register definitions for SPI host hardware.

2012-05-11 Thread David Daney
From: David Daney david.da...@cavium.com Needed by SPI driver. Signed-off-by: David Daney david.da...@cavium.com --- arch/mips/include/asm/octeon/cvmx-mpi-defs.h | 328 ++ 1 files changed, 328 insertions(+), 0 deletions(-) create mode 100644 arch/mips/include/asm

[PATCH 0/3] of/spi/eeprom: Configure at25 from device tree and autoload its driver.

2012-05-11 Thread David Daney
From: David Daney david.da...@cavium.com As per the Subject, given a device tree fragment like this: spi@107001000 { compatible = cavium,octeon-3010-spi; reg = 0x10700 0x1000 0x0 0x100; interrupts = 0 58; #address

[PATCH 2/3] spi: Use consistent MODALIAS values.

2012-05-11 Thread David Daney
From: David Daney david.da...@cavium.com For SPI devices, the MODALIAS should start with spi: so that the modprobe can find the proper drivers. Be consistent, for devices added via spi_new_device(), make sure spi: is added if it is not already there. In spi_match_device() handle matching when

[PATCH 3/3] eeprom/of: Add device tree bindings to at25.

2012-05-11 Thread David Daney
From: David Daney david.da...@cavium.com We can extract the pagesize, size and address-width from the device tree so that SPI eeproms can be fully specified in the device tree. Also add a MODULE_DEVICE_TABLE so the drivers can be automatically bound. Signed-off-by: David Daney david.da

[PATCH 1/3] of: Add prefix parameter to of_modalias_node().

2012-05-11 Thread David Daney
From: David Daney david.da...@cavium.com When generating MODALIASes, it is convenient to add things like spi: or i2c: to the front of the strings. This allows the standard modprobe to find the right driver when automatically populating bus children from the device tree structure. Add a prefix

[PATCH RFC] mmc: Add host driver for OCTEON MMC controller.

2012-05-09 Thread David Daney
From: David Daney david.da...@cavium.com The OCTEON MMC controller is currently found on cn61XX and cnf71XX devices. Device parameters are configured from device tree data. Currenly supported are eMMC, MMC and SD devices. Signed-off-by: David Daney david.da...@cavium.com --- This patch

Re: [PATCH] OF: PCI: const usage needed by MIPS

2012-05-03 Thread David Daney
On 05/03/2012 05:30 PM, Bjorn Helgaas wrote: On Tue, May 1, 2012 at 7:28 AM, John Crispinblo...@openwrt.org wrote: On 30/04/12 19:54, David Daney wrote: On 04/30/2012 10:46 AM, John Crispin wrote: On MIPS we want to call of_irq_map_pci from inside arch/mips/include/asm/pci.h:extern int

[PATCH v6 0/3] netdev/of/phy: MDIO bus multiplexer support.

2012-05-02 Thread David Daney
From: David Daney david.da...@cavium.com This code has been working well for about six months on a couple of different configurations (boards), so I thought it would be a good time to send it out again, and I hope get it on the path towards merging. v6: Correct Kconfig depends in 2/3 as noticed

[PATCH v6 1/3] netdev/of/phy: New function: of_mdio_find_bus().

2012-05-02 Thread David Daney
From: David Daney david.da...@cavium.com Add of_mdio_find_bus() which allows an mii_bus to be located given its associated the device tree node. This is needed by the follow-on patch to add a driver for MDIO bus multiplexers. The of_mdiobus_register() function is modified so that the device

[PATCH v6 2/3] netdev/of/phy: Add MDIO bus multiplexer support.

2012-05-02 Thread David Daney
From: David Daney david.da...@cavium.com This patch adds a somewhat generic framework for MDIO bus multiplexers. It is modeled on the I2C multiplexer. The multiplexer is needed if there are multiple PHYs with the same address connected to the same MDIO bus adepter, or if there is insufficient

[PATCH v6 3/3] netdev/of/phy: Add MDIO bus multiplexer driven by GPIO lines.

2012-05-02 Thread David Daney
From: David Daney david.da...@cavium.com The GPIO pins select which sub bus is connected to the master. Initially tested with an sn74cbtlv3253 switch device wired into the MDIO bus. Signed-off-by: David Daney david.da...@cavium.com --- .../devicetree/bindings/net/mdio-mux-gpio.txt | 127

Re: [PATCH] OF: PCI: const usage needed by MIPS

2012-04-30 Thread David Daney
this consistent tree-wide, but it is not yet applied. David Daney Signed-off-by: John Crispinblo...@openwrt.org Cc: linux-...@vger.kernel.org Cc: devicetree-discuss@lists.ozlabs.org Cc: linux-m...@linux-mips.org --- I am not sure which tree this should go via. Grant, can you take it ? drivers

[PATCH v8 1/4] MIPS: Don't define early_init_devtree() and device_tree_init() in prom.c for CPU_CAVIUM_OCTEON

2012-04-26 Thread David Daney
From: David Daney david.da...@cavium.com This code is not common enough to be in a shared file, so OCTEON defines it's own versions. When the last of this target specific code is moved out, we can remove all of this. Signed-off-by: David Daney david.da...@cavium.com --- arch/mips/kernel/prom.c

[PATCH v8 0/4] MIPS: OCTEON: Use Device Tree.

2012-04-26 Thread David Daney
From: David Daney david.da...@cavium.com This code has now had extensive testing, it is running on more than 10 different boards and SOC combinations. The patches in this set are all in the arch/mips tree and should probably be merged by Ralf. They do depend on this libfdt patch: https

[PATCH v8 2/4] MIPS: Octeon: Setup irq_domains for interrupts.

2012-04-26 Thread David Daney
From: David Daney david.da...@cavium.com Create two domains. One for the GPIO lines, and the other for on-chip sources. Signed-off-by: David Daney david.da...@cavium.com --- arch/mips/cavium-octeon/octeon-irq.c | 215 -- 1 files changed, 206 insertions(+), 9

[PATCH v8 4/4] MIPS: Octeon: Initialize and fixup device tree.

2012-04-26 Thread David Daney
From: David Daney david.da...@cavium.com Signed-off-by: David Daney david.da...@cavium.com --- arch/mips/Kconfig |2 + arch/mips/cavium-octeon/Makefile |3 + arch/mips/cavium-octeon/octeon-platform.c | 523 - arch/mips/cavium

[PATCH v8 3/4] MIPS: Octeon: Add device tree source files.

2012-04-26 Thread David Daney
From: David Daney david.da...@cavium.com The two device tree files octeon_3xxx.dts and octeon_68xx.dts are trimmed by code in a subsequent patch to reflect the hardware actually present on the board. To this end several properties that are not part of the declared bindings are added to aid

[PATCH v2 2/5] netdev: mdio-octeon.c: Convert to use device tree.

2012-04-26 Thread David Daney
From: David Daney david.da...@cavium.com Get the MDIO bus controller addresses from the device tree, small clean up in use of devm_* Remove, now unused, platform device setup code. Acked-by: David S. Miller da...@davemloft.net Signed-off-by: David Daney david.da...@cavium.com Cc: net

[PATCH v2 0/5] MIPS: OCTEON: Convert some device to use Device Tree.

2012-04-26 Thread David Daney
From: David Daney david.da...@cavium.com This patch set depends on the previous set to add Device Tree to OCTEON. That set can be found among other places here: http://marc.info/?l=linux-kernelm=133548781607480 For v2: No functional changes, but minor clean-ups to use some new device tree

[PATCH v2 1/5] i2c: Convert i2c-octeon.c to use device tree.

2012-04-26 Thread David Daney
From: David Daney david.da...@cavium.com There are three parts to this: 1) Remove the definitions of OCTEON_IRQ_TWSI and OCTEON_IRQ_TWSI2. The interrupts are specified by the device tree and these hard coded irq numbers block the used of the irq lines by the irq_domain code. 2) Remove

[PATCH v2 5/5] MIPS: Octeon: Use device tree to register serial ports.

2012-04-26 Thread David Daney
From: David Daney david.da...@cavium.com Switch to using the device tree to register serial ports. Add all the ports with compatible = cavium,octeon-3860-uart. Octeon serial ports have their own device type, required port flags, and I/O functions, so using of_serial.c is not indicated. We need

[PATCH v2 4/5] staging: octeon_ethernet: Convert to use device tree.

2012-04-26 Thread David Daney
From: David Daney david.da...@cavium.com Get MAC address and PHY connection from the device tree. The driver is converted to a platform driver. Acked-by: Greg Kroah-Hartman gre...@linuxfoundation.org Signed-off-by: David Daney david.da...@cavium.com Cc: net...@vger.kernel.org Cc: Greg Kroah

Re: [PATCH v5 2/3] netdev/of/phy: Add MDIO bus multiplexer support.

2012-04-23 Thread David Daney
appropriate dependencies. I will send a revised patch set. Thanks, David Daney ___ devicetree-discuss mailing list devicetree-discuss@lists.ozlabs.org https://lists.ozlabs.org/listinfo/devicetree-discuss

Re: [PATCH v3 2/2] i2c/of: Automatically populate i2c mux busses from device tree data.

2012-04-23 Thread David Daney
On 04/22/2012 09:20 AM, Wolfram Sang wrote: On Thu, Apr 12, 2012 at 02:14:23PM -0700, David Daney wrote: From: David Daneydavid.da...@cavium.com For 'normal' i2c bus drivers, we can call of_i2c_register_devices() and have the device tree framework automatically populate the bus

Re: [PATCH v3 2/2] i2c/of: Automatically populate i2c mux busses from device tree data.

2012-04-23 Thread David Daney
On 04/23/2012 09:58 AM, Wolfram Sang wrote: I can send a new patch set with those corrections, or if you prefer, you could commit these making the changes yourself. I'll do it, probably faster for both of us :) Great! Thank you for reviewing this, David Daney

Re: [PATCH 1/2] i2c: mux: add device tree support

2012-04-23 Thread David Daney
parameters required for DT support. Update all callers. ** Set the appropriate adap-dev.of_node for the child bus. ** Call of_i2c_register_devices() for the child bus. Signed-off-by: Stephen Warrenswar...@nvidia.com David Daney (CCed) posted another variant [1]. Just looking at the patches

Re: [PATCH v5 2/3] netdev/of/phy: Add MDIO bus multiplexer support.

2012-04-21 Thread David Daney
it here too. David Daney ___ devicetree-discuss mailing list devicetree-discuss@lists.ozlabs.org https://lists.ozlabs.org/listinfo/devicetree-discuss

Re: [PATCH 1/5] i2c: Convert i2c-octeon.c to use device tree.

2012-04-18 Thread David Daney
the legacy one? Yes, they are documented here: http://patchwork.linux-mips.org/patch/3536/ look in the cavium-i2c.txt file. Thanks, David Daney ___ devicetree-discuss mailing list devicetree-discuss@lists.ozlabs.org https://lists.ozlabs.org/listinfo

Re: [PATCH v4 3/3] netdev/of/phy: Add MDIO bus multiplexer driven by GPIO lines.

2012-04-18 Thread David Daney
) Regenerate the entire set with said patch rolled in? Thanks, David Daney ___ devicetree-discuss mailing list devicetree-discuss@lists.ozlabs.org https://lists.ozlabs.org/listinfo/devicetree-discuss

[PATCH v5 3/3] netdev/of/phy: Add MDIO bus multiplexer driven by GPIO lines.

2012-04-18 Thread David Daney
From: David Daney david.da...@cavium.com The GPIO pins select which sub bus is connected to the master. Initially tested with an sn74cbtlv3253 switch device wired into the MDIO bus. Signed-off-by: David Daney david.da...@cavium.com --- .../devicetree/bindings/net/mdio-mux-gpio.txt | 127

[PATCH v5 1/3] netdev/of/phy: New function: of_mdio_find_bus().

2012-04-18 Thread David Daney
From: David Daney david.da...@cavium.com Add of_mdio_find_bus() which allows an mii_bus to be located given its associated the device tree node. This is needed by the follow-on patch to add a driver for MDIO bus multiplexers. The of_mdiobus_register() function is modified so that the device

[PATCH v5 0/3] netdev/of/phy: MDIO bus multiplexer support.

2012-04-18 Thread David Daney
From: David Daney david.da...@cavium.com This code has been working well for about six months on a couple of different configurations (boards), so I thought it would be a good time to send it out again, and I hope get it on the path towards merging. v5: Correct Kconfig depends in 3/3 as noticed

[PATCH v5 2/3] netdev/of/phy: Add MDIO bus multiplexer support.

2012-04-18 Thread David Daney
From: David Daney david.da...@cavium.com This patch adds a somewhat generic framework for MDIO bus multiplexers. It is modeled on the I2C multiplexer. The multiplexer is needed if there are multiple PHYs with the same address connected to the same MDIO bus adepter, or if there is insufficient

Re: [PATCH v3 1/3] netdev/of/phy: New function: of_mdio_find_bus().

2012-04-17 Thread David Daney
On 04/16/2012 06:03 PM, David Daney wrote: From: David Daneydavid.da...@cavium.com Add of_mdio_find_bus() which allows an mii_bus to be located given its associated the device tree node. This is needed by the follow-on patch to add a driver for MDIO bus multiplexers. The of_mdiobus_register

[PATCH v4 0/3] netdev/of/phy: MDIO bus multiplexer support.

2012-04-17 Thread David Daney
From: David Daney david.da...@cavium.com This code has been working well for about six months on a couple of different configurations (boards), so I thought it would be a good time to send it out again, and I hope get it on the path towards merging. v4: Correct some comment text and rename

[PATCH v4 3/3] netdev/of/phy: Add MDIO bus multiplexer driven by GPIO lines.

2012-04-17 Thread David Daney
From: David Daney david.da...@cavium.com The GPIO pins select which sub bus is connected to the master. Initially tested with an sn74cbtlv3253 switch device wired into the MDIO bus. Signed-off-by: David Daney david.da...@cavium.com --- .../devicetree/bindings/net/mdio-mux-gpio.txt | 127

[PATCH v4 1/3] netdev/of/phy: New function: of_mdio_find_bus().

2012-04-17 Thread David Daney
From: David Daney david.da...@cavium.com Add of_mdio_find_bus() which allows an mii_bus to be located given its associated the device tree node. This is needed by the follow-on patch to add a driver for MDIO bus multiplexers. The of_mdiobus_register() function is modified so that the device

[PATCH v4 2/3] netdev/of/phy: Add MDIO bus multiplexer support.

2012-04-17 Thread David Daney
From: David Daney david.da...@cavium.com This patch adds a somewhat generic framework for MDIO bus multiplexers. It is modeled on the I2C multiplexer. The multiplexer is needed if there are multiple PHYs with the same address connected to the same MDIO bus adepter, or if there is insufficient

[PATCH v3 0/3] netdev/of/phy: MDIO bus multiplexer support.

2012-04-16 Thread David Daney
From: David Daney david.da...@cavium.com This code has been working well for about six months on a couple of different configurations (boards), so I thought it would be a good time to send it out again, and I hope get it on the path towards merging. v3: Update binding to use mdio-mux-gpio

[PATCH v3 1/3] netdev/of/phy: New function: of_mdio_find_bus().

2012-04-16 Thread David Daney
From: David Daney david.da...@cavium.com Add of_mdio_find_bus() which allows an mii_bus to be located given its associated the device tree node. This is needed by the follow-on patch to add a driver for MDIO bus multiplexers. The of_mdiobus_register() function is modified so that the device

[PATCH v3 2/3] netdev/of/phy: Add MDIO bus multiplexer support.

2012-04-16 Thread David Daney
From: David Daney david.da...@cavium.com This patch adds a somewhat generic framework for MDIO bus multiplexers. It is modeled on the I2C multiplexer. The multiplexer is needed if there are multiple PHYs with the same address connected to the same MDIO bus adepter, or if there is insufficient

[PATCH v3 3/3] netdev/of/phy: Add MDIO bus multiplexer driven by GPIO lines.

2012-04-16 Thread David Daney
From: David Daney david.da...@cavium.com The GPIO pins select which sub bus is connected to the master. Initially tested with an sn74cbtlv3253 switch device wired into the MDIO bus. Signed-off-by: David Daney david.da...@cavium.com --- .../devicetree/bindings/net/mdio-mux-gpio.txt | 127

Re: [PATCH 2/2] gpio/MIPS/OCTEON: Add a driver for OCTEON's on-chip GPIO pins.

2012-04-13 Thread David Daney
On 04/13/2012 02:56 AM, Florian Fainelli wrote: Hi David, [...] +/* + * The address offset of the GPIO configuration register for a given + * line. + */ +static unsigned int bit_cfg_reg(unsigned int gpio) +{ + if (gpio 16) + return 8 * gpio; + else + return 8 * (gpio - 16) + 0x100; +} You

Re: [PATCH v2 0/3] netdev/of/phy: MDIO bus multiplexer support.

2012-04-13 Thread David Daney
Pinging on this, again, as we'd like to leverage it for current and future boards. :) Today I am working on it, so I will have new patches within a couple of days. David Daney ___ devicetree-discuss mailing list devicetree-discuss@lists.ozlabs.org https

[PATCH v3 0/2] i2c/of: Populate multiplexed i2c busses from the device tree.

2012-04-12 Thread David Daney
From: David Daney david.da...@cavium.com v3: Integrate changes from Lars-Peter Clausen to make better use of the of_*() infrastructure. Get rid of ugly #ifdefs. v2: Update bindings to use reg insutead of cell-index v1: Unchanged from the original RFC where I said: We need to populate

[PATCH v3 2/2] i2c/of: Automatically populate i2c mux busses from device tree data.

2012-04-12 Thread David Daney
From: David Daney david.da...@cavium.com For 'normal' i2c bus drivers, we can call of_i2c_register_devices() and have the device tree framework automatically populate the bus with the devices specified in the device tree. This patch adds a common code to the i2c mux framework to have the mux sub

[PATCH v3 1/2] i2c: Add a struct device * parameter to i2c_add_mux_adapter()

2012-04-12 Thread David Daney
From: David Daney david.da...@cavium.com And adjust all callers. The new device parameter is used in the next patch to initialize the mux's of_node so that its children may be automatically populated. Signed-off-by: David Daney david.da...@cavium.com Cc: Lars-Peter Clausen l...@metafoo.de

[PATCH 1/2] MIPS: OCTEON: Select ARCH_REQUIRE_GPIOLIB

2012-04-12 Thread David Daney
From: David Daney david.da...@cavium.com ... and create asm/mach-cavium-octeon/gpio.h so that things continue to build. This allows us to use the existing I2C connected GPIO expanders. Signed-off-by: David Daney david.da...@cavium.com --- arch/mips/Kconfig |1

[PATCH 0/2] gpio/MIPS/OCTEON: Add GPIO support for OCTEON.

2012-04-12 Thread David Daney
From: David Daney david.da...@cavium.com There are two patches needed to add OCTEON GPIO support: 1) Select ARCH_REQUIRE_GPIOLIB. This allows standard I2C GPIO expanders to function, as well as being a prerequisite for the driver for the on-chip pins. 2) The on-chip pin driver. I'm not sure

  1   2   3   >