| #
1a4f6af8 |
| 02-Mar-2020 |
Joseph Chen <chenjh@rock-chips.com> |
Merge branch 'next-dev' into thunder-boot
|
| #
2eb7260f |
| 03-Dec-2019 |
Joseph Chen <chenjh@rock-chips.com> |
cmd: fdt: use gd->fdt_blob as default fdt address
Signed-off-by: Joseph Chen <chenjh@rock-chips.com> Change-Id: I16a413bcbca17842cd560367ebae6454a63354f2
|
| #
0e00a84c |
| 04-Mar-2018 |
Masahiro Yamada <yamada.masahiro@socionext.com> |
UPSTREAM: libfdt: move headers to <linux/libfdt.h> and <linux/libfdt_env.h>
Thomas reported U-Boot failed to build host tools if libfdt-devel package is installed because tools include libfdt header
UPSTREAM: libfdt: move headers to <linux/libfdt.h> and <linux/libfdt_env.h>
Thomas reported U-Boot failed to build host tools if libfdt-devel package is installed because tools include libfdt headers from /usr/include/ instead of using internal ones.
This commit moves the header code: include/libfdt.h -> include/linux/libfdt.h include/libfdt_env.h -> include/linux/libfdt_env.h
and replaces include directives: #include <libfdt.h> -> #include <linux/libfdt.h> #include <libfdt_env.h> -> #include <linux/libfdt_env.h>
Change-Id: I6c0f7e50e8b571106627f25ddac008a62bd2994e Reported-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
show more ...
|
| #
853f31c4 |
| 28-Sep-2017 |
Bernhard Messerklinger <bernhard.messerklinger@br-automation.com> |
UPSTREAM: cmd/fdt.c align data buffer to avoid unaligned word access
Since the compiler is free to place a char array to any address in memory (in this case the stack), also to a non word aligned ad
UPSTREAM: cmd/fdt.c align data buffer to avoid unaligned word access
Since the compiler is free to place a char array to any address in memory (in this case the stack), also to a non word aligned address the function "fdt_prop_parse" runs into troubles upon it wants to write some (fdt32_t *) to such a variable (if it has been placed to a none word aligned address).
To avoid this we tell the compiler to always align this scratchpad to a word aligned address.
Change-Id: I6ea64827a9c245db4ba2a2ff522aaddea647c2f2 Signed-off-by: Bernhard Messerklinger <bernhard.messerklinger@br-automation.com> Reviewed-by: Hannes Schmelzer <oe5hpm@oevsv.at> Tested-by: Hannes Schmelzer <oe5hpm@oevsv.at> Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Kever Yang <kever.yang@rock-chips.com> (cherry picked from commit 6dfd65f81fd060a85c961a84f85a286e8e96332c)
show more ...
|
| #
7c95a495 |
| 04-Sep-2017 |
Pantelis Antoniou <pantelis.antoniou@konsulko.com> |
UPSTREAM: fdt: Switch to using the verbose overlay application method
The verbose overlay application method prints out more helpful messages, so switch to it.
Change-Id: Ie8bd31e939e3c12fe547028d0
UPSTREAM: fdt: Switch to using the verbose overlay application method
The verbose overlay application method prints out more helpful messages, so switch to it.
Change-Id: Ie8bd31e939e3c12fe547028d0fa3ddc8b254d33d Signed-off-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com> Acked-by: Simon Glass <sjg@chromium.org> Signed-off-by: Kever Yang <kever.yang@rock-chips.com> (cherry picked from commit 81ecc5d92badfcf1415a6052b5896a62271a94dc)
show more ...
|
| #
ced0fd93 |
| 04-Sep-2017 |
Tom Rini <trini@konsulko.com> |
Merge git://git.denx.de/u-boot-dm
|
| #
cee8c35d |
| 18-Aug-2017 |
Hannes Schmelzer <oe5hpm@oevsv.at> |
fdt: fix 'prop (...) not found!' error in 'fdt set' command
This commit brings things back to the well known working state of the command. - With commit 9620d87259572ef21f0df60988d9a932ca673779 (cmd
fdt: fix 'prop (...) not found!' error in 'fdt set' command
This commit brings things back to the well known working state of the command. - With commit 9620d87259572ef21f0df60988d9a932ca673779 (cmd/fdt: support single value replacement within an array)
there was an error introduced modifying (inserting) a property to a device-tree node. fdt_getprop(...) returnes a len with -1 for a non-existing property, but a memcpy with len -1 isn't a good idea and things went wrong (crash). - Some times later Tom did repair this with commit 99bb38e2cce9d99238458e0f6d1880c6d2e80a4d (fdt: Check for NULL return from fdt_getprop in 'fdt set')
This repairs the crash but the behaviour of the command isn't like before, it makes it impossible to insert a property. -
Signed-off-by: Hannes Schmelzer <oe5hpm@oevsv.at> Acked-by: Simon Glass <sjg@chromium.org>
show more ...
|
| #
bfebc8c9 |
| 03-Aug-2017 |
Simon Glass <sjg@chromium.org> |
env: Rename getenv_hex(), getenv_yesno(), getenv_ulong()
We are now using an env_ prefix for environment functions. Rename these for consistency. Also add function comments in common.h.
Suggested-b
env: Rename getenv_hex(), getenv_yesno(), getenv_ulong()
We are now using an env_ prefix for environment functions. Rename these for consistency. Also add function comments in common.h.
Suggested-by: Wolfgang Denk <wd@denx.de> Signed-off-by: Simon Glass <sjg@chromium.org>
show more ...
|
| #
018f5303 |
| 03-Aug-2017 |
Simon Glass <sjg@chromium.org> |
env: Rename common functions related to setenv()
We are now using an env_ prefix for environment functions. Rename these commonly used functions, for consistency. Also add function comments in commo
env: Rename common functions related to setenv()
We are now using an env_ prefix for environment functions. Rename these commonly used functions, for consistency. Also add function comments in common.h.
Suggested-by: Wolfgang Denk <wd@denx.de> Signed-off-by: Simon Glass <sjg@chromium.org>
show more ...
|
| #
382bee57 |
| 03-Aug-2017 |
Simon Glass <sjg@chromium.org> |
env: Rename setenv() to env_set()
We are now using an env_ prefix for environment functions. Rename setenv() for consistency. Also add function comments in common.h.
Suggested-by: Wolfgang Denk <wd
env: Rename setenv() to env_set()
We are now using an env_ prefix for environment functions. Rename setenv() for consistency. Also add function comments in common.h.
Suggested-by: Wolfgang Denk <wd@denx.de> Signed-off-by: Simon Glass <sjg@chromium.org>
show more ...
|
| #
8d3a2568 |
| 12-Jul-2017 |
Tom Rini <trini@konsulko.com> |
Merge git://git.denx.de/u-boot-dm
|
| #
99bb38e2 |
| 13-Jun-2017 |
Tom Rini <trini@konsulko.com> |
fdt: Check for NULL return from fdt_getprop in 'fdt set'
While the previous pass through fixed one place where we knew that fdt_getprop would be given a positive len, in the case of 'fdt set' we do
fdt: Check for NULL return from fdt_getprop in 'fdt set'
While the previous pass through fixed one place where we knew that fdt_getprop would be given a positive len, in the case of 'fdt set' we do not, so check that we did no get NULL from fdt_getprop().
Cc: Simon Glass <sjg@chromium.org> Reported-by: Coverity (CID: 163249) Fixes 72c98ed1ab48 ("fdt: Add a check to do_fdt() for coverity") Signed-off-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
show more ...
|
| #
9f952672 |
| 07-Jun-2017 |
Simon Glass <sjg@chromium.org> |
fdt: Add a check to fdt_print() for coverity
We know that fdt_getprop() does not return NULL when len is > 0 but coverity does not. Add an extra check to keep it happy.
Signed-off-by: Simon Glass <
fdt: Add a check to fdt_print() for coverity
We know that fdt_getprop() does not return NULL when len is > 0 but coverity does not. Add an extra check to keep it happy.
Signed-off-by: Simon Glass <sjg@chromium.org> Reported-by: Coverity (CID: 163248)
show more ...
|
| #
72c98ed1 |
| 07-Jun-2017 |
Simon Glass <sjg@chromium.org> |
fdt: Add a check to do_fdt() for coverity
We know that fdt_getprop() does not return NULL when len is > 0 but coverity does not. Add an extra check to keep it happy.
Signed-off-by: Simon Glass <sjg
fdt: Add a check to do_fdt() for coverity
We know that fdt_getprop() does not return NULL when len is > 0 but coverity does not. Add an extra check to keep it happy.
Signed-off-by: Simon Glass <sjg@chromium.org> Reported-by: Coverity (CID: 163249) Fixes: bc80295b (fdt: Add get commands to fdt)
show more ...
|
| #
8cb3ce64 |
| 10-Jun-2017 |
Tom Rini <trini@konsulko.com> |
Merge git://git.denx.de/u-boot-dm
|
| #
9620d872 |
| 30-May-2017 |
Hannes Schmelzer <Hannes.Schmelzer@br-automation.com> |
cmd/fdt: support single value replacement within an array
With this commit we can modify single values within an array of a dts property.
This is useful if we have for example a pwm-backlight where
cmd/fdt: support single value replacement within an array
With this commit we can modify single values within an array of a dts property.
This is useful if we have for example a pwm-backlight where we want to modifiy the pwm frequency per u-boot script.
The pwm is described in dts like this:
backlight { pwms = <0x0000002b 0x00000000 0x004c4b40>; };
For changing the frequency, here the 3rd parameter, we simply type:
fdt set /backlight pwms <? ? 0x1E8480>;
For doing all this we: - backup the property content into our 'SCRATCHPAD' - only modify the array-cell if the new content doesn't start with '?'
Signed-off-by: Hannes Schmelzer <hannes.schmelzer@br-automation.com> Reviewed-by: Simon Glass <sjg@chromium.org>
show more ...
|
| #
5d927b42 |
| 17-May-2017 |
Simon Glass <sjg@chromium.org> |
Kconfig: Drop CONFIG_CMD_FDT_MAX_DUMP
This option is not used by any board. Drop it.
Signed-off-by: Simon Glass <sjg@chromium.org>
|
| #
b7127e3c |
| 14-Jan-2017 |
Tom Rini <trini@konsulko.com> |
Merge git://git.denx.de/u-boot-fdt
|
| #
b05bf6c7 |
| 09-Jan-2017 |
Andreas Färber <afaerber@suse.de> |
cmd/fdt: Make fdt get value endian-safe for single-cell properties
On a Raspberry Pi 2 disagreements on cell endianness can be observed:
U-Boot> fdt print /soc/gpio@7e200000 phandle phandle = <
cmd/fdt: Make fdt get value endian-safe for single-cell properties
On a Raspberry Pi 2 disagreements on cell endianness can be observed:
U-Boot> fdt print /soc/gpio@7e200000 phandle phandle = <0x0000000d> U-Boot> fdt get value myvar /soc/gpio@7e200000 phandle; printenv myvar myvar=0x0D000000
Fix this by always treating the pointer as BE and converting it in fdt_value_setenv(), like its counterpart fdt_parse_prop() already does.
Consistently use fdt32_t, fdt32_to_cpu() and cpu_to_fdt32().
Fixes: bc80295 ("fdt: Add get commands to fdt") Cc: Joe Hershberger <joe.hershberger@ni.com> Cc: Gerald Van Baren <gvb@unssw.com> Signed-off-by: Andreas Färber <afaerber@suse.de> Acked-by: Simon Glass <sjg@chromium.org>
show more ...
|
| #
082b1414 |
| 20-Dec-2016 |
Stefan Agner <stefan.agner@toradex.com> |
cmd: fdt: Print error message when fdt application fails
There are lots of reason why a FDT application might fail, the error code might give an indication. Let the error code translate in a error s
cmd: fdt: Print error message when fdt application fails
There are lots of reason why a FDT application might fail, the error code might give an indication. Let the error code translate in a error string so users can try to understand what went wrong.
Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com> Acked-by: Simon Glass <sjg@chromium.org>
show more ...
|
| #
73eed452 |
| 04-Dec-2016 |
Tom Rini <trini@konsulko.com> |
Merge branch 'master' of git://www.denx.de/git/u-boot-dm
|
| #
f7f191ee |
| 24-Nov-2016 |
Fabien Parent <fparent@baylibre.com> |
cmd/fdt: fix uncallable systemsetup command
The function that is processing the 'fdt' parameters is one big if-else if. In order to be able to type command faster only the first few letter are check
cmd/fdt: fix uncallable systemsetup command
The function that is processing the 'fdt' parameters is one big if-else if. In order to be able to type command faster only the first few letter are checked to know which block of code to execute. For systemsetup, the block of code that was executed was always the wrong one and ended up in a failure.
} else if (argv[1][0] == 's') { process "fdt set" command } else if (strncmp(argv[1], "sys", 3) == 0) { process "fdt systemsetup" command. }
When typing "fdt systemsetup", the code that was executed was the code for "fdt set".
This commit fix this issue by moving the "else if" for systemsetup before the else if for "fdt set". This allow us to keep compatibility with any script that make use of "fdt s" to set node values.
Signed-off-by: Fabien Parent <fparent@baylibre.com> Acked-by: Simon Glass <sjg@chromium.org>
show more ...
|
| #
4504062b |
| 14-Oct-2016 |
Tom Rini <trini@konsulko.com> |
Merge git://git.denx.de/u-boot-fdt
|
| #
ef476836 |
| 20-Sep-2016 |
Hannes Schmelzer <hannes.schmelzer@br-automation.com> |
cmd/fdt: add possibilty to have 'extrasize' on fdt resize
Sometimes devicetree nodes and or properties are added out of the u-boot console, maybe through some script or manual interaction.
The devi
cmd/fdt: add possibilty to have 'extrasize' on fdt resize
Sometimes devicetree nodes and or properties are added out of the u-boot console, maybe through some script or manual interaction.
The devicetree as loaded or embedded is quite small, so the devicetree has to be resized to take up those new nodes/properties.
In original the devicetree was only extended by effective 4 * add_mem_rsv.
With this commit we can add an argument to the "fdt resize" command, which takes the extrasize to be added.
Signed-off-by: Hannes Schmelzer <hannes.schmelzer@br-automation.com>
Signed-off-by: Hannes Schmelzer <oe5hpm@oevsv.at> Acked-by: Simon Glass <sjg@chromium.org>
show more ...
|
| #
e6628ad7 |
| 05-Jul-2016 |
Maxime Ripard <maxime.ripard@free-electrons.com> |
cmd: fdt: add fdt overlay application subcommand
The device tree overlays are a good way to deal with user-modifyable boards or boards with some kind of an expansion mechanism where we can easily pl
cmd: fdt: add fdt overlay application subcommand
The device tree overlays are a good way to deal with user-modifyable boards or boards with some kind of an expansion mechanism where we can easily plug new board in (like the BBB or the raspberry pi).
However, so far, the usual mechanism to deal with it was to have in Linux some driver detecting the expansion boards plugged in and then request these overlays using the firmware interface.
That works in most cases, but in some cases, you might want to have the overlays applied before the userspace comes in. Either because the new board requires some kind of an early initialization, or because your root filesystem is accessed through that expansion board.
The easiest solution in such a case is to simply have the component before Linux applying that overlay, removing all these drawbacks.
Reviewed-by: Stefan Agner <stefan@agner.ch> Acked-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com> Acked-by: Simon Glass <sjg@chromium.org> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
show more ...
|