summaryrefslogtreecommitdiff
path: root/chip
diff options
context:
space:
mode:
Diffstat (limited to 'chip')
-rw-r--r--chip/g/upgrade_fw.h3
-rw-r--r--chip/g/usb_upgrade.c5
-rw-r--r--chip/g/usb_upgrade.h14
3 files changed, 5 insertions, 17 deletions
diff --git a/chip/g/upgrade_fw.h b/chip/g/upgrade_fw.h
index 1e6c595fb7..ce9debd5fb 100644
--- a/chip/g/upgrade_fw.h
+++ b/chip/g/upgrade_fw.h
@@ -8,6 +8,9 @@
#include <stddef.h>
+/* TODO: Handle this in upgrade_fw.c, not usb_upgrade.c */
+#define UPGRADE_DONE 0xB007AB1E
+
void fw_upgrade_command_handler(void *body,
size_t cmd_size,
size_t *response_size);
diff --git a/chip/g/usb_upgrade.c b/chip/g/usb_upgrade.c
index 54e4fb6d1c..7e86a0c035 100644
--- a/chip/g/usb_upgrade.c
+++ b/chip/g/usb_upgrade.c
@@ -12,7 +12,6 @@
#include "system.h"
#include "upgrade_fw.h"
#include "usb-stream.h"
-#include "usb_upgrade.h"
#define CPRINTS(format, args...) cprints(CC_USB, format, ## args)
@@ -49,8 +48,8 @@ static struct queue const usb_to_upgrade = QUEUE_DIRECT(64, uint8_t,
USB_STREAM_CONFIG_FULL(usb_upgrade,
USB_IFACE_UPGRADE,
USB_CLASS_VENDOR_SPEC,
- UNOFFICIAL_USB_SUBCLASS_GOOGLE_CR50,
- 0xff, /* vendor-specific protocol */
+ USB_SUBCLASS_GOOGLE_CR50,
+ USB_PROTOCOL_GOOGLE_CR50_NON_HC_FW_UPDATE,
USB_STR_UPGRADE_NAME,
USB_EP_UPGRADE,
USB_MAX_PACKET_SIZE,
diff --git a/chip/g/usb_upgrade.h b/chip/g/usb_upgrade.h
deleted file mode 100644
index 7fe25b5895..0000000000
--- a/chip/g/usb_upgrade.h
+++ /dev/null
@@ -1,14 +0,0 @@
-/* Copyright 2016 The Chromium OS Authors. All rights reserved.
- * Use of this source code is governed by a BSD-style license that can be
- * found in the LICENSE file.
- */
-
-#ifndef __CROS_EC_USB_UPGRADE_H
-#define __CROS_EC_USB_UPGRADE_H
-
-#define UNOFFICIAL_USB_SUBCLASS_GOOGLE_CR50 0x53
-
-/* Commands from host */
-#define UPGRADE_DONE 0xB007AB1E
-
-#endif /* __CROS_EC_USB_UPGRADE_H */