aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>2012-03-29 15:32:08 -0400
committerDavid S. Miller <davem@davemloft.net>2012-04-01 23:22:11 -0400
commit10b9194f959608368ed89df1937f17cfe6bd6d84 (patch)
tree867eec7da75983ee378204b8bdbeefc26301c336
parent6bafd6436e99d08e8def37ae9f790e1aff871bae (diff)
net: sh_eth: fix endian check for architecture independent
SuperH has the "CONFIG_CPU_LITTLE_ENDIAN" and the "__LITTLE_ENDIAN__". But, other architecture doesn't have them. So, this patch fixes it. Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/ethernet/renesas/sh_eth.c2
-rw-r--r--drivers/net/ethernet/renesas/sh_eth.h4
2 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/ethernet/renesas/sh_eth.c b/drivers/net/ethernet/renesas/sh_eth.c
index 8bdf070ace90..d63e09b29a96 100644
--- a/drivers/net/ethernet/renesas/sh_eth.c
+++ b/drivers/net/ethernet/renesas/sh_eth.c
@@ -804,7 +804,7 @@ static int sh_eth_dev_init(struct net_device *ndev)
804 /* all sh_eth int mask */ 804 /* all sh_eth int mask */
805 sh_eth_write(ndev, 0, EESIPR); 805 sh_eth_write(ndev, 0, EESIPR);
806 806
807#if defined(__LITTLE_ENDIAN__) 807#if defined(__LITTLE_ENDIAN)
808 if (mdp->cd->hw_swap) 808 if (mdp->cd->hw_swap)
809 sh_eth_write(ndev, EDMR_EL, EDMR); 809 sh_eth_write(ndev, EDMR_EL, EDMR);
810 else 810 else
diff --git a/drivers/net/ethernet/renesas/sh_eth.h b/drivers/net/ethernet/renesas/sh_eth.h
index e66de1823532..0fa14afce23d 100644
--- a/drivers/net/ethernet/renesas/sh_eth.h
+++ b/drivers/net/ethernet/renesas/sh_eth.h
@@ -693,7 +693,7 @@ enum TSU_FWSLC_BIT {
693 */ 693 */
694struct sh_eth_txdesc { 694struct sh_eth_txdesc {
695 u32 status; /* TD0 */ 695 u32 status; /* TD0 */
696#if defined(CONFIG_CPU_LITTLE_ENDIAN) 696#if defined(__LITTLE_ENDIAN)
697 u16 pad0; /* TD1 */ 697 u16 pad0; /* TD1 */
698 u16 buffer_length; /* TD1 */ 698 u16 buffer_length; /* TD1 */
699#else 699#else
@@ -710,7 +710,7 @@ struct sh_eth_txdesc {
710 */ 710 */
711struct sh_eth_rxdesc { 711struct sh_eth_rxdesc {
712 u32 status; /* RD0 */ 712 u32 status; /* RD0 */
713#if defined(CONFIG_CPU_LITTLE_ENDIAN) 713#if defined(__LITTLE_ENDIAN)
714 u16 frame_length; /* RD1 */ 714 u16 frame_length; /* RD1 */
715 u16 buffer_length; /* RD1 */ 715 u16 buffer_length; /* RD1 */
716#else 716#else