Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fdtdump.c array boundary error when running /prepare #5

Open
Tonymac32 opened this issue Feb 23, 2025 · 2 comments
Open

fdtdump.c array boundary error when running /prepare #5

Tonymac32 opened this issue Feb 23, 2025 · 2 comments

Comments

@Tonymac32
Copy link

tony@DESKTOP-97UV9T4:~/khadas-uboot$ ./scripts/prepare
[i] prepare tc
[i] make_010_dtc.sh
[i] make dtc-1.6.0.tar.gz
[i] DOWNLOAD https://github.com/dgibson/dtc/archive/v1.6.0.tar.gz => dtc-1.6.0.tar.gz DIR ../../dl
[w] already downloaded
CHK version_gen.h
CC fdtdump.o
In file included from fdtdump.c:14:
fdtdump.c: In function ‘main’:
libfdt/libfdt.h:251:28: error: array subscript ‘struct fdt_header[0]’ is partly outside array bounds of ‘unsigned char[4]’ [-Werror=array-bounds]
251 | fdth->name = cpu_to_fdt32(val);
| ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
libfdt/libfdt.h:253:1: note: in expansion of macro ‘fdt_set_hdr_’
253 | fdt_set_hdr_(magic);
| ^~~~~~~~~~~~
fdtdump.c:216:31: note: while referencing ‘smagic’
216 | unsigned char smagic[FDT_MAGIC_SIZE];
| ^~~~~~
cc1: all warnings being treated as errors
make: *** [Makefile:345: fdtdump.o] Error 1
[i] prepare tc DONE

@hyphop
Copy link
Member

hyphop commented Feb 24, 2025

tnx - fixed by 0e3e133

@hyphop
Copy link
Member

hyphop commented Feb 24, 2025

this repo still need some aditional fixes for vim1 vim2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants