summaryrefslogtreecommitdiff
path: root/include/miiphy.h
diff options
context:
space:
mode:
authorStefan Roese <sr@denx.de>2005-11-01 10:02:21 +0100
committerStefan Roese <sr@denx.de>2005-11-01 10:02:21 +0100
commitd9f2f5008c32c8373d68a4c8e14f50a469965a23 (patch)
tree64dd39bdb04a7b0d4034d3037e288e7d2341379f /include/miiphy.h
parente190290ba40fc5340cefd04dd6abf5def15065b9 (diff)
parentbe360d9824d653780ebd3ffc08f1938a8e3dd747 (diff)
downloadu-boot-imx-d9f2f5008c32c8373d68a4c8e14f50a469965a23.zip
u-boot-imx-d9f2f5008c32c8373d68a4c8e14f50a469965a23.tar.gz
u-boot-imx-d9f2f5008c32c8373d68a4c8e14f50a469965a23.tar.bz2
Merge with /git/u-boot.git
Diffstat (limited to 'include/miiphy.h')
-rw-r--r--include/miiphy.h36
1 files changed, 28 insertions, 8 deletions
diff --git a/include/miiphy.h b/include/miiphy.h
index afdd5a7..3c6ee77 100644
--- a/include/miiphy.h
+++ b/include/miiphy.h
@@ -38,18 +38,38 @@
#ifndef _miiphy_h_
#define _miiphy_h_
+#include <net.h>
-int miiphy_read(unsigned char addr, unsigned char reg, unsigned short * value);
-int miiphy_write(unsigned char addr, unsigned char reg, unsigned short value);
-int miiphy_info(unsigned char addr, unsigned int *oui, unsigned char *model,
- unsigned char *rev);
-int miiphy_reset(unsigned char addr);
-int miiphy_speed(unsigned char addr);
-int miiphy_duplex(unsigned char addr);
+int miiphy_read(char *devname, unsigned char addr, unsigned char reg,
+ unsigned short *value);
+int miiphy_write(char *devname, unsigned char addr, unsigned char reg,
+ unsigned short value);
+int miiphy_info(char *devname, unsigned char addr, unsigned int *oui,
+ unsigned char *model, unsigned char *rev);
+int miiphy_reset(char *devname, unsigned char addr);
+int miiphy_speed(char *devname, unsigned char addr);
+int miiphy_duplex(char *devname, unsigned char addr);
#ifdef CFG_FAULT_ECHO_LINK_DOWN
-int miiphy_link(unsigned char addr);
+int miiphy_link(char *devname, unsigned char addr);
#endif
+void miiphy_register(char *devname,
+ int (* read)(char *devname, unsigned char addr,
+ unsigned char reg, unsigned short *value),
+ int (* write)(char *devname, unsigned char addr,
+ unsigned char reg, unsigned short value));
+
+int miiphy_set_current_dev(char *devname);
+char *miiphy_get_current_dev(void);
+
+void miiphy_listdev(void);
+
+#define BB_MII_DEVNAME "bbmii"
+
+int bb_miiphy_read (char *devname, unsigned char addr,
+ unsigned char reg, unsigned short *value);
+int bb_miiphy_write (char *devname, unsigned char addr,
+ unsigned char reg, unsigned short value);
/* phy seed setup */
#define AUTO 99