aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/fec_mxc.h
diff options
context:
space:
mode:
authorJagan Teki <jagan@amarulasolutions.com>2016-12-06 00:00:50 +0100
committerStefano Babic <sbabic@denx.de>2016-12-16 17:15:27 +0100
commit567173a610107ced9174f03290851f272b4cbfc2 (patch)
treece24907a8d8370a4c45f10346708a9074d992283 /drivers/net/fec_mxc.h
parent60752ca86afdb0eaf2482aee9dafbdea84cb75f1 (diff)
downloadu-boot-567173a610107ced9174f03290851f272b4cbfc2.zip
u-boot-567173a610107ced9174f03290851f272b4cbfc2.tar.gz
u-boot-567173a610107ced9174f03290851f272b4cbfc2.tar.bz2
net: fec_mxc: Driver cleanups
- Remove exctra space - Add space - Add tab space - Fix single line comments quotes - Fix 'CHECK: Avoid CamelCase' - Fix 'CHECK: Alignment should match open parenthesis' - Fix 'WARNING: line over 80 characters' - Re-arrage header include files Cc: Simon Glass <sjg@chromium.org> Cc: Peng Fan <peng.fan@nxp.com> Cc: Stefano Babic <sbabic@denx.de> Cc: Michael Trimarchi <michael@amarulasolutions.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com> Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Diffstat (limited to 'drivers/net/fec_mxc.h')
-rw-r--r--drivers/net/fec_mxc.h27
1 files changed, 8 insertions, 19 deletions
diff --git a/drivers/net/fec_mxc.h b/drivers/net/fec_mxc.h
index 9fc6153..43a7d7b 100644
--- a/drivers/net/fec_mxc.h
+++ b/drivers/net/fec_mxc.h
@@ -14,21 +14,14 @@
* SPDX-License-Identifier: GPL-2.0+
*/
-
#ifndef __FEC_MXC_H
#define __FEC_MXC_H
-void imx_get_mac_from_fuse(int dev_id, unsigned char *mac);
-
-/**
- * Layout description of the FEC
- */
+/* Layout description of the FEC */
struct ethernet_regs {
+ /* [10:2]addr = 00 */
-/* [10:2]addr = 00 */
-
-/* Control and status Registers (offset 000-1FF) */
-
+ /* Control and status Registers (offset 000-1FF) */
uint32_t res0[1]; /* MBAR_ETH + 0x000 */
uint32_t ievent; /* MBAR_ETH + 0x004 */
uint32_t imask; /* MBAR_ETH + 0x008 */
@@ -71,8 +64,7 @@ struct ethernet_regs {
uint32_t emrbr; /* MBAR_ETH + 0x188 */
uint32_t res12[29]; /* MBAR_ETH + 0x18C-1FC */
-/* MIB COUNTERS (Offset 200-2FF) */
-
+ /* MIB COUNTERS (Offset 200-2FF) */
uint32_t rmon_t_drop; /* MBAR_ETH + 0x200 */
uint32_t rmon_t_packets; /* MBAR_ETH + 0x204 */
uint32_t rmon_t_bc_pkt; /* MBAR_ETH + 0x208 */
@@ -174,7 +166,6 @@ struct ethernet_regs {
#define FEC_IMASKT_RL 0x00100000
#define FEC_IMASK_UN 0x00080000
-
#define FEC_RCNTRL_MAX_FL_SHIFT 16
#define FEC_RCNTRL_LOOP 0x00000001
#define FEC_RCNTRL_DRT 0x00000002
@@ -233,9 +224,7 @@ struct fec_bd {
uint32_t data_pointer; /* payload's buffer address */
};
-/**
- * Supported phy types on this platform
- */
+/* Supported phy types on this platform */
enum xceiver_type {
SEVENWIRE, /* 7-wire */
MII10, /* MII 10Mbps */
@@ -244,9 +233,7 @@ enum xceiver_type {
RGMII, /* RGMII */
};
-/**
- * @brief i.MX27-FEC private structure
- */
+/* @brief i.MX27-FEC private structure */
struct fec_priv {
struct ethernet_regs *eth; /* pointer to register'S base */
enum xceiver_type xcv_type; /* transceiver type */
@@ -270,6 +257,8 @@ struct fec_priv {
#endif
};
+void imx_get_mac_from_fuse(int dev_id, unsigned char *mac);
+
/**
* @brief Numbers of buffer descriptors for receiving
*