libfdt: Sync overlay with upstream
PATCH 1/1 libfdt: Sync overlay with upstream
Now that the overlay code has been merge upstream, update our copy to what's been merged, since a significant number of issues have been fixed during the merge process.
--- include/libfdt.h | 24 ++++-- lib/libfdt/fdt_overlay.c | 199 +++++++++++++++++++++++++++++----------------- lib/libfdt/fdt_strerror.c | 3 + 3 files changed, 147 insertions(+), 79 deletions(-)
include/libfdt.h +18 -6
@@ -79,8 +79,10 @@* (e.g. missing a leading / for a function which requires an * absolute path) */ #define FDT_ERR_BADPHANDLE 6 -/* FDT_ERR_BADPHANDLE: Function was passed an invalid phandle -* value. phandle values of 0 and -1 are not permitted. */ +/* FDT_ERR_BADPHANDLE: Function was passed an invalid phandle. +* This can be caused either by an invalid phandle property +* length, or the phandle value was either 0 or -1, which are +* not permitted. */ #define FDT_ERR_BADSTATE 7/* FDT_ERR_BADSTATE: Function was passed an incomplete device * tree created by the sequential-write functions, which is
@@ -126,12 +128,21 @@* value. For example: a property expected to contain a string list * is not NUL-terminated within the length of its value. */ -#define FDT_ERR_TOODEEP 16 +#define FDT_ERR_BADOVERLAY 16 +/* FDT_ERR_BADOVERLAY: The device tree overlay, while +* correctly structured, cannot be applied due to some +* unexpected or missing value, property or node. */ + +#define FDT_ERR_NOPHANDLES 17 +/* FDT_ERR_NOPHANDLES: The device tree doesn't have any +* phandle available anymore without causing an overflow */ + +#define FDT_ERR_TOODEEP 18/* FDT_ERR_TOODEEP: The depth of a node has exceeded the internal * libfdt limit. This can happen if you have more than * FDT_MAX_DEPTH nested nodes. */ -#define FDT_ERR_MAX 16 +#define FDT_ERR_MAX 18/**********************************************************************/ /* Low-level functions (you probably don't need these) */
@@ -1789,8 +1800,9 @@ int fdt_del_node(void *fdt, int nodeoffset);* -FDT_ERR_NOSPACE, there's not enough space in the base device tree * -FDT_ERR_NOTFOUND, the overlay points to some inexistant nodes or * properties in the base DT -* -FDT_ERR_BADPHANDLE, the phandles in the overlay do not have the right -* magic +* -FDT_ERR_BADPHANDLE, +* -FDT_ERR_BADOVERLAY, +* -FDT_ERR_NOPHANDLES, * -FDT_ERR_INTERNAL, * -FDT_ERR_BADLAYOUT, * -FDT_ERR_BADMAGIC,
lib/libfdt/fdt_overlay.c +126 -73
411 lines not on this page · raw message
lib/libfdt/fdt_strerror.c +3 -0
@@ -28,6 +28,7 @@ static struct fdt_errtabent fdt_errtable[] = {FDT_ERRTABENT (FDT_ERR_BADOFFSET ),FDT_ERRTABENT (FDT_ERR_BADPATH ), +FDT_ERRTABENT (FDT_ERR_BADPHANDLE ),FDT_ERRTABENT (FDT_ERR_BADSTATE ), FDT_ERRTABENT(FDT_ERR_TRUNCATED),
@@ -35,6 +36,8 @@ static struct fdt_errtabent fdt_errtable[] = {FDT_ERRTABENT (FDT_ERR_BADVERSION ),FDT_ERRTABENT (FDT_ERR_BADSTRUCTURE ),FDT_ERRTABENT (FDT_ERR_BADLAYOUT ), +FDT_ERRTABENT (FDT_ERR_BADOVERLAY ), + FDT_ERRTABENT(FDT_ERR_NOPHANDLES), };#define FDT_ERRTABSIZE (sizeof(fdt_errtable) / sizeof(fdt_errtable[0]))
Signature · 1 line
2.9.3
PATCH 1/1 libfdt: Sync overlay with upstream
Quoted 10 lines · Maxime Ripard
Now that the overlay code has been merge upstream, update our copy to what's been merged, since a significant number of issues have been fixed during the merge process.
Signed-off-by Maxime Ripard <[email protected]>--- include/libfdt.h | 24 ++++-- lib/libfdt/fdt_overlay.c | 199 +++++++++++++++++++++++++++++----------------- lib/libfdt/fdt_strerror.c | 3 + 3 files changed, 147 insertions(+), 79 deletions(-)
PATCH 1/1 libfdt: Sync overlay with upstream
Hi Simon,
Quoted 6 lines · Simon Glass
Quoted 4 lines · Maxime Ripard
Now that the overlay code has been merge upstream, update our copy to what's been merged, since a significant number of issues have been fixed during the merge process.
Quoted 8 lines
Quoted 6 lines
Signed-off-by Maxime Ripard <[email protected]>--- include/libfdt.h | 24 ++++-- lib/libfdt/fdt_overlay.c | 199 +++++++++++++++++++++++++++++----------------- lib/libfdt/fdt_strerror.c | 3 + 3 files changed, 147 insertions(+), 79 deletions(-)Acked-by Simon Glass <[email protected]>
Sorry for the dumb question, but shouldn't that go through your tree ?
Thanks,
Maxime
Signature · 10 lines
Maxime Ripard, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 801 bytes Desc: not available URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161018/567ced9f/attachment.sig>
PATCH 1/1 libfdt: Sync overlay with upstream
Hi Maxime,
Quoted 16 lines · Maxime Ripard
Hi Simon,
Quoted 13 lines · Simon Glass
Quoted 10 lines · Maxime Ripard
Now that the overlay code has been merge upstream, update our copy to what's been merged, since a significant number of issues have been fixed during the merge process.
Signed-off-by Maxime Ripard <[email protected]>--- include/libfdt.h | 24 ++++-- lib/libfdt/fdt_overlay.c | 199 +++++++++++++++++++++++++++++----------------- lib/libfdt/fdt_strerror.c | 3 + 3 files changed, 147 insertions(+), 79 deletions(-)
Quoted 3 lines
Quoted 1 line
Acked-by Simon Glass <[email protected]>Sorry for the dumb question, but shouldn't that go through your tree ?
Yes. Since we are at RC2 I was thinking of waiting until next cycle though. Or do you think this is urgent?
Regards,
SImon
PATCH 1/1 libfdt: Sync overlay with upstream
Hi Simon,
Quoted 20 lines · Simon Glass
Hi Maxime,
Quoted 16 lines · Maxime Ripard
Hi Simon,
Quoted 13 lines · Simon Glass
Quoted 10 lines · Maxime Ripard
Now that the overlay code has been merge upstream, update our copy to what's been merged, since a significant number of issues have been fixed during the merge process.
Signed-off-by Maxime Ripard <[email protected]>--- include/libfdt.h | 24 ++++-- lib/libfdt/fdt_overlay.c | 199 +++++++++++++++++++++++++++++----------------- lib/libfdt/fdt_strerror.c | 3 + 3 files changed, 147 insertions(+), 79 deletions(-)
Quoted 6 lines
Quoted 3 lines
Quoted 1 line
Acked-by Simon Glass <[email protected]>Sorry for the dumb question, but shouldn't that go through your tree ?
Yes. Since we are at RC2 I was thinking of waiting until next cycle though. Or do you think this is urgent?
I'd be enclined to say yes. It really contains a significant number of fixes for some cases that might definitely be used in real life, so it totally counts as a fix for me.
And since the changes are well contained, and it passes the tests both in dtc and in U-Boot, I'd say that it's pretty safe to merge.
Thanks!
Maxime
Signature · 10 lines
Maxime Ripard, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 801 bytes Desc: not available URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161019/43552052/attachment.sig>
PATCH 1/1 libfdt: Sync overlay with upstream
Quoted 30 lines · Maxime Ripard
Hi Simon,
Quoted 20 lines · Simon Glass
Hi Maxime,
Quoted 16 lines · Maxime Ripard
Hi Simon,
Quoted 13 lines · Simon Glass
Quoted 10 lines · Maxime Ripard
Now that the overlay code has been merge upstream, update our copy to what's been merged, since a significant number of issues have been fixed during the merge process.
Signed-off-by Maxime Ripard <[email protected]>--- include/libfdt.h | 24 ++++-- lib/libfdt/fdt_overlay.c | 199 +++++++++++++++++++++++++++++----------------- lib/libfdt/fdt_strerror.c | 3 + 3 files changed, 147 insertions(+), 79 deletions(-)Quoted 6 lines
Quoted 3 lines
Quoted 1 line
Acked-by Simon Glass <[email protected]>Sorry for the dumb question, but shouldn't that go through your tree ?
Yes. Since we are at RC2 I was thinking of waiting until next cycle though. Or do you think this is urgent?
Quoted 6 lines
I'd be enclined to say yes. It really contains a significant number of fixes for some cases that might definitely be used in real life, so it totally counts as a fix for me.
And since the changes are well contained, and it passes the tests both in dtc and in U-Boot, I'd say that it's pretty safe to merge.
Applied to u-boot-fdt, thanks!