From: INSUN PYO Date: Wed, 11 Mar 2020 04:42:24 +0000 (+0900) Subject: Remove the duplicated usb_client->disable() function. X-Git-Tag: submit/tizen/20200331.081929~36 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c59e9b7f81d5454133f791b467b3468d29115d49;p=platform%2Fcore%2Fsystem%2Fdeviced.git Remove the duplicated usb_client->disable() function. Change-Id: Idf5a5e321facd206f3f7cac3e1b9cf8509f8b9b9 --- diff --git a/src/usb/usb.c b/src/usb/usb.c index 8335c1b..2be5c81 100644 --- a/src/usb/usb.c +++ b/src/usb/usb.c @@ -222,7 +222,6 @@ static int usb_change_gadget(unsigned mode) goto out; } - usb_client->disable(usb_client); ret = usb_client->reconfigure_gadget(usb_client, gadget); gadget_translator->cleanup_gadget(gadget); if (ret) { @@ -345,7 +344,7 @@ int usb_change_mode(unsigned int new_mode) /* Special case: Because usb gadget is disabled, temporarily switch usb state from available to connected. */ send_usb_state_changed_event(VCONFKEY_SYSMAN_USB_CONNECTED); - ret = usb_disable(); /* Need to clean up because usb_change_gadget() also calls usb_client->disable() */ + ret = usb_disable(); if (ret < 0) { _E("Failed to disable current USB mode."); return ret;