mirror of
https://github.com/dgibson/dtc.git
synced 2026-01-22 01:30:34 -05:00
The members of struct fdt_header are declared as fdt32_t which is a 32-bit, big-endian, unsigned integer. These fields are accessed by macros in libfdt.h so no return type is declared. But the correct return type is uint32_t, not fdt32_t, since the endianness conversion is done within the macro before returning the value. The macros are re-declared as normal functions in pylibfdt since swig does not support macros. The return type is currently int. Change it to uint32_t, which allows us to drop the work-around mask in Fdt.magic(). Also change the typedef for fdt32_t to uint32_t. The currently has no obvious effect, since use of big-endian values should always be internal to pylibfdt, but it is more correct. Signed-off-by: Simon Glass <sjg@chromium.org> Suggested-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: David Gibson <david@gibson.dropbear.id.au> |
||
|---|---|---|
| .. | ||
| .gitignore | ||
| libfdt.i | ||
| Makefile.pylibfdt | ||
| setup.py | ||