[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20161205222521.lm7pyyjnmdi6asei@rob-hp-laptop>
Date: Mon, 5 Dec 2016 16:25:21 -0600
From: Rob Herring <robh@...nel.org>
To: Tony Lindgren <tony@...mide.com>
Cc: Lee Jones <lee.jones@...aro.org>,
Samuel Ortiz <sameo@...ux.intel.com>,
linux-kernel@...r.kernel.org, linux-omap@...r.kernel.org,
devicetree@...r.kernel.org, Marcel Partap <mpartap@....net>,
Mark Rutland <mark.rutland@....com>,
Michael Scott <michael.scott@...aro.org>
Subject: Re: [PATCHv2] mfd: cpcap: Add minimal support
On Tue, Nov 29, 2016 at 08:47:02AM -0800, Tony Lindgren wrote:
> Many Motorola phones like droid 4 are using a custom PMIC called CPCAP
> or 6556002. We can support it's core features quite easily with regmap_spi
> and regmap_irq.
>
> The children of cpcap, such as regulators, ADC and USB, can be just regular
> device drivers and defined in the dts file. They get probed as we call
> of_platform_populate() at the end of our probe, and then the children
> can just call dev_get_regmap(dev.parent, NULL) to get the regmap.
>
> Cc: devicetree@...r.kernel.org
> Cc: Marcel Partap <mpartap@....net>
> Cc: Mark Rutland <mark.rutland@....com>
> Cc: Michael Scott <michael.scott@...aro.org>
> Cc: Rob Herring <robh+dt@...nel.org>
> Signed-off-by: Tony Lindgren <tony@...mide.com>
> ---
>
> Changes from v1:
>
> - Addressed comments from Lee Jones except did not start
> generalizing bulk adding of IRQ chips. That can be done
> later as needed.
>
> - Dropped the ranges translation based on comments from
> Lee Jones and Rob Herring. We are using regmap anyways.
>
> - Changed naming to use motorola-cpcap as this is Motorola
> custom PMIC manufactured by STE and TI.
>
> - Moved the revision and vendor check to motorola-cpcap.h.
> This keeps the undocumented register bits limited to
> these functions and the child device drivers can use
> them for the related workarounds.
>
> - Checked that motorola-cpcap.h is really aligned despite
> how the patch looks for some of the lines.
>
> ---
> .../devicetree/bindings/mfd/motorola-cpcap.txt | 31 +++
> drivers/mfd/Kconfig | 11 +
> drivers/mfd/Makefile | 1 +
> drivers/mfd/motorola-cpcap.c | 244 +++++++++++++++++
> include/linux/mfd/motorola-cpcap.h | 289 +++++++++++++++++++++
> 5 files changed, 576 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/mfd/motorola-cpcap.txt
> create mode 100644 drivers/mfd/motorola-cpcap.c
> create mode 100644 include/linux/mfd/motorola-cpcap.h
>
> diff --git a/Documentation/devicetree/bindings/mfd/motorola-cpcap.txt b/Documentation/devicetree/bindings/mfd/motorola-cpcap.txt
> new file mode 100644
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/mfd/motorola-cpcap.txt
> @@ -0,0 +1,31 @@
> +Motorola CPCAP PMIC device tree binding
> +
> +Required properties:
> +- compatible : One or both of "motorola,cpcap" or "ste,6556002"
> +- reg : SPI chip select
> +- interrupt-parent : The parent interrupt controller
> +- interrupts : The interrupt line the device is connected to
> +- interrupt-controller : Marks the device node as an interrupt controller
> +- #interrupt-cells : The number of cells to describe an IRQ, should be 2
> +- #address-cells : Child device offset number of cells, typically 1
> +- #size-cells : Child device size number of cells, typically 1
> +- spi-max-frequency : Typically set to 3000000
> +- spi-cs_high : SPI chip select direction
Should be spi-cs-high.
With that:
Acked-by: Rob Herring <robh@...nel.org>
Powered by blists - more mailing lists