From 7fcd0590eb730fab8ff75c6e684b5aee36174775 Mon Sep 17 00:00:00 2001 From: Bill Richardson Date: Thu, 24 Mar 2016 19:11:36 -0700 Subject: [PATCH] Cr50: Fix console message on unexpected USB event We were referring to unhandled USB control messages as errors, but they aren't necessarily. Sometimes they're optional things that aren't fatal. We should still address them, but we don't have to freak out. BUG=none BRANCH=none TEST=make buildall; test on Cr50 Change-Id: I892acec2d89b8ec95353cdc09f3e49aa78b1704d Signed-off-by: Bill Richardson Reviewed-on: https://chromium-review.googlesource.com/335200 Reviewed-by: Randall Spangler --- chip/g/usb.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/chip/g/usb.c b/chip/g/usb.c index 83c1089a40..f9ce50725e 100644 --- a/chip/g/usb.c +++ b/chip/g/usb.c @@ -161,17 +161,17 @@ DECLARE_CONSOLE_COMMAND(usb, command_usb, NULL); /* When debugging, print errors as they occur */ -#define report_error(dummy) \ - print_later("USB ERROR at usb.c line %d: 0x%x", \ - __LINE__, dummy, 0, 0, 0) +#define report_error(val) \ + print_later("Unhandled USB event at usb.c line %d: 0x%x", \ + __LINE__, val, 0, 0, 0) #else /* Not debugging */ #define print_later(...) /* TODO: Something unexpected happened. Figure out how to report & fix it. */ -#define report_error(dummy) \ - CPRINTS("Unhandled USB error at %s line %d: 0x%x", \ - __FILE__, __LINE__, dummy) +#define report_error(val) \ + CPRINTS("Unhandled USB event at %s line %d: 0x%x", \ + __FILE__, __LINE__, val) #endif /* DEBUG_ME */