-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
USB: move usb debugfs directory creation to the usb common core
The USB gadget subsystem wants to use the USB debugfs root directory, so move it to the common "core" USB code so that it is properly initialized and removed as needed. In order to properly do this, we need to load the common code before the usb core code, when everything is linked into the kernel, so reorder the link order of the code. Also as the usb common code has the possibility of the led trigger logic to be merged into it, handle the build option properly by only having one module init/exit function and have the common code initialize the led trigger if needed. Reported-by: Chunfeng Yun <chunfeng.yun@mediatek.com> Cc: Felipe Balbi <felipe.balbi@linux.intel.com> Tested-by: Chunfeng Yun <chunfeng.yun@mediatek.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
- Loading branch information
Greg Kroah-Hartman
committed
Jun 6, 2019
1 parent
0e01624
commit 812086d
Showing
5 changed files
with
43 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
/* SPDX-License-Identifier: GPL-2.0 */ | ||
|
||
#ifndef __LINUX_USB_COMMON_H | ||
#define __LINUX_USB_COMMON_H | ||
|
||
#if defined(CONFIG_USB_LED_TRIG) | ||
void ledtrig_usb_init(void); | ||
void ledtrig_usb_exit(void); | ||
#else | ||
static inline void ledtrig_usb_init(void) { } | ||
static inline void ledtrig_usb_exit(void) { } | ||
#endif | ||
|
||
#endif /* __LINUX_USB_COMMON_H */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters