On 12/12/17 15:05, Geoff Levand wrote:
Hi Nathan,
On 12/08/2017 01:25 PM, Nathan Whitehorn wrote:
I submitted patches to libfdt that resolve this particular ABI breakage
yesterday. If the patch gets merged, newer kernels should become bootable again.
Here's the link:
https://github.com/dgibson/dtc/pull/12 (Add limited read-only support for
older (V2 and V3) device tree to libfdt.)
I rebased your patch and have it in my ps3-queue
branch, but my ps3 with ps3-petitboot-09.11.30 still
would not boot with it. I didn't spend any time yet
to look into why.
https://git.kernel.org/pub/scm/linux/kernel/git/geoff/ps3-linux.git/log/?h=ps3-queue
-Geoff
I found a bug (and updated the pull request), which might help.
The other potential issue is that the fdt_get_property*() API in libfdt
is fundamentally incompatible with the way that V2 device trees align
data accesses since it returns a pointer to a packed structure with both
the property header and data. However, the data in V2 devtrees may be
offset by 4 bytes in a way that depends both on the offset within the
tree and the length of the property and so cannot be represented only as
the tail of a fixed structure. I don't know if Linux uses those
functions; I had to replace two uses in FreeBSD with the equivalent
fdt_getprop*() calls to get things to work.
-Nathan