/kernel/linux/linux-5.10/drivers/usb/mtu3/ |
H A D | mtu3_dr.c | 122 int ssusb_set_vbus(struct otg_switch_mtk *otg_sx, int is_on) in ssusb_set_vbus() argument 125 container_of(otg_sx, struct ssusb_mtk, otg_switch); in ssusb_set_vbus() 126 struct regulator *vbus = otg_sx->vbus; in ssusb_set_vbus() 152 static void ssusb_set_mailbox(struct otg_switch_mtk *otg_sx, in ssusb_set_mailbox() argument 156 container_of(otg_sx, struct ssusb_mtk, otg_switch); in ssusb_set_mailbox() 165 ssusb_set_vbus(otg_sx, 1); in ssusb_set_mailbox() 170 ssusb_set_vbus(otg_sx, 0); in ssusb_set_mailbox() 189 struct otg_switch_mtk *otg_sx = in ssusb_id_work() local 192 if (otg_sx->id_event) in ssusb_id_work() 193 ssusb_set_mailbox(otg_sx, MTU3_ID_GROUN in ssusb_id_work() 200 struct otg_switch_mtk *otg_sx = ssusb_vbus_work() local 216 struct otg_switch_mtk *otg_sx = ssusb_id_notifier() local 228 struct otg_switch_mtk *otg_sx = ssusb_vbus_notifier() local 237 ssusb_extcon_register(struct otg_switch_mtk *otg_sx) ssusb_extcon_register() argument 285 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; ssusb_mode_switch() local 345 ssusb_role_sw_register(struct otg_switch_mtk *otg_sx) ssusb_role_sw_register() argument 365 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; ssusb_otg_switch_init() local 383 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; ssusb_otg_switch_exit() local [all...] |
H A D | mtu3_plat.c | 217 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; in get_ssusb_rscs() local 287 otg_sx->vbus = devm_regulator_get(dev, "vbus"); in get_ssusb_rscs() 288 if (IS_ERR(otg_sx->vbus)) { in get_ssusb_rscs() 290 return PTR_ERR(otg_sx->vbus); in get_ssusb_rscs() 297 otg_sx->is_u3_drd = of_property_read_bool(node, "mediatek,usb3-drd"); in get_ssusb_rscs() 298 otg_sx->manual_drd_enabled = in get_ssusb_rscs() 300 otg_sx->role_sw_used = of_property_read_bool(node, "usb-role-switch"); in get_ssusb_rscs() 302 if (!otg_sx->role_sw_used && of_property_read_bool(node, "extcon")) { in get_ssusb_rscs() 303 otg_sx->edev = extcon_get_edev_by_phandle(ssusb->dev, 0); in get_ssusb_rscs() 304 if (IS_ERR(otg_sx in get_ssusb_rscs() [all...] |
H A D | mtu3_dr.h | 75 int ssusb_set_vbus(struct otg_switch_mtk *otg_sx, int is_on); 92 static inline int ssusb_set_vbus(struct otg_switch_mtk *otg_sx, int is_on) in ssusb_set_vbus() argument
|
H A D | mtu3_debugfs.c | 478 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; in ssusb_vbus_show() local 481 regulator_is_enabled(otg_sx->vbus) ? "on" : "off"); in ssusb_vbus_show() 496 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; in ssusb_vbus_write() local 508 ssusb_set_vbus(otg_sx, enable); in ssusb_vbus_write()
|
H A D | mtu3_host.c | 194 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; in ssusb_host_setup() local 204 if (otg_sx->manual_drd_enabled) in ssusb_host_setup()
|
/kernel/linux/linux-6.6/drivers/usb/mtu3/ |
H A D | mtu3_dr.c | 17 static inline struct ssusb_mtk *otg_sx_to_ssusb(struct otg_switch_mtk *otg_sx) in otg_sx_to_ssusb() argument 19 return container_of(otg_sx, struct ssusb_mtk, otg_switch); in otg_sx_to_ssusb() 102 int ssusb_set_vbus(struct otg_switch_mtk *otg_sx, int is_on) in ssusb_set_vbus() argument 104 struct ssusb_mtk *ssusb = otg_sx_to_ssusb(otg_sx); in ssusb_set_vbus() 105 struct regulator *vbus = otg_sx->vbus; in ssusb_set_vbus() 129 struct otg_switch_mtk *otg_sx = in ssusb_mode_sw_work() local 131 struct ssusb_mtk *ssusb = otg_sx_to_ssusb(otg_sx); in ssusb_mode_sw_work() 133 enum usb_role desired_role = otg_sx->desired_role; in ssusb_mode_sw_work() 141 if (otg_sx->default_role == USB_ROLE_DEVICE) in ssusb_mode_sw_work() 157 ssusb_set_vbus(otg_sx, in ssusb_mode_sw_work() 174 ssusb_set_mode(struct otg_switch_mtk *otg_sx, enum usb_role role) ssusb_set_mode() argument 188 struct otg_switch_mtk *otg_sx = ssusb_id_notifier() local 196 ssusb_extcon_register(struct otg_switch_mtk *otg_sx) ssusb_extcon_register() argument 232 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; ssusb_mode_switch() local 263 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; ssusb_role_sw_set() local 277 ssusb_role_sw_register(struct otg_switch_mtk *otg_sx) ssusb_role_sw_register() argument 309 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; ssusb_otg_switch_init() local 326 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; ssusb_otg_switch_exit() local [all...] |
H A D | mtu3_plat.c | 195 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; in ssusb_u3_drd_check() local 202 otg_sx->is_u3_drd = false; in ssusb_u3_drd_check() 212 otg_sx->is_u3_drd = !!(dev_u3p_num && host_u3p_num); in ssusb_u3_drd_check() 215 dev_info(ssusb->dev, "usb3-drd: %d\n", otg_sx->is_u3_drd); in ssusb_u3_drd_check() 221 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; in get_ssusb_rscs() local 290 otg_sx->vbus = devm_regulator_get(dev, "vbus"); in get_ssusb_rscs() 291 if (IS_ERR(otg_sx->vbus)) { in get_ssusb_rscs() 293 return PTR_ERR(otg_sx->vbus); in get_ssusb_rscs() 300 otg_sx->manual_drd_enabled = in get_ssusb_rscs() 302 otg_sx in get_ssusb_rscs() [all...] |
H A D | mtu3_dr.h | 97 int ssusb_set_vbus(struct otg_switch_mtk *otg_sx, int is_on); 114 static inline int ssusb_set_vbus(struct otg_switch_mtk *otg_sx, int is_on) in ssusb_set_vbus() argument
|
H A D | mtu3_debugfs.c | 479 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; in ssusb_vbus_show() local 482 regulator_is_enabled(otg_sx->vbus) ? "on" : "off"); in ssusb_vbus_show() 497 struct otg_switch_mtk *otg_sx = &ssusb->otg_switch; in ssusb_vbus_write() local 509 ssusb_set_vbus(otg_sx, enable); in ssusb_vbus_write()
|