summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChen Guoyin <guoyin.chen@nxp.com>2016-12-29 14:55:32 +0800
committerChen Guoyin <guoyin.chen@nxp.com>2017-01-20 10:31:56 +0800
commit793e1666a2c2e24ba66b631544ec85acb91e9b12 (patch)
tree79402505ed30e05d263c91146cacfa3afd810b84
parentf99f29a501019231ac1649d29de5c51302ed3d5b (diff)
downloadu-boot-imx-793e1666a2c2e24ba66b631544ec85acb91e9b12.zip
u-boot-imx-793e1666a2c2e24ba66b631544ec85acb91e9b12.tar.gz
u-boot-imx-793e1666a2c2e24ba66b631544ec85acb91e9b12.tar.bz2
MA-9140 Add variant as imx6ul_pico or imx6ul_iopb depending on the board
The bootloader is currently reporting the variant (ie imx6ul_pico) for the product variable and not reporting a product variable. This needs to be changed to report product=imx6ul for both boards and variant=imx6ul_pico or imx6ul_iopb depending on the board. Change-Id: Ic2fd160519b065a9164996fa7e18f24e3500f5df Signed-off-by: Chen Guoyin <guoyin.chen@nxp.com>
-rwxr-xr-xdrivers/usb/gadget/f_fastboot.c6
-rw-r--r--include/configs/mx6ul_nxpu_iopb.h3
-rw-r--r--include/configs/picosom-imx6ul.h3
3 files changed, 9 insertions, 3 deletions
diff --git a/drivers/usb/gadget/f_fastboot.c b/drivers/usb/gadget/f_fastboot.c
index 5dfdb86..339887a 100755
--- a/drivers/usb/gadget/f_fastboot.c
+++ b/drivers/usb/gadget/f_fastboot.c
@@ -2742,6 +2742,10 @@ static char *get_serial(void)
#define PRODUCT_NAME "NXP i.MX"
#endif
+#if !defined(VARIANT_NAME)
+#define VARIANT_NAME "NXP i.MX"
+#endif
+
static void cb_getvar(struct usb_ep *ep, struct usb_request *req)
{
char *cmd = req->buf;
@@ -2799,7 +2803,7 @@ static void cb_getvar(struct usb_ep *ep, struct usb_request *req)
} else if (!strcmp_l1("battery-soc-ok", cmd)) {
strncat(response, "yes", chars_left);
} else if (!strcmp_l1("variant", cmd)) {
- /* just OKAY here */
+ strncat(response, VARIANT_NAME, chars_left);
} else if (!strcmp_l1("off-mode-charge", cmd)) {
strncat(response, "1", chars_left);
} else if (!strcmp_l1("downloadsize", cmd) ||
diff --git a/include/configs/mx6ul_nxpu_iopb.h b/include/configs/mx6ul_nxpu_iopb.h
index b27381a..4cc2f1c 100644
--- a/include/configs/mx6ul_nxpu_iopb.h
+++ b/include/configs/mx6ul_nxpu_iopb.h
@@ -425,6 +425,7 @@
#endif
-#define PRODUCT_NAME "imx6ul_iopb"
+#define PRODUCT_NAME "imx6ul"
+#define VARIANT_NAME "imx6ul_iopb"
#endif
diff --git a/include/configs/picosom-imx6ul.h b/include/configs/picosom-imx6ul.h
index bc92365..6ab032f 100644
--- a/include/configs/picosom-imx6ul.h
+++ b/include/configs/picosom-imx6ul.h
@@ -399,6 +399,7 @@
#define CONFIG_USB_FASTBOOT_BUF_SIZE 0xc800000
#endif
-#define PRODUCT_NAME "imx6ul_pico"
+#define PRODUCT_NAME "imx6ul"
+#define VARIANT_NAME "imx6ul_pico"
#endif