lkml.org 
[lkml]   [2022]   [May]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH v3 2/3] dt-bindings: mtd: partitions: Extend fixed-partitions binding
    Date
    Extend fixed-partitions binding for support of Sercomm partition parser
    (add "sercomm,sc-partitions" compatible).

    Signed-off-by: Mikhail Zhilkin <csharper2005@gmail.com>
    ---
    .../mtd/partitions/fixed-partitions.yaml | 55 ++++++++++++++++++-
    1 file changed, 53 insertions(+), 2 deletions(-)

    diff --git a/Documentation/devicetree/bindings/mtd/partitions/fixed-partitions.yaml b/Documentation/devicetree/bindings/mtd/partitions/fixed-partitions.yaml
    index ea4cace6a955..ad3ccd250802 100644
    --- a/Documentation/devicetree/bindings/mtd/partitions/fixed-partitions.yaml
    +++ b/Documentation/devicetree/bindings/mtd/partitions/fixed-partitions.yaml
    @@ -19,7 +19,11 @@ maintainers:

    properties:
    compatible:
    - const: fixed-partitions
    + oneOf:
    + - const: fixed-partitions
    + - items:
    + - const: sercomm,sc-partitions
    + - const: fixed-partitions

    "#address-cells": true

    @@ -27,7 +31,24 @@ properties:

    patternProperties:
    "@[0-9a-f]+$":
    - $ref: "partition.yaml#"
    + allOf:
    + - $ref: "partition.yaml#"
    + - if:
    + properties:
    + compatible:
    + contains:
    + const: sercomm,sc-partitions
    + then:
    + properties:
    + sercomm,scpart-id:
    + description: Partition id in Sercomm partition map. Mtd
    + parser uses this id to find a record in the partition map
    + containing offset and size of the current partition. The
    + values from partition map overrides partition offset and
    + size defined in reg property of the dts. Frequently these
    + values are the same, but may differ if device has bad
    + eraseblocks on a flash.
    + $ref: /schemas/types.yaml#/definitions/uint32

    required:
    - "#address-cells"
    @@ -52,6 +73,7 @@ examples:
    reg = <0x0100000 0x200000>;
    };
    };
    +
    - |
    partitions {
    compatible = "fixed-partitions";
    @@ -64,6 +86,7 @@ examples:
    reg = <0x00000000 0x1 0x00000000>;
    };
    };
    +
    - |
    partitions {
    compatible = "fixed-partitions";
    @@ -82,6 +105,7 @@ examples:
    reg = <0x2 0x00000000 0x1 0x00000000>;
    };
    };
    +
    - |
    partitions {
    compatible = "fixed-partitions";
    @@ -119,3 +143,30 @@ examples:
    };
    };
    };
    +
    + - |
    + partitions {
    + compatible = "sercomm,sc-partitions", "fixed-partitions";
    + #address-cells = <1>;
    + #size-cells = <1>;
    +
    + partition@0 {
    + label = "u-boot";
    + reg = <0x0 0x100000>;
    + sercomm,scpart-id = <0>;
    + read-only;
    + };
    +
    + partition@100000 {
    + label = "dynamic partition map";
    + reg = <0x100000 0x100000>;
    + sercomm,scpart-id = <1>;
    + };
    +
    + partition@200000 {
    + label = "Factory";
    + reg = <0x200000 0x100000>;
    + sercomm,scpart-id = <2>;
    + read-only;
    + };
    + };
    --
    2.25.1
    \
     
     \ /
      Last update: 2022-05-03 17:52    [W:3.264 / U:0.004 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site