[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20220822100550.3039-1-johan+linaro@kernel.org>
Date: Mon, 22 Aug 2022 12:05:50 +0200
From: Johan Hovold <johan+linaro@...nel.org>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc: Andy Gross <agross@...nel.org>,
Bjorn Andersson <bjorn.andersson@...aro.org>,
Konrad Dybcio <konrad.dybcio@...ainline.org>,
Felipe Balbi <balbi@...nel.org>, linux-arm-msm@...r.kernel.org,
linux-usb@...r.kernel.org, linux-kernel@...r.kernel.org,
Johan Hovold <johan+linaro@...nel.org>,
kernel test robot <lkp@...el.com>
Subject: [PATCH] usb: dwc3: qcom: suppress unused-variable warning
The dwc3_qcom_read_usb2_speed() helper is now only called when the
controller is acting as host, but the compiler will warn that the hcd
variable is unused in gadget-only W=1 builds.
Fixes: c06795f114a6 ("usb: dwc3: qcom: fix gadget-only builds")
Reported-by: kernel test robot <lkp@...el.com>
Signed-off-by: Johan Hovold <johan+linaro@...nel.org>
---
drivers/usb/dwc3/dwc3-qcom.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/dwc3/dwc3-qcom.c b/drivers/usb/dwc3/dwc3-qcom.c
index b3ba9aaf876c..8298aebd395e 100644
--- a/drivers/usb/dwc3/dwc3-qcom.c
+++ b/drivers/usb/dwc3/dwc3-qcom.c
@@ -310,7 +310,7 @@ static enum usb_device_speed dwc3_qcom_read_usb2_speed(struct dwc3_qcom *qcom)
{
struct dwc3 *dwc = platform_get_drvdata(qcom->dwc3);
struct usb_device *udev;
- struct usb_hcd *hcd;
+ struct usb_hcd __maybe_unused *hcd;
/*
* FIXME: Fix this layering violation.
--
2.35.1
Powered by blists - more mailing lists