summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/arm/altera-cyclone-v/README
diff options
context:
space:
mode:
authorChristian Mauderer <Christian.Mauderer@embedded-brains.de>2014-08-22 08:53:10 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2014-08-22 11:48:27 +0200
commitd5f543296737df9b9410fccca4b7105679d0e17a (patch)
tree40e3583a4fcbff95c17e94ad5d7fb9680e374577 /c/src/lib/libbsp/arm/altera-cyclone-v/README
parentbsp/tms570: disable huge memory demanding tests for internal RAM build variant. (diff)
downloadrtems-d5f543296737df9b9410fccca4b7105679d0e17a.tar.bz2
libchip/dwmac: Make PHY address user configurable
This patch allows the user to configure the PHY address for the DWMAC driver by giving a pointer to a dwmac_user_cfg structure to network stack via rtems_bsdnet_ifconfig::drv_ctrl.
Diffstat (limited to 'c/src/lib/libbsp/arm/altera-cyclone-v/README')
-rw-r--r--c/src/lib/libbsp/arm/altera-cyclone-v/README28
1 files changed, 28 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/arm/altera-cyclone-v/README b/c/src/lib/libbsp/arm/altera-cyclone-v/README
index 0a5bc05505..658fe77255 100644
--- a/c/src/lib/libbsp/arm/altera-cyclone-v/README
+++ b/c/src/lib/libbsp/arm/altera-cyclone-v/README
@@ -14,3 +14,31 @@ have to set the following options:
Additional there has to be one free file descriptor to access the i2c. Set the
CONFIGURE_LIBIO_MAXIMUM_FILE_DESCRIPTORS accordingly.
+
+Network
+-------
+The default PHY address can be overwritten by the application. To do this, the
+drv_ctrl pointer of the rtems_bsdnet_ifconfig structure should point to a
+dwmac_ifconfig_drv_ctrl object with the appropriate settings before the
+rtems_bsdnet_initialize_network() is called. E.g.:
+
+ #include <libchip/dwmac.h>
+ #include <bsp.h>
+
+ static dwmac_ifconfig_drv_ctrl drv_ctrl = {
+ .phy_addr = 1
+ };
+
+ ...
+
+ static struct rtems_bsdnet_ifconfig some_ifconfig = {
+ .name = RTEMS_BSP_NETWORK_DRIVER_NAME,
+ .attach = RTEMS_BSP_NETWORK_DRIVER_ATTACH,
+ .drv_ctrl = &drv_ctrl
+ };
+
+ ...
+
+ rtems_bsdnet_initialize_network();
+
+If drv_ctrl is the NULL pointer, default values will be used instead.