summaryrefslogtreecommitdiff
path: root/board
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2017-10-05 08:26:36 -0400
committerTom Rini <trini@konsulko.com>2017-10-05 08:26:36 -0400
commit4f42a0d7210bd8d4d1f5e2fb73456679d74c44cd (patch)
tree9d86a09455140a0dc85bc7caa82c09a9eac82202 /board
parent6a3e65dea3e525b5337ca8014aa4be9f5fafeb92 (diff)
parente6ee85a6891eca187c9a9364c51690d3f6a36932 (diff)
Merge git://git.denx.de/u-boot-sunxi
Diffstat (limited to 'board')
-rw-r--r--board/samsung/common/gadget.c4
-rw-r--r--board/siemens/common/factoryset.c4
-rw-r--r--board/sunxi/MAINTAINERS5
-rw-r--r--board/sunxi/board.c31
4 files changed, 24 insertions, 20 deletions
diff --git a/board/samsung/common/gadget.c b/board/samsung/common/gadget.c
index 6a1e57f164..ef732befc4 100644
--- a/board/samsung/common/gadget.c
+++ b/board/samsung/common/gadget.c
@@ -17,8 +17,8 @@ int g_dnl_bind_fixup(struct usb_device_descriptor *dev, const char *name)
put_unaligned(CONFIG_G_DNL_UMS_VENDOR_NUM, &dev->idVendor);
put_unaligned(CONFIG_G_DNL_UMS_PRODUCT_NUM, &dev->idProduct);
} else {
- put_unaligned(CONFIG_G_DNL_VENDOR_NUM, &dev->idVendor);
- put_unaligned(CONFIG_G_DNL_PRODUCT_NUM, &dev->idProduct);
+ put_unaligned(CONFIG_USB_GADGET_VENDOR_NUM, &dev->idVendor);
+ put_unaligned(CONFIG_USB_GADGET_PRODUCT_NUM, &dev->idProduct);
}
return 0;
}
diff --git a/board/siemens/common/factoryset.c b/board/siemens/common/factoryset.c
index b4f027af28..81bbb5758d 100644
--- a/board/siemens/common/factoryset.c
+++ b/board/siemens/common/factoryset.c
@@ -145,8 +145,8 @@ int factoryset_read_eeprom(int i2c_addr)
unsigned char *cp, *cp1;
#if defined(CONFIG_USB_FUNCTION_DFU)
- factory_dat.usb_vendor_id = CONFIG_G_DNL_VENDOR_NUM;
- factory_dat.usb_product_id = CONFIG_G_DNL_PRODUCT_NUM;
+ factory_dat.usb_vendor_id = CONFIG_USB_GADGET_VENDOR_NUM;
+ factory_dat.usb_product_id = CONFIG_USB_GADGET_PRODUCT_NUM;
#endif
if (i2c_probe(i2c_addr))
goto err;
diff --git a/board/sunxi/MAINTAINERS b/board/sunxi/MAINTAINERS
index ff6eea24a5..26c452e1b3 100644
--- a/board/sunxi/MAINTAINERS
+++ b/board/sunxi/MAINTAINERS
@@ -118,6 +118,11 @@ M: Paul Kocialkowski <contact@paulk.fr>
S: Maintained
F: configs/Ampe_A76_defconfig
+BANANAPI M1 PLUS
+M: Jagan Teki <jagan@amarulasolutions.com>
+S: Maintained
+F: configs/bananapi_m1_plus_defconfig
+
BANANAPI M2 ULTRA BOARD
M: Chen-Yu Tsai <wens@csie.org>
S: Maintained
diff --git a/board/sunxi/board.c b/board/sunxi/board.c
index 70e01437c4..6e13ee32c1 100644
--- a/board/sunxi/board.c
+++ b/board/sunxi/board.c
@@ -32,6 +32,7 @@
#include <libfdt.h>
#include <nand.h>
#include <net.h>
+#include <spl.h>
#include <sy8106a.h>
#include <asm/setup.h>
@@ -491,20 +492,6 @@ int board_mmc_init(bd_t *bis)
return -1;
#endif
-#if !defined(CONFIG_SPL_BUILD) && CONFIG_MMC_SUNXI_SLOT_EXTRA == 2
- /*
- * On systems with an emmc (mmc2), figure out if we are booting from
- * the emmc and if we are make it "mmc dev 0" so that boot.scr, etc.
- * are searched there first. Note we only do this for u-boot proper,
- * not for the SPL, see spl_boot_device().
- */
- if (readb(SPL_ADDR + 0x28) == SUNXI_BOOTED_FROM_MMC2) {
- /* Booting from emmc / mmc2, swap */
- mmc0->block_dev.devnum = 1;
- mmc1->block_dev.devnum = 0;
- }
-#endif
-
return 0;
}
#endif
@@ -720,13 +707,22 @@ static void setup_environment(const void *fdt)
int misc_init_r(void)
{
__maybe_unused int ret;
+ uint boot;
env_set("fel_booted", NULL);
env_set("fel_scriptaddr", NULL);
+ env_set("mmc_bootdev", NULL);
+
+ boot = sunxi_get_boot_device();
/* determine if we are running in FEL mode */
- if (!is_boot0_magic(SPL_ADDR + 4)) { /* eGON.BT0 */
+ if (boot == BOOT_DEVICE_BOARD) {
env_set("fel_booted", "1");
parse_spl_header(SPL_ADDR);
+ /* or if we booted from MMC, and which one */
+ } else if (boot == BOOT_DEVICE_MMC1) {
+ env_set("mmc_bootdev", "0");
+ } else if (boot == BOOT_DEVICE_MMC2) {
+ env_set("mmc_bootdev", "1");
}
setup_environment(gd->fdt_blob);
@@ -736,7 +732,10 @@ int misc_init_r(void)
if (ret)
return ret;
#endif
- sunxi_musb_board_init();
+
+#ifdef CONFIG_USB_ETHER
+ usb_ether_init();
+#endif
return 0;
}