mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-29 22:02:02 +00:00
usb: phy: mxs: remove CONFIG_USB_OTG condition for mxs_phy_is_otg_host()
commitff2b89de47
upstream. When CONFIG_USB_OTG is not set, mxs_phy_is_otg_host() will always return false. This behaviour is wrong. Since phy.last_event will always be set for either host or device mode. Therefore, CONFIG_USB_OTG condition can be removed. Fixes:5eda42aebb
("usb: phy: mxs: fix getting wrong state with mxs_phy_is_otg_host()") cc: <stable@vger.kernel.org> Acked-by: Peter Chen <peter.chen@kernel.org> Signed-off-by: Xu Yang <xu.yang_2@nxp.com> Link: https://lore.kernel.org/r/20231228110753.1755756-3-xu.yang_2@nxp.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
98654bc44c
commit
21ee23b1b0
1 changed files with 1 additions and 2 deletions
|
@ -312,8 +312,7 @@ static void __mxs_phy_disconnect_line(struct mxs_phy *mxs_phy, bool disconnect)
|
|||
|
||||
static bool mxs_phy_is_otg_host(struct mxs_phy *mxs_phy)
|
||||
{
|
||||
return IS_ENABLED(CONFIG_USB_OTG) &&
|
||||
mxs_phy->phy.last_event == USB_EVENT_ID;
|
||||
return mxs_phy->phy.last_event == USB_EVENT_ID;
|
||||
}
|
||||
|
||||
static void mxs_phy_disconnect_line(struct mxs_phy *mxs_phy, bool on)
|
||||
|
|
Loading…
Reference in a new issue