stmmac: use of_property_read_u32 instead of read_u8

Numbers in DT are stored in “cells” which are 32-bits
in size. of_property_read_u8 does not work properly
because of endianness problem.

This causes it to always return 0 with little-endian

Fix it by using of_property_read_u32() OF API.

Signed-off-by: Bhadram Varka <>
Signed-off-by: David S. Miller <>
2 files changed