summaryrefslogtreecommitdiff
path: root/chip
diff options
context:
space:
mode:
authorBrian Norris <briannorris@chromium.org>2016-10-21 15:48:40 -0700
committerBrian Norris <briannorris@chromium.org>2016-10-22 00:01:02 +0000
commitc4e1a40e35a7d0f55a6a0bea55a1e325fdd41568 (patch)
tree72c15bbb10bfa0c8a181a670a31f5968c224c171 /chip
parenta4da57e0f3731fe5384315a168ed047aa8486645 (diff)
downloadchrome-ec-c4e1a40e35a7d0f55a6a0bea55a1e325fdd41568.tar.gz
Fixup usb_updater for reef/clang
clang doesn't like the array here: ec-utils-0.0.1-r3361: x86_64-cros-linux-gnu-clang -std=gnu99 -g -Wall -Werror -Wpointer-arith -Wcast-align -Wcast-qual -Wundef -Wsign-compare -Wredundant-decls -Wmissing-declarations -O0 -I/build/reef/usr/include/libusb-1.0 -I../../include -I../../board/cr50 -I ../../chip/g -I../../util usb_updater.c -lusb-1.0 -lcrypto -o usb_updater ec-utils-0.0.1-r3361: In file included from usb_updater.c:32: ec-utils-0.0.1-r3361: In file included from ../../include/usb_descriptor.h:14: ec-utils-0.0.1-r3361: ../../chip/g/usb_hw.h:29:14: error: tentative array definition assumed to have ec-utils-0.0.1-r3361: one element [-Werror] ec-utils-0.0.1-r3361: static int (*usb_iface_request[]) (struct usb_setup_packet *req); ec-utils-0.0.1-r3361: ^ ec-utils-0.0.1-r3361: 1 error generated. But it's willing to forgive if this is extern. It should be extern anyway. BRANCH=none BUG=chromium:658436 TEST=reef pre-cq passes (building ec-utils) Change-Id: I5b5f8eb8dcdc3340487b118b30469c8cee73e182 Signed-off-by: Brian Norris <briannorris@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/401421 Reviewed-by: Shawn N <shawnn@chromium.org>
Diffstat (limited to 'chip')
-rw-r--r--chip/g/usb_hw.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/chip/g/usb_hw.h b/chip/g/usb_hw.h
index 90d23f2bd7..03cabce5a6 100644
--- a/chip/g/usb_hw.h
+++ b/chip/g/usb_hw.h
@@ -26,7 +26,7 @@ extern void (*usb_ep_rx[]) (void);
extern void (*usb_ep_reset[]) (void);
struct usb_setup_packet;
/* EP0 Interface handler callbacks */
-static int (*usb_iface_request[]) (struct usb_setup_packet *req);
+extern int (*usb_iface_request[]) (struct usb_setup_packet *req);
/*
* Declare any interface-specific control request handlers. These Setup packets