/* * Routine: board_eth_init * Description: initialize module and base-board Ethernet chips */ int board_eth_init(bd_t *bis) { int rc = 0, rc1 = 0; setup_net_chip_gmpc(); reset_net_chip(); rc1 = handle_mac_address(); if (rc1) printf("No MAC address found! "); rc1 = smc911x_initialize(0, CM_T3X_SMC911X_BASE); if (rc1 > 0) rc++; rc1 = smc911x_initialize(1, SB_T35_SMC911X_BASE); if (rc1 > 0) rc++; return rc; }
int board_eth_init(bd_t *bis) { davinci_emac_initialize(); /* init cs for extern lan */ enable_gpmc_cs_config(gpmc_smc911, &gpmc_cfg->cs[5], CONFIG_SMC911X_BASE, GPMC_SIZE_16M); if (smc911x_initialize(0, CONFIG_SMC911X_BASE) <= 0) printf("\nError initializing SMC911x controlleri\n"); return 0; }
int board_eth_init(bd_t *bis) { int rc = -ENODEV; weim_smc911x_iomux(); weim_cs1_settings(); #ifdef CONFIG_SMC911X rc = smc911x_initialize(0, CONFIG_SMC911X_BASE); #endif return rc; }
/* * Routine: board_eth_init * Description: initialize module and base-board Ethernet chips */ int board_eth_init(bd_t *bis) { int rc = 0, rc1 = 0; #ifdef CONFIG_SMC911X setup_net_chip_gmpc(); reset_net_chip(); rc1 = handle_mac_address(); if (rc1) printf("CM-T3x: No MAC address found\n"); rc1 = smc911x_initialize(0, CM_T3X_SMC911X_BASE); if (rc1 > 0) rc++; rc1 = smc911x_initialize(1, SB_T35_SMC911X_BASE); if (rc1 > 0) rc++; #endif return rc; }
int board_eth_init(bd_t *bis) { #ifdef CONFIG_SMC911X u32 smc_bw_conf, smc_bc_conf; struct fdt_sromc config; fdt_addr_t base_addr; int node; node = decode_sromc(gd->fdt_blob, &config); if (node < 0) { debug("%s: Could not find sromc configuration\n", __func__); return 0; } node = fdtdec_next_compatible(gd->fdt_blob, node, COMPAT_SMSC_LAN9215); if (node < 0) { debug("%s: Could not find lan9215 configuration\n", __func__); return 0; } /* We now have a node, so any problems from now on are errors */ base_addr = fdtdec_get_addr(gd->fdt_blob, node, "reg"); if (base_addr == FDT_ADDR_T_NONE) { debug("%s: Could not find lan9215 address\n", __func__); return -1; } /* Ethernet needs data bus width of 16 bits */ if (config.width != 2) { debug("%s: Unsupported bus width %d\n", __func__, config.width); return -1; } smc_bw_conf = SROMC_DATA16_WIDTH(config.bank) | SROMC_BYTE_ENABLE(config.bank); smc_bc_conf = SROMC_BC_TACS(config.timing[FDT_SROM_TACS]) | SROMC_BC_TCOS(config.timing[FDT_SROM_TCOS]) | SROMC_BC_TACC(config.timing[FDT_SROM_TACC]) | SROMC_BC_TCOH(config.timing[FDT_SROM_TCOH]) | SROMC_BC_TAH(config.timing[FDT_SROM_TAH]) | SROMC_BC_TACP(config.timing[FDT_SROM_TACP]) | SROMC_BC_PMC(config.timing[FDT_SROM_PMC]); /* Select and configure the SROMC bank */ exynos_pinmux_config(PERIPH_ID_SROMC, config.bank); s5p_config_sromc(config.bank, smc_bw_conf, smc_bc_conf); return smc911x_initialize(0, base_addr); #endif return 0; }
int board_eth_init(bd_t *bis) { #ifdef CONFIG_SMC911X u32 smc_bw_conf, smc_bc_conf; struct fdt_sromc config; fdt_addr_t base_addr; /* Non-FDT configuration - bank number and timing parameters*/ config.bank = CONFIG_ENV_SROM_BANK; config.width = 2; config.timing[FDT_SROM_TACS] = 0x01; config.timing[FDT_SROM_TCOS] = 0x01; config.timing[FDT_SROM_TACC] = 0x06; config.timing[FDT_SROM_TCOH] = 0x01; config.timing[FDT_SROM_TAH] = 0x0C; config.timing[FDT_SROM_TACP] = 0x09; config.timing[FDT_SROM_PMC] = 0x01; base_addr = CONFIG_SMC911X_BASE; /* Ethernet needs data bus width of 16 bits */ if (config.width != 2) { debug("%s: Unsupported bus width %d\n", __func__, config.width); return -1; } smc_bw_conf = SROMC_DATA16_WIDTH(config.bank) | SROMC_BYTE_ENABLE(config.bank); smc_bc_conf = SROMC_BC_TACS(config.timing[FDT_SROM_TACS]) |\ SROMC_BC_TCOS(config.timing[FDT_SROM_TCOS]) |\ SROMC_BC_TACC(config.timing[FDT_SROM_TACC]) |\ SROMC_BC_TCOH(config.timing[FDT_SROM_TCOH]) |\ SROMC_BC_TAH(config.timing[FDT_SROM_TAH]) |\ SROMC_BC_TACP(config.timing[FDT_SROM_TACP]) |\ SROMC_BC_PMC(config.timing[FDT_SROM_PMC]); /* Select and configure the SROMC bank */ exynos_pinmux_config(PERIPH_ID_SROMC, config.bank); s5p_config_sromc(config.bank, smc_bw_conf, smc_bc_conf); return smc911x_initialize(0, base_addr); #endif return 0; }
int cl_omap3_smc911x_init(int id, int cs, u32 base_addr, int (*reset)(int), int rst_gpio) { int ret; cl_omap3_smc911x_setup_net_chip_gmpc(cs, base_addr); if (reset) reset(rst_gpio); else cl_omap3_smc911x_reset_net_chip(rst_gpio); ret = smc911x_initialize(id, base_addr); if (ret > 0) return ret; printf("Failed initializing SMC911x! "); return 0; }
int board_eth_init(bd_t *bis) { int rc = 0; #ifdef CONFIG_SMC911X #define STR_ENV_ETHADDR "ethaddr" struct eth_device *dev; uchar eth_addr[6]; rc = smc911x_initialize(0, CONFIG_SMC911X_BASE); if (!eth_getenv_enetaddr(STR_ENV_ETHADDR, eth_addr)) { dev = eth_get_dev_by_index(0); if (dev) { eth_setenv_enetaddr(STR_ENV_ETHADDR, dev->enetaddr); } else { printf("omap3evm: Couldn't get eth device\n"); rc = -1; } } #endif return rc; }
int board_eth_init(bd_t *bis) { int rc = 0; rc = smc911x_initialize(0, CONFIG_SMC911X_BASE); return rc; }
int board_eth_init(bd_t *bis) { return smc911x_initialize(0, CONFIG_SMC911X_BASE); }
int board_eth_init(bd_t *bis) { /* return ok if at least 1 eth device works */ return bfin_EMAC_initialize(bis) & smc911x_initialize(0, CONFIG_SMC911X_BASE); }