dts/x86: use proper unit-address values
This commit changes the way some x86 devicetree set the unit-address values of memory nodes. Before the change, they were always set to `0`. After the change, they are derived from the `DT_DRAM_BASE` macro to match the first address specified by the reg property. Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
This commit is contained in:
parent
d37ae60751
commit
0edc89c63b
3 changed files with 6 additions and 5 deletions
|
|
@ -31,9 +31,9 @@
|
|||
zephyr,shell-uart = &uart0;
|
||||
};
|
||||
|
||||
dram0: memory@0 {
|
||||
dram0: memory@DT_DRAM_BASE {
|
||||
device_type = "memory";
|
||||
reg = <DT_DRAM_BASE DT_DRAM_SIZE>;
|
||||
reg = <DT_ADDR(DT_DRAM_BASE) DT_DRAM_SIZE>;
|
||||
};
|
||||
|
||||
soc {
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
#define DT_DRAM_BASE 0x100000
|
||||
/* Note: this is the unit-address (in hex) of the node */
|
||||
#define DT_DRAM_BASE 100000
|
||||
#define DT_DRAM_SIZE DT_SIZE_K(256)
|
||||
#include "qemu_x86.dts"
|
||||
|
|
|
|||
|
|
@ -36,9 +36,9 @@
|
|||
#address-cells = <1>;
|
||||
};
|
||||
|
||||
dram0: memory@0 {
|
||||
dram0: memory@DT_DRAM_BASE {
|
||||
device_type = "memory";
|
||||
reg = <DT_DRAM_BASE DT_DRAM_SIZE>;
|
||||
reg = <DT_ADDR(DT_DRAM_BASE) DT_DRAM_SIZE>;
|
||||
};
|
||||
|
||||
soc {
|
||||
|
|
|
|||
Loading…
Reference in a new issue