From 4fd16633a8c379971425f7fd482152f163b09158 Mon Sep 17 00:00:00 2001
From: Paul Burton <Paul.Burton@imgtec.com>
Date: Fri, 17 Sep 2010 14:08:57 +0100
Subject: [PATCH] Endianness macros should not dereference unaligned pointers
The LE_*/BE_* macros previously worked by casting the pointer passed to them to a pointer to the correct integer type, then dereferencing it. This will not work on architectures which don't allow unaligned data access. Instead, access one byte at a time and shift to form the value.