All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rob Herring <robh+dt@kernel.org>
To: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>,
	devicetree@vger.kernel.org,
	"maintainer:BROADCOM BCM7XXX ARM ARCHITECTURE" 
	<bcm-kernel-feedback-list@broadcom.com>,
	"moderated list:BROADCOM BCM2835 ARM ARCHITECTURE" 
	<linux-rpi-kernel@lists.infradead.org>,
	linux-arm-kernel <linux-arm-kernel@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Russell King <linux@armlinux.org.uk>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will@kernel.org>,
	Tim Gover <tim.gover@raspberrypi.com>,
	Phil Elwell <phil@raspberrypi.com>
Subject: Re: [PATCH 1/6] dt-bindings: nvmem: Add bindings for rmem driver
Date: Tue, 15 Dec 2020 14:25:34 -0600	[thread overview]
Message-ID: <CAL_JsqK7zZdWi0orXoqPWqvvxP3H6n7=JRqhdeAiAYAHRS3WHQ@mail.gmail.com> (raw)
In-Reply-To: <20201215155627.2513-2-nsaenzjulienne@suse.de>

On Tue, Dec 15, 2020 at 9:56 AM Nicolas Saenz Julienne
<nsaenzjulienne@suse.de> wrote:
>
> Firmware/co-processors might use reserved memory areas in order to pass
> data stemming from an nvmem device otherwise non accessible to Linux.
> For example an EEPROM memory only physically accessible to firmware, or
> data only accessible early at boot time.
>
> Introduce the dt-bindings to nvmem's rmem.
>
> Signed-off-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
> ---
>  .../devicetree/bindings/nvmem/rmem.yaml       | 35 +++++++++++++++++++
>  1 file changed, 35 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/nvmem/rmem.yaml
>
> diff --git a/Documentation/devicetree/bindings/nvmem/rmem.yaml b/Documentation/devicetree/bindings/nvmem/rmem.yaml
> new file mode 100644
> index 000000000000..3037ebc4634d
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/nvmem/rmem.yaml
> @@ -0,0 +1,35 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/nvmem/rmem.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Reserved Memory Based nvmem Device
> +
> +maintainers:
> +  - Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
> +
> +properties:
> +  compatible:
> +    enum:
> +      - nvmem-rmem
> +
> +  memory-region:
> +    $ref: /schemas/types.yaml#/definitions/phandle
> +    description:
> +      phandle to the reserved memory region

There's no need for this indirection. Just add a compatible to the
reserved-memory node. See ramoops for example.

Please make the compatible specific enough to define what the memory
contains. If you want 'nvmem-rmem' as a fallback that's fine.

> +
> +required:
> +  - compatible
> +  - memory-region
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +        fw-config {
> +                compatible = "nvmem-rmem";
> +                memory-region = <&mem>;
> +        };
> +
> +...
> --
> 2.29.2
>

WARNING: multiple messages have this Message-ID (diff)
From: Rob Herring <robh+dt@kernel.org>
To: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
Cc: devicetree@vger.kernel.org, Tim Gover <tim.gover@raspberrypi.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Russell King <linux@armlinux.org.uk>,
	Srinivas Kandagatla <srinivas.kandagatla@linaro.org>,
	"moderated list:BROADCOM BCM2835 ARM ARCHITECTURE"
	<linux-rpi-kernel@lists.infradead.org>,
	"maintainer:BROADCOM BCM7XXX ARM ARCHITECTURE"
	<bcm-kernel-feedback-list@broadcom.com>,
	Will Deacon <will@kernel.org>, Phil Elwell <phil@raspberrypi.com>,
	linux-arm-kernel <linux-arm-kernel@lists.infradead.org>
Subject: Re: [PATCH 1/6] dt-bindings: nvmem: Add bindings for rmem driver
Date: Tue, 15 Dec 2020 14:25:34 -0600	[thread overview]
Message-ID: <CAL_JsqK7zZdWi0orXoqPWqvvxP3H6n7=JRqhdeAiAYAHRS3WHQ@mail.gmail.com> (raw)
In-Reply-To: <20201215155627.2513-2-nsaenzjulienne@suse.de>

On Tue, Dec 15, 2020 at 9:56 AM Nicolas Saenz Julienne
<nsaenzjulienne@suse.de> wrote:
>
> Firmware/co-processors might use reserved memory areas in order to pass
> data stemming from an nvmem device otherwise non accessible to Linux.
> For example an EEPROM memory only physically accessible to firmware, or
> data only accessible early at boot time.
>
> Introduce the dt-bindings to nvmem's rmem.
>
> Signed-off-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
> ---
>  .../devicetree/bindings/nvmem/rmem.yaml       | 35 +++++++++++++++++++
>  1 file changed, 35 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/nvmem/rmem.yaml
>
> diff --git a/Documentation/devicetree/bindings/nvmem/rmem.yaml b/Documentation/devicetree/bindings/nvmem/rmem.yaml
> new file mode 100644
> index 000000000000..3037ebc4634d
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/nvmem/rmem.yaml
> @@ -0,0 +1,35 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/nvmem/rmem.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Reserved Memory Based nvmem Device
> +
> +maintainers:
> +  - Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
> +
> +properties:
> +  compatible:
> +    enum:
> +      - nvmem-rmem
> +
> +  memory-region:
> +    $ref: /schemas/types.yaml#/definitions/phandle
> +    description:
> +      phandle to the reserved memory region

There's no need for this indirection. Just add a compatible to the
reserved-memory node. See ramoops for example.

Please make the compatible specific enough to define what the memory
contains. If you want 'nvmem-rmem' as a fallback that's fine.

> +
> +required:
> +  - compatible
> +  - memory-region
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +        fw-config {
> +                compatible = "nvmem-rmem";
> +                memory-region = <&mem>;
> +        };
> +
> +...
> --
> 2.29.2
>

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2020-12-15 20:27 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-15 15:56 [PATCH 0/6] Expose RPi4'd bootloader configuration Nicolas Saenz Julienne
2020-12-15 15:56 ` Nicolas Saenz Julienne
2020-12-15 15:56 ` [PATCH 1/6] dt-bindings: nvmem: Add bindings for rmem driver Nicolas Saenz Julienne
2020-12-15 15:56   ` Nicolas Saenz Julienne
2020-12-15 20:25   ` Rob Herring [this message]
2020-12-15 20:25     ` Rob Herring
2020-12-15 21:16     ` Nicolas Saenz Julienne
2020-12-15 21:16       ` Nicolas Saenz Julienne
2020-12-15 15:56 ` [PATCH 2/6] nvmem: Add driver to expose reserved memory as nvmem Nicolas Saenz Julienne
2020-12-15 15:56   ` Nicolas Saenz Julienne
2020-12-15 15:56 ` [PATCH 3/6] ARM: dts: bcm2711: Add reserved memory template to hold firmware configuration Nicolas Saenz Julienne
2020-12-15 15:56   ` Nicolas Saenz Julienne
2020-12-15 20:27   ` Rob Herring
2020-12-15 20:27     ` Rob Herring
2020-12-15 15:56 ` [PATCH 4/6] ARM: dts: bcm2711: Expose boot-loader configuration Nicolas Saenz Julienne
2020-12-15 15:56   ` Nicolas Saenz Julienne
2020-12-15 15:56 ` [PATCH 5/6] arm64: defconfig: Enable nvmem's rmem driver Nicolas Saenz Julienne
2020-12-15 15:56   ` Nicolas Saenz Julienne
2020-12-15 15:56 ` [PATCH 6/6] ARM: multi_v7_defconfig: " Nicolas Saenz Julienne
2020-12-15 15:56   ` Nicolas Saenz Julienne
2020-12-15 16:05 ` [PATCH 0/6] Expose RPi4'd bootloader configuration Nicolas Saenz Julienne
2020-12-15 16:05   ` Nicolas Saenz Julienne
2020-12-15 18:44 ` Catalin Marinas
2020-12-15 18:44   ` Catalin Marinas
2020-12-15 19:01   ` Nicolas Saenz Julienne
2020-12-15 19:01     ` Nicolas Saenz Julienne
2020-12-15 19:54     ` Rob Herring
2020-12-15 19:54       ` Rob Herring
2020-12-15 21:21       ` Nicolas Saenz Julienne
2020-12-15 21:21         ` Nicolas Saenz Julienne

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='CAL_JsqK7zZdWi0orXoqPWqvvxP3H6n7=JRqhdeAiAYAHRS3WHQ@mail.gmail.com' \
    --to=robh+dt@kernel.org \
    --cc=bcm-kernel-feedback-list@broadcom.com \
    --cc=catalin.marinas@arm.com \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rpi-kernel@lists.infradead.org \
    --cc=linux@armlinux.org.uk \
    --cc=nsaenzjulienne@suse.de \
    --cc=phil@raspberrypi.com \
    --cc=srinivas.kandagatla@linaro.org \
    --cc=tim.gover@raspberrypi.com \
    --cc=will@kernel.org \
    /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: link
Be 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.