]> git.dujemihanovic.xyz Git - u-boot.git/commit
pstore: Use root address-cells/size-cells as defaults for reserved-memory
authorAndrey Skvortsov <andrej.skvortzov@gmail.com>
Sat, 26 Aug 2023 12:16:52 +0000 (15:16 +0300)
committerTom Rini <trini@konsulko.com>
Tue, 24 Oct 2023 20:34:45 +0000 (16:34 -0400)
commit9859edd3fc10ffb63f53e1d21aa6eb34b688f6da
tree36c3dce94006e1b965190ee0cf5d81dbf6819855
parent801c482207c71425666da759b447a1d1d4e62786
pstore: Use root address-cells/size-cells as defaults for reserved-memory

u-boot adds reserve-memory node, if it's missing, with following
properties:

```
    reserved-memory {
         #address-cells = <2>;
         #size-cells = <2>;
         ranges;
    }
```

But with these default address-cells and size-cells values, pstore
isn't working on A64. Root node for A64 defines 'address-cells' and
'size-cells' as 1.

dtc complains if reserved-memory has different address-cells and
size-cells.

```
     Warning (ranges_format): /reserved-memory:ranges: empty "ranges"
     property but its #address-cells (2) differs from / (1)
```

This patch takes into account address-cells and size-cells of the root
node and uses them as values for new reserved-memory node.

Signed-off-by: Andrey Skvortsov <andrej.skvortzov@gmail.com>
cmd/pstore.c