2023-09-28 00:04:38

by Simon Glass

[permalink] [raw]
Subject: [PATCH v4] dt-bindings: mtd: fixed-partitions: Add compression property

Sometimes the contents of a partition are compressed. Add a property to
express this and define the algorithm used.

Signed-off-by: Simon Glass <[email protected]>
---

Changes in v4:
- Add an example

Changes in v3:
- Just add a compression property for now

Changes in v2:
- Use "binman" for compatible instead of "u-boot,binman"
- Significantly rework the patch
- Use make dt_binding_check DT_SCHEMA_FILES=Documentation/../partitions

.../mtd/partitions/fixed-partitions.yaml | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)

diff --git a/Documentation/devicetree/bindings/mtd/partitions/fixed-partitions.yaml b/Documentation/devicetree/bindings/mtd/partitions/fixed-partitions.yaml
index 331e564f29dc..058253d6d889 100644
--- a/Documentation/devicetree/bindings/mtd/partitions/fixed-partitions.yaml
+++ b/Documentation/devicetree/bindings/mtd/partitions/fixed-partitions.yaml
@@ -29,6 +29,24 @@ properties:

"#size-cells": true

+ compression:
+ $ref: /schemas/types.yaml#/definitions/string
+ description: |
+ Compression algorithm used to store the data in this partition, chosen
+ from a list of well-known algorithms.
+
+ The contents are compressed using this algorithm.
+
+ enum:
+ - none
+ - bzip2
+ - gzip
+ - lzop
+ - lz4
+ - lzma
+ - xz
+ - zstd
+
patternProperties:
"@[0-9a-f]+$":
$ref: partition.yaml#
@@ -64,6 +82,7 @@ examples:

uimage@100000 {
reg = <0x0100000 0x200000>;
+ compress = "lzma";
};
};

--
2.42.0.515.g380fc7ccd1-goog


2023-10-10 13:55:08

by Rob Herring

[permalink] [raw]
Subject: Re: [PATCH v4] dt-bindings: mtd: fixed-partitions: Add compression property


On Wed, 27 Sep 2023 12:05:43 -0600, Simon Glass wrote:
> Sometimes the contents of a partition are compressed. Add a property to
> express this and define the algorithm used.
>
> Signed-off-by: Simon Glass <[email protected]>
> ---
>
> Changes in v4:
> - Add an example
>
> Changes in v3:
> - Just add a compression property for now
>
> Changes in v2:
> - Use "binman" for compatible instead of "u-boot,binman"
> - Significantly rework the patch
> - Use make dt_binding_check DT_SCHEMA_FILES=Documentation/../partitions
>
> .../mtd/partitions/fixed-partitions.yaml | 19 +++++++++++++++++++
> 1 file changed, 19 insertions(+)
>

Reviewed-by: Rob Herring <[email protected]>

2023-10-16 09:28:57

by Miquel Raynal

[permalink] [raw]
Subject: Re: [PATCH v4] dt-bindings: mtd: fixed-partitions: Add compression property

On Wed, 2023-09-27 at 18:05:43 UTC, Simon Glass wrote:
> Sometimes the contents of a partition are compressed. Add a property to
> express this and define the algorithm used.
>
> Signed-off-by: Simon Glass <[email protected]>

Applied to https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git mtd/next, thanks.

Miquel