libfdt: Revert 6dcb8ba4 from upstream libfdt
authorTom Rini <trini@konsulko.com>
Mon, 27 Jan 2020 17:10:31 +0000 (12:10 -0500)
committerTom Rini <trini@konsulko.com>
Thu, 30 Jan 2020 18:30:35 +0000 (13:30 -0500)
commite8c2d25845c72c7202a628a97d45e31beea40668
tree4edcfaded2876ed931998a8686d2220a61e443e0
parent84f0415201e57e1919a2c91684e64bdedd85d159
libfdt: Revert 6dcb8ba4 from upstream libfdt

In upstream libfdt, 6dcb8ba4 "libfdt: Add helpers for accessing
unaligned words" introduced changes to support unaligned reads for ARM
platforms and 11738cf01f15 "libfdt: Don't use memcpy to handle unaligned
reads on ARM" improved the performance of these helpers.

In practice however, this only occurs when the user has forced the
device tree to be placed in memory in a non-aligned way, which in turn
violates both our rules and the Linux Kernel rules for how things must
reside in memory to function.

This "in practice" part is important as handling these other cases adds
visible (1 second or more) delay to boot in what would be considered the
fast path of the code.

Cc: Patrice CHOTARD <patrice.chotard@st.com>
Cc: Patrick DELAUNAY <patrick.delaunay@st.com>
Link: https://www.spinics.net/lists/devicetree-compiler/msg02972.html
Signed-off-by: Tom Rini <trini@konsulko.com>
Tested-by: Patrice Chotard <patrice.chotard@st.com>
lib/libfdt/fdt_ro.c
scripts/dtc/libfdt/fdt_ro.c
scripts/dtc/libfdt/libfdt.h