]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
usb: dwc2: Avoid leaving the error_debugfs label unused
authorMartin Blumenstingl <martin.blumenstingl@googlemail.com>
Fri, 20 Nov 2020 16:46:45 +0000 (08:46 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 24 Nov 2020 12:38:54 +0000 (13:38 +0100)
commit37b4f6474a4ace8cc3cc13b8e17c7c862a373007
tree0a9bdc8101f2b415a6959bb5eb3b657a25d2268f
parent53b3380debd8c4f717c65986862fa05fd4e0198d
usb: dwc2: Avoid leaving the error_debugfs label unused

commit 190bb01b72d2d5c3654a03c42fb1ad0dc6114c79 upstream.

The error_debugfs label is only used when either
CONFIG_USB_DWC2_PERIPHERAL or CONFIG_USB_DWC2_DUAL_ROLE is enabled. Add
the same #if to the error_debugfs label itself as the code which uses
this label already has.

This avoids the following compiler warning:
  warning: label ‘error_debugfs’ defined but not used [-Wunused-label]

Fixes: e1c08cf23172ed ("usb: dwc2: Add missing cleanups when usb_add_gadget_udc() fails")
Acked-by: Minas Harutyunyan <Minas.Harutyunyan@synopsys.com>
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Signed-off-by: Felipe Balbi <balbi@kernel.org>
Cc: stable@vger.kernel.org # 5.9.x
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/usb/dwc2/platform.c