summaryrefslogtreecommitdiff
path: root/board/servo_micro/board.h
diff options
context:
space:
mode:
authorNick Sanders <nsanders@chromium.org>2016-07-19 15:33:47 -0700
committerchrome-bot <chrome-bot@chromium.org>2016-07-21 17:33:04 -0700
commit08aebf624ca1b8bed94cb5b4378ed058e9d9c007 (patch)
treeec83a814b5545e863b99c364dc9c735145a88e20 /board/servo_micro/board.h
parentf623eaf077a4050cd7ae6dd3c96525325060d647 (diff)
downloadchrome-ec-08aebf624ca1b8bed94cb5b4378ed058e9d9c007.tar.gz
servo_micro: add USB updater
This adds a Google FW update endpoint to servo micro in place of a GPIO enpoint. BUG=chromium:571477 TEST=successfully update servo micro via usb BRANCH=None Signed-off-by: Nick Sanders <nsanders@chromium.org> Change-Id: I3d6c501d515b3f1db6e8259fbb829abe18f72e00 Reviewed-on: https://chromium-review.googlesource.com/361834 Commit-Ready: Nick Sanders <nsanders@chromium.org> Tested-by: Nick Sanders <nsanders@chromium.org> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
Diffstat (limited to 'board/servo_micro/board.h')
-rw-r--r--board/servo_micro/board.h40
1 files changed, 22 insertions, 18 deletions
diff --git a/board/servo_micro/board.h b/board/servo_micro/board.h
index ddb4316415..03e583afeb 100644
--- a/board/servo_micro/board.h
+++ b/board/servo_micro/board.h
@@ -33,25 +33,31 @@
#define CONFIG_USB
#define CONFIG_USB_PID 0x501a
#define CONFIG_USB_CONSOLE
+#define CONFIG_USB_UPDATE
+
+#define CONFIG_USB_SERIALNO
+#define DEFAULT_SERIALNO "Uninitialized"
/* USB interface indexes (use define rather than enum to expand them) */
-#define USB_IFACE_USART4_STREAM 0
-#define USB_IFACE_SPI 2
-#define USB_IFACE_CONSOLE 3
-#define USB_IFACE_I2C 4
-#define USB_IFACE_USART3_STREAM 5
-#define USB_IFACE_USART2_STREAM 6
-#define USB_IFACE_COUNT 7
+#define USB_IFACE_USART4_STREAM 0
+#define USB_IFACE_UPDATE 1
+#define USB_IFACE_SPI 2
+#define USB_IFACE_CONSOLE 3
+#define USB_IFACE_I2C 4
+#define USB_IFACE_USART3_STREAM 5
+#define USB_IFACE_USART2_STREAM 6
+#define USB_IFACE_COUNT 7
/* USB endpoint indexes (use define rather than enum to expand them) */
-#define USB_EP_CONTROL 0
-#define USB_EP_USART4_STREAM 1
-#define USB_EP_SPI 3
-#define USB_EP_CONSOLE 4
-#define USB_EP_I2C 5
-#define USB_EP_USART3_STREAM 6
-#define USB_EP_USART2_STREAM 7
-#define USB_EP_COUNT 8
+#define USB_EP_CONTROL 0
+#define USB_EP_USART4_STREAM 1
+#define USB_EP_UPDATE 2
+#define USB_EP_SPI 3
+#define USB_EP_CONSOLE 4
+#define USB_EP_I2C 5
+#define USB_EP_USART3_STREAM 6
+#define USB_EP_USART2_STREAM 7
+#define USB_EP_COUNT 8
/* Enable console recasting of GPIO type. */
#define CONFIG_CMD_GPIO_EXTENDED
@@ -84,9 +90,6 @@
#include "gpio_signal.h"
-#define CONFIG_USB_SERIALNO
-#define DEFAULT_SERIALNO "Uninitialized"
-
/* USB string indexes */
enum usb_strings {
USB_STR_DESC = 0,
@@ -98,6 +101,7 @@ enum usb_strings {
USB_STR_CONSOLE_NAME,
USB_STR_USART3_STREAM_NAME,
USB_STR_USART2_STREAM_NAME,
+ USB_STR_UPDATE_NAME,
USB_STR_COUNT
};