net/macb: improve big endian CPU support
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Fri, 24 Jul 2015 18:23:59 +0000 (21:23 +0300)
committerDavid S. Miller <davem@davemloft.net>
Mon, 27 Jul 2015 08:10:29 +0000 (01:10 -0700)
commitf2ce8a9e48385f444389e75cfe293637c3eb5410
tree7226bddfdacdaaa762b2403a502c77bc41c40f17
parentdfbafc995304ebb9a9b03f65083e6e9cea143b20
net/macb: improve big endian CPU support

The commit a50dad355a53 (net: macb: Add big endian CPU support) converted I/O
accessors to readl_relaxed() and writel_relaxed() and consequentially broke
MACB driver on AVR32 platforms such as ATNGW100.

This patch improves I/O access by checking endiannes first and use the
corresponding methods.

Fixes: a50dad355a53 (net: macb: Add big endian CPU support)
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/cadence/macb.c
drivers/net/ethernet/cadence/macb.h