mmc: fix response decoding on little endian

The mmc code defines the response as an array of chars.  However, it
access the response bytes both as (i) an array of four uints (with
casts) and (ii) as individual chars.  The former case is used more
often, including by the driver when it assigns the response.

The char-wise accesses are broken on little endian systems because they
assume that the bytes in the uints are in big endian byte order.

This patch fixes this by changing the response to be an array of four
uints and replacing the char-wise accesses with equivalent uint-wise
accesses.

Signed-off-by: Rabin Vincent <rabin@rab.in>
2 files changed