diff options
Diffstat (limited to 'nuttx/arch/arm/src/sama5/sam_emac.h')
-rw-r--r-- | nuttx/arch/arm/src/sama5/sam_emac.h | 51 |
1 files changed, 40 insertions, 11 deletions
diff --git a/nuttx/arch/arm/src/sama5/sam_emac.h b/nuttx/arch/arm/src/sama5/sam_emac.h index df71da4b8..31b73ee25 100644 --- a/nuttx/arch/arm/src/sama5/sam_emac.h +++ b/nuttx/arch/arm/src/sama5/sam_emac.h @@ -45,12 +45,20 @@ #include "chip.h" #include "chip/sam_emac.h" -#ifndef __ASSEMBLY__ +/************************************************************************************ + * Pre-processor Definitions + ************************************************************************************/ +/* Definitions for use with sam_phy_boardinitialize */ + +#define GMAC_INTF 0 +#define EMAC_INTF 1 /************************************************************************************ * Public Functions ************************************************************************************/ +#ifndef __ASSEMBLY__ + #undef EXTERN #if defined(__cplusplus) #define EXTERN extern "C" @@ -59,26 +67,47 @@ extern "C" { #define EXTERN extern #endif -/************************************************************************************ - * Function: sam_ethinitialize +/**************************************************************************** + * Function: sam_gmac_initialize * * Description: - * Initialize the Ethernet driver for one interface. If the STM32 chip supports - * multiple Ethernet controllers, then board specific logic must implement - * up_netinitialize() and call this function to initialize the desired interfaces. + * Initialize the GMAC driver. * - * Parameters: - * intf - In the case where there are multiple EMACs, this value identifies which - * EMAC is to be initialized. + * Input Parameters: + * None * * Returned Value: * OK on success; Negated errno on failure. * * Assumptions: + * Called very early in the initialization sequence. * - ************************************************************************************/ + ****************************************************************************/ + +#ifdef CONFIG_SAMA5_GMAC +int sam_gmac_initialize(void); +#endif -int sam_ethinitialize(int intf); +/**************************************************************************** + * Function: sam_emac_initialize + * + * Description: + * Initialize the EMAC driver. + * + * Input Parameters: + * None + * + * Returned Value: + * OK on success; Negated errno on failure. + * + * Assumptions: + * Called very early in the initialization sequence. + * + ****************************************************************************/ + +#ifdef CONFIG_SAMA5_EMAC +int sam_emac_initialize(void); +#endif /************************************************************************************ * Function: sam_phy_boardinitialize |