Merge branch 'master' of git://git.denx.de/u-boot-mmc
[platform/kernel/u-boot.git] / board / alphaproject / ap_sh4a_4a / ap_sh4a_4a.c
index 77cadea..9205c22 100644 (file)
@@ -2,19 +2,7 @@
  * Copyright (C) 2012 Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
  * Copyright (C) 2012 Renesas Solutions Corp.
  *
- * 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.
- *
+ * SPDX-License-Identifier:    GPL-2.0+
  */
 
 #include <common.h>
@@ -23,8 +11,6 @@
 #include <netdev.h>
 #include <i2c.h>
 
-DECLARE_GLOBAL_DATA_PTR;
-
 #define MODEMR                 (0xFFCC0020)
 #define MODEMR_MASK            (0x6)
 #define MODEMR_533MHZ  (0x2)
@@ -90,7 +76,7 @@ int checkboard(void)
 /* IPSR11 */
 #define ET0_ERXD4      (0x4 <<  4)
 #define ET0_ERXD5      (0x4 <<  7)
-#define ET0_ERXD6      (0x4 <<  4)
+#define ET0_ERXD6      (0x3 << 10)
 #define ET0_TX_EN      (0x2 << 19)
 #define ET0_TX_ER      (0x2 << 21)
 #define ET0_TX_CLK_A (0x4 << 23)
@@ -99,7 +85,7 @@ int checkboard(void)
        (ET0_ERXD4 | ET0_ERXD5 | ET0_ERXD6 | ET0_TX_EN | ET0_TX_ER | \
        ET0_TX_CLK_A | ET0_RX_CLK_A)
 
-#define GPSR1_INIT (0xFFBF7FFF)
+#define GPSR1_INIT (0xFFFF7FFF)
 #define GPSR2_INIT (0x4005FEFF)
 #define GPSR3_INIT (0x2EFFFFFF)
 #define GPSR4_INIT (0xC7000000)
@@ -170,26 +156,7 @@ int board_init(void)
 
 int board_late_init(void)
 {
-       u8 mac[6];
-
-       /* Read Mac Address and set*/
-       i2c_init(CONFIG_SYS_I2C_SPEED, CONFIG_SYS_I2C_SLAVE);
-       i2c_set_bus_num(CONFIG_SYS_I2C_MODULE);
-
-       /* Read MAC address */
-       i2c_read(0x50, 0x0, 0, mac, 6);
-
-       if (is_valid_ether_addr(mac))
-               eth_setenv_enetaddr("ethaddr", mac);
-
-       return 0;
-}
-
-int dram_init(void)
-{
-       gd->bd->bi_memstart = CONFIG_SYS_SDRAM_BASE;
-       gd->bd->bi_memsize = CONFIG_SYS_SDRAM_SIZE;
-       printf("DRAM:  %dMB\n", CONFIG_SYS_SDRAM_SIZE / (1024 * 1024));
+       printf("Cannot use I2C to get MAC address\n");
 
        return 0;
 }