X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=board%2Ftechnexion%2Ftwister%2Ftwister.c;h=25aeebc8d0e9543bf08c6443c83fdc58b6cb1064;hb=8850c5d57c10aa6431d138d426e6e105c99cc7ba;hp=b92758692d57a49d1611b999aeb0cf979be3ce22;hpb=a939ea3ab459d5fb3d1eaaec289c6ca85f2f74c1;p=platform%2Fkernel%2Fu-boot.git diff --git a/board/technexion/twister/twister.c b/board/technexion/twister/twister.c index b927586..25aeebc 100644 --- a/board/technexion/twister/twister.c +++ b/board/technexion/twister/twister.c @@ -4,23 +4,7 @@ * * Copyright (C) 2009 TechNexion Ltd. * - * See file CREDITS for list of people who contributed to this - * project. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License as - * published by the Free Software Foundation; either version 2 of - * the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, - * MA 02111-1307 USA + * SPDX-License-Identifier: GPL-2.0+ */ #include @@ -32,8 +16,10 @@ #include #include #include +#include +#include #include -#ifdef CONFIG_USB_EHCI +#ifdef CONFIG_USB_EHCI_HCD #include #include #endif @@ -60,19 +46,20 @@ static const u32 gpmc_XR16L2751[] = { XR16L2751_GPMC_CONFIG6, }; -#ifdef CONFIG_USB_EHCI +#ifdef CONFIG_USB_EHCI_HCD static struct omap_usbhs_board_data usbhs_bdata = { .port_mode[0] = OMAP_EHCI_PORT_MODE_PHY, .port_mode[1] = OMAP_EHCI_PORT_MODE_PHY, .port_mode[2] = OMAP_USBHS_PORT_MODE_UNUSED, }; -int ehci_hcd_init(void) +int ehci_hcd_init(int index, enum usb_init_type init, + struct ehci_hccr **hccr, struct ehci_hcor **hcor) { - return omap_ehci_hcd_init(&usbhs_bdata); + return omap_ehci_hcd_init(index, &usbhs_bdata, hccr, hcor); } -int ehci_hcd_stop(void) +int ehci_hcd_stop(int index) { return omap_ehci_hcd_stop(); } @@ -98,12 +85,26 @@ int board_init(void) return 0; } +#ifndef CONFIG_SPL_BUILD int misc_init_r(void) { - dieid_num_r(); + char *eth_addr; + struct tam3517_module_info info; + int ret; + + omap_die_id_display(); + + eth_addr = getenv("ethaddr"); + if (eth_addr) + return 0; + + TAM3517_READ_EEPROM(&info, ret); + if (!ret) + TAM3517_READ_MAC_FROM_EEPROM(&info); return 0; } +#endif /* * Routine: set_muxconf_regs @@ -129,17 +130,17 @@ int board_eth_init(bd_t *bis) return 0; } -#if defined(CONFIG_OMAP_HSMMC) && \ +#if defined(CONFIG_MMC_OMAP_HS) && \ !defined(CONFIG_SPL_BUILD) int board_mmc_init(bd_t *bis) { - return omap_mmc_init(0); + return omap_mmc_init(0, 0, 0, -1, -1); } #endif #ifdef CONFIG_SPL_OS_BOOT /* - * Do board specific preperation before SPL + * Do board specific preparation before SPL * Linux boot */ void spl_board_prepare_for_linux(void) @@ -151,10 +152,10 @@ void spl_board_prepare_for_linux(void) int spl_start_uboot(void) { int val = 0; - if (!gpio_request(CONFIG_SPL_OS_BOOT_KEY, "U-Boot key")) { - gpio_direction_input(CONFIG_SPL_OS_BOOT_KEY); - val = gpio_get_value(CONFIG_SPL_OS_BOOT_KEY); - gpio_free(CONFIG_SPL_OS_BOOT_KEY); + if (!gpio_request(SPL_OS_BOOT_KEY, "U-Boot key")) { + gpio_direction_input(SPL_OS_BOOT_KEY); + val = gpio_get_value(SPL_OS_BOOT_KEY); + gpio_free(SPL_OS_BOOT_KEY); } return val; }