usb: mtu3: register a USB Role Switch for dual role mode
Because extcon is not allowed for new bindings, and the dual role switch is supported by USB Role Switch, especially for Type-C drivers, so register a USB Role Switch to support the new way Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com> Link: https://lore.kernel.org/r/1567070558-29417-12-git-send-email-chunfeng.yun@mediatek.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Este cometimento está contido em:

cometido por
Greg Kroah-Hartman

ascendente
4602f3bff2
cometimento
1ac91ac5d0
@@ -199,6 +199,9 @@ struct mtu3_gpd_ring {
|
||||
* @id_nb : notifier for iddig(idpin) detection
|
||||
* @id_work : work of iddig detection notifier
|
||||
* @id_event : event of iddig detecion notifier
|
||||
* @role_sw : use USB Role Switch to support dual-role switch, can't use
|
||||
* extcon at the same time, and extcon is deprecated.
|
||||
* @role_sw_used : true when the USB Role Switch is used.
|
||||
* @is_u3_drd: whether port0 supports usb3.0 dual-role device or not
|
||||
* @manual_drd_enabled: it's true when supports dual-role device by debugfs
|
||||
* to switch host/device modes depending on user input.
|
||||
@@ -212,6 +215,8 @@ struct otg_switch_mtk {
|
||||
struct notifier_block id_nb;
|
||||
struct work_struct id_work;
|
||||
unsigned long id_event;
|
||||
struct usb_role_switch *role_sw;
|
||||
bool role_sw_used;
|
||||
bool is_u3_drd;
|
||||
bool manual_drd_enabled;
|
||||
};
|
||||
|
Criar uma nova questão referindo esta
Bloquear um utilizador