With clang this gives a warning because hubsts appears to be used before
it is set, even if ultimately it is not used. Simplify the code to avoid
this problem.
Signed-off-by: Simon Glass <sjg@chromium.org>
short hubCharacteristics;
struct usb_hub_descriptor *descriptor;
struct usb_hub_device *hub;
- __maybe_unused struct usb_hub_status *hubsts;
+ struct usb_hub_status *hubsts;
int ret;
hub = usb_get_hub_device(dev);
return ret;
}
-#ifdef DEBUG
hubsts = (struct usb_hub_status *)buffer;
-#endif
debug("get_hub_status returned status %X, change %X\n",
le16_to_cpu(hubsts->wHubStatus),