mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-18 10:48:51 +00:00
da39341223
This existing code assumes that a reg property is larger than one cell, but this is not always the case. Fix this assumption. Also if a node's parent is missing the #address-cells and #size-cells properties we use 2 as a default for each. But this should not happen in practice. More likely the properties were removed for SPL due to there being no 'u-boot,dm-pre-reloc' property, or similar. Add a warning for this as the failure can be very confusing. Signed-off-by: Simon Glass <sjg@chromium.org>
30 lines
435 B
Text
30 lines
435 B
Text
// SPDX-License-Identifier: GPL-2.0+
|
|
/*
|
|
* Test device tree file for dtoc
|
|
*
|
|
* Copyright 2017 Google, Inc
|
|
*/
|
|
|
|
/dts-v1/;
|
|
|
|
/ {
|
|
#address-cells = <1>;
|
|
#size-cells = <1>;
|
|
|
|
i2c@0 {
|
|
compatible = "sandbox,i2c";
|
|
u-boot,dm-pre-reloc;
|
|
#address-cells = <1>;
|
|
#size-cells = <0>;
|
|
pmic@9 {
|
|
compatible = "sandbox,pmic";
|
|
u-boot,dm-pre-reloc;
|
|
reg = <9>;
|
|
low-power;
|
|
|
|
gpio {
|
|
compatible = "sandbox,gpio";
|
|
};
|
|
};
|
|
};
|
|
};
|