* [PATCH] octeontx: do not require cavium BDK node to be present
@ 2021-06-17 23:31 Tim Harvey
2021-06-18 6:04 ` Stefan Roese
2021-07-09 5:19 ` Stefan Roese
0 siblings, 2 replies; 3+ messages in thread
From: Tim Harvey @ 2021-06-17 23:31 UTC (permalink / raw)
To: Aaron Williams; +Cc: Stefan Roese, Suneel Garapati, u-boot, Tim Harvey
The cavium,bdk node is a non-standard dt node used by the BDK and
therefore it is removed from the dt before booting Linux. Do not
require this node to exist as it won't for standard dt's.
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
---
board/Marvell/octeontx/board-fdt.c | 20 ++++++++------------
1 file changed, 8 insertions(+), 12 deletions(-)
diff --git a/board/Marvell/octeontx/board-fdt.c b/board/Marvell/octeontx/board-fdt.c
index 0b05ef11e9..1db2a4a267 100644
--- a/board/Marvell/octeontx/board-fdt.c
+++ b/board/Marvell/octeontx/board-fdt.c
@@ -281,20 +281,16 @@ int ft_board_setup(void *blob, struct bd_info *bd)
}
if (blob) {
+ /* delete cavium,bdk node if it exists */
offset = fdt_path_offset(blob, "/cavium,bdk");
- if (offset < 0) {
- printf("ERROR: FDT BDK node not found\n");
- return offset;
- }
-
- /* delete node */
- ret = fdt_del_node(blob, offset);
- if (ret < 0) {
- printf("WARNING : could not remove bdk node\n");
- return ret;
+ if (offset >= 0) {
+ ret = fdt_del_node(blob, offset);
+ if (ret < 0) {
+ printf("WARNING : could not remove bdk node\n");
+ return ret;
+ }
+ debug("%s deleted bdk node\n", __func__);
}
-
- debug("%s deleted bdk node\n", __func__);
}
return 0;
--
2.17.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] octeontx: do not require cavium BDK node to be present
2021-06-17 23:31 [PATCH] octeontx: do not require cavium BDK node to be present Tim Harvey
@ 2021-06-18 6:04 ` Stefan Roese
2021-07-09 5:19 ` Stefan Roese
1 sibling, 0 replies; 3+ messages in thread
From: Stefan Roese @ 2021-06-18 6:04 UTC (permalink / raw)
To: Tim Harvey, Aaron Williams; +Cc: Suneel Garapati, u-boot
On 18.06.21 01:31, Tim Harvey wrote:
> The cavium,bdk node is a non-standard dt node used by the BDK and
> therefore it is removed from the dt before booting Linux. Do not
> require this node to exist as it won't for standard dt's.
>
> Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Thanks,
Stefan
> ---
> board/Marvell/octeontx/board-fdt.c | 20 ++++++++------------
> 1 file changed, 8 insertions(+), 12 deletions(-)
>
> diff --git a/board/Marvell/octeontx/board-fdt.c b/board/Marvell/octeontx/board-fdt.c
> index 0b05ef11e9..1db2a4a267 100644
> --- a/board/Marvell/octeontx/board-fdt.c
> +++ b/board/Marvell/octeontx/board-fdt.c
> @@ -281,20 +281,16 @@ int ft_board_setup(void *blob, struct bd_info *bd)
> }
>
> if (blob) {
> + /* delete cavium,bdk node if it exists */
> offset = fdt_path_offset(blob, "/cavium,bdk");
> - if (offset < 0) {
> - printf("ERROR: FDT BDK node not found\n");
> - return offset;
> - }
> -
> - /* delete node */
> - ret = fdt_del_node(blob, offset);
> - if (ret < 0) {
> - printf("WARNING : could not remove bdk node\n");
> - return ret;
> + if (offset >= 0) {
> + ret = fdt_del_node(blob, offset);
> + if (ret < 0) {
> + printf("WARNING : could not remove bdk node\n");
> + return ret;
> + }
> + debug("%s deleted bdk node\n", __func__);
> }
> -
> - debug("%s deleted bdk node\n", __func__);
> }
>
> return 0;
>
Viele Grüße,
Stefan
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-51 Fax: (+49)-8142-66989-80 Email: sr@denx.de
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] octeontx: do not require cavium BDK node to be present
2021-06-17 23:31 [PATCH] octeontx: do not require cavium BDK node to be present Tim Harvey
2021-06-18 6:04 ` Stefan Roese
@ 2021-07-09 5:19 ` Stefan Roese
1 sibling, 0 replies; 3+ messages in thread
From: Stefan Roese @ 2021-07-09 5:19 UTC (permalink / raw)
To: Tim Harvey, Aaron Williams; +Cc: Suneel Garapati, u-boot
On 18.06.21 01:31, Tim Harvey wrote:
> The cavium,bdk node is a non-standard dt node used by the BDK and
> therefore it is removed from the dt before booting Linux. Do not
> require this node to exist as it won't for standard dt's.
>
> Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Applied to u-boot-marvell/master
Thanks,
Stefan
> ---
> board/Marvell/octeontx/board-fdt.c | 20 ++++++++------------
> 1 file changed, 8 insertions(+), 12 deletions(-)
>
> diff --git a/board/Marvell/octeontx/board-fdt.c b/board/Marvell/octeontx/board-fdt.c
> index 0b05ef11e9..1db2a4a267 100644
> --- a/board/Marvell/octeontx/board-fdt.c
> +++ b/board/Marvell/octeontx/board-fdt.c
> @@ -281,20 +281,16 @@ int ft_board_setup(void *blob, struct bd_info *bd)
> }
>
> if (blob) {
> + /* delete cavium,bdk node if it exists */
> offset = fdt_path_offset(blob, "/cavium,bdk");
> - if (offset < 0) {
> - printf("ERROR: FDT BDK node not found\n");
> - return offset;
> - }
> -
> - /* delete node */
> - ret = fdt_del_node(blob, offset);
> - if (ret < 0) {
> - printf("WARNING : could not remove bdk node\n");
> - return ret;
> + if (offset >= 0) {
> + ret = fdt_del_node(blob, offset);
> + if (ret < 0) {
> + printf("WARNING : could not remove bdk node\n");
> + return ret;
> + }
> + debug("%s deleted bdk node\n", __func__);
> }
> -
> - debug("%s deleted bdk node\n", __func__);
> }
>
> return 0;
>
Viele Grüße,
Stefan
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-51 Fax: (+49)-8142-66989-80 Email: sr@denx.de
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-07-09 5:19 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-17 23:31 [PATCH] octeontx: do not require cavium BDK node to be present Tim Harvey
2021-06-18 6:04 ` Stefan Roese
2021-07-09 5:19 ` Stefan Roese
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.