* [PATCH 0/5] phy: Replace the deprecated extcon API
[not found] <CGME20170717012057epcas1p11fe3d445ed16c7f94b57922b0a8f243a@epcas1p1.samsung.com>
@ 2017-07-17 1:20 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-17 1:20 UTC (permalink / raw)
To: kishon, balbi, gregkh
Cc: linux-kernel, linux-arm-kernel, linux-usb, cw00.choi, chanwoo,
myungjoo.ham
These patches replace the deprecated extcon API
and remove them from extcon framework.
The patch1 and patch2 were already acked by Kishon Vijay Abraham I.
If patch3/patch4 are reviewed, I'll create the immutable branch
and send the pull request to both usb and phy maintainer.
Chanwoo Choi (5):
phy: qcom-usb-hs: Replace the extcon API
phy: rockchip-inno-usb2: Replace the extcon API
phy: phy-bcm-ns2-usbdrd: Replace the deprecated extcon API
usb: gadget: udc: Replace the deprecated extcon API
extcon: Remove deprecated extcon_set/get_cable_state_()
drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c | 8 ++++----
drivers/phy/qualcomm/phy-qcom-usb-hs.c | 14 +++-----------
drivers/phy/rockchip/phy-rockchip-inno-usb2.c | 10 +++++-----
drivers/usb/gadget/udc/snps_udc_plat.c | 6 +++---
include/linux/extcon.h | 11 -----------
5 files changed, 15 insertions(+), 34 deletions(-)
--
1.9.1
^ permalink raw reply [flat|nested] 22+ messages in thread
* [PATCH 0/5] phy: Replace the deprecated extcon API
@ 2017-07-17 1:20 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-17 1:20 UTC (permalink / raw)
To: linux-arm-kernel
These patches replace the deprecated extcon API
and remove them from extcon framework.
The patch1 and patch2 were already acked by Kishon Vijay Abraham I.
If patch3/patch4 are reviewed, I'll create the immutable branch
and send the pull request to both usb and phy maintainer.
Chanwoo Choi (5):
phy: qcom-usb-hs: Replace the extcon API
phy: rockchip-inno-usb2: Replace the extcon API
phy: phy-bcm-ns2-usbdrd: Replace the deprecated extcon API
usb: gadget: udc: Replace the deprecated extcon API
extcon: Remove deprecated extcon_set/get_cable_state_()
drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c | 8 ++++----
drivers/phy/qualcomm/phy-qcom-usb-hs.c | 14 +++-----------
drivers/phy/rockchip/phy-rockchip-inno-usb2.c | 10 +++++-----
drivers/usb/gadget/udc/snps_udc_plat.c | 6 +++---
include/linux/extcon.h | 11 -----------
5 files changed, 15 insertions(+), 34 deletions(-)
--
1.9.1
^ permalink raw reply [flat|nested] 22+ messages in thread
* [PATCH 1/5] phy: qcom-usb-hs: Replace the extcon API
[not found] ` <CGME20170717012058epcas1p181ca458cd4c80643ee7077e9ee78f7bb@epcas1p1.samsung.com>
@ 2017-07-17 1:20 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-17 1:20 UTC (permalink / raw)
To: kishon, balbi, gregkh
Cc: linux-kernel, linux-arm-kernel, linux-usb, cw00.choi, chanwoo,
myungjoo.ham
This patch uses the resource-managed extcon API for extcon_register_notifier()
and replaces the deprecated extcon API as following:
- (deprecated) extcon_get_cable_state_() -> extcon_get_state()
Acked-by: Kishon Vijay Abraham I <kishon@ti.com>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
---
drivers/phy/qualcomm/phy-qcom-usb-hs.c | 14 +++-----------
1 file changed, 3 insertions(+), 11 deletions(-)
diff --git a/drivers/phy/qualcomm/phy-qcom-usb-hs.c b/drivers/phy/qualcomm/phy-qcom-usb-hs.c
index 4b20abc3ae2f..2d0c70b5589f 100644
--- a/drivers/phy/qualcomm/phy-qcom-usb-hs.c
+++ b/drivers/phy/qualcomm/phy-qcom-usb-hs.c
@@ -155,12 +155,12 @@ static int qcom_usb_hs_phy_power_on(struct phy *phy)
}
if (uphy->vbus_edev) {
- state = extcon_get_cable_state_(uphy->vbus_edev, EXTCON_USB);
+ state = extcon_get_state(uphy->vbus_edev, EXTCON_USB);
/* setup initial state */
qcom_usb_hs_phy_vbus_notifier(&uphy->vbus_notify, state,
uphy->vbus_edev);
- ret = extcon_register_notifier(uphy->vbus_edev, EXTCON_USB,
- &uphy->vbus_notify);
+ ret = devm_extcon_register_notifier(&ulpi->dev, uphy->vbus_edev,
+ EXTCON_USB, &uphy->vbus_notify);
if (ret)
goto err_ulpi;
}
@@ -179,16 +179,8 @@ static int qcom_usb_hs_phy_power_on(struct phy *phy)
static int qcom_usb_hs_phy_power_off(struct phy *phy)
{
- int ret;
struct qcom_usb_hs_phy *uphy = phy_get_drvdata(phy);
- if (uphy->vbus_edev) {
- ret = extcon_unregister_notifier(uphy->vbus_edev, EXTCON_USB,
- &uphy->vbus_notify);
- if (ret)
- return ret;
- }
-
regulator_disable(uphy->v3p3);
regulator_disable(uphy->v1p8);
clk_disable_unprepare(uphy->sleep_clk);
--
1.9.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [PATCH 1/5] phy: qcom-usb-hs: Replace the extcon API
@ 2017-07-17 1:20 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-17 1:20 UTC (permalink / raw)
To: linux-arm-kernel
This patch uses the resource-managed extcon API for extcon_register_notifier()
and replaces the deprecated extcon API as following:
- (deprecated) extcon_get_cable_state_() -> extcon_get_state()
Acked-by: Kishon Vijay Abraham I <kishon@ti.com>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
---
drivers/phy/qualcomm/phy-qcom-usb-hs.c | 14 +++-----------
1 file changed, 3 insertions(+), 11 deletions(-)
diff --git a/drivers/phy/qualcomm/phy-qcom-usb-hs.c b/drivers/phy/qualcomm/phy-qcom-usb-hs.c
index 4b20abc3ae2f..2d0c70b5589f 100644
--- a/drivers/phy/qualcomm/phy-qcom-usb-hs.c
+++ b/drivers/phy/qualcomm/phy-qcom-usb-hs.c
@@ -155,12 +155,12 @@ static int qcom_usb_hs_phy_power_on(struct phy *phy)
}
if (uphy->vbus_edev) {
- state = extcon_get_cable_state_(uphy->vbus_edev, EXTCON_USB);
+ state = extcon_get_state(uphy->vbus_edev, EXTCON_USB);
/* setup initial state */
qcom_usb_hs_phy_vbus_notifier(&uphy->vbus_notify, state,
uphy->vbus_edev);
- ret = extcon_register_notifier(uphy->vbus_edev, EXTCON_USB,
- &uphy->vbus_notify);
+ ret = devm_extcon_register_notifier(&ulpi->dev, uphy->vbus_edev,
+ EXTCON_USB, &uphy->vbus_notify);
if (ret)
goto err_ulpi;
}
@@ -179,16 +179,8 @@ static int qcom_usb_hs_phy_power_on(struct phy *phy)
static int qcom_usb_hs_phy_power_off(struct phy *phy)
{
- int ret;
struct qcom_usb_hs_phy *uphy = phy_get_drvdata(phy);
- if (uphy->vbus_edev) {
- ret = extcon_unregister_notifier(uphy->vbus_edev, EXTCON_USB,
- &uphy->vbus_notify);
- if (ret)
- return ret;
- }
-
regulator_disable(uphy->v3p3);
regulator_disable(uphy->v1p8);
clk_disable_unprepare(uphy->sleep_clk);
--
1.9.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [PATCH 2/5] phy: rockchip-inno-usb2: Replace the extcon API
[not found] ` <CGME20170717012058epcas1p157e9a296eb5e415ae24bb51a1e6026db@epcas1p1.samsung.com>
@ 2017-07-17 1:20 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-17 1:20 UTC (permalink / raw)
To: kishon, balbi, gregkh
Cc: linux-kernel, linux-arm-kernel, linux-usb, cw00.choi, chanwoo,
myungjoo.ham, linux-rockchip
This patch uses the resource-managed extcon API for extcon_register_notifier()
and replaces the deprecated extcon API as following:
- extcon_get_cable_state_() -> extcon_get_state()
- extcon_set_cable_state_() -> extcon_set_state_sync()
Cc: linux-rockchip@lists.infradead.org
acked-by: Kishon Vijay Abraham I <kishon@ti.com>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
---
drivers/phy/rockchip/phy-rockchip-inno-usb2.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
index 626883d9d176..ef033089b7a0 100644
--- a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
+++ b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
@@ -545,7 +545,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
rockchip_usb2phy_power_off(rport->phy);
/* fall through */
case OTG_STATE_B_IDLE:
- if (extcon_get_cable_state_(rphy->edev, EXTCON_USB_HOST) > 0) {
+ if (extcon_get_state(rphy->edev, EXTCON_USB_HOST) > 0) {
dev_dbg(&rport->phy->dev, "usb otg host connect\n");
rport->state = OTG_STATE_A_HOST;
rockchip_usb2phy_power_on(rport->phy);
@@ -598,7 +598,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
rport->vbus_attached = vbus_attach;
if (notify_charger && rphy->edev) {
- extcon_set_cable_state_(rphy->edev,
+ extcon_set_state_sync(rphy->edev,
cable, vbus_attach);
if (cable == EXTCON_CHG_USB_SDP)
extcon_set_state_sync(rphy->edev,
@@ -619,7 +619,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
sch_work = true;
break;
case OTG_STATE_A_HOST:
- if (extcon_get_cable_state_(rphy->edev, EXTCON_USB_HOST) == 0) {
+ if (extcon_get_state(rphy->edev, EXTCON_USB_HOST) == 0) {
dev_dbg(&rport->phy->dev, "usb otg host disconnect\n");
rport->state = OTG_STATE_B_IDLE;
rockchip_usb2phy_power_off(rport->phy);
@@ -1006,8 +1006,8 @@ static int rockchip_usb2phy_otg_port_init(struct rockchip_usb2phy *rphy,
if (!IS_ERR(rphy->edev)) {
rport->event_nb.notifier_call = rockchip_otg_event;
- ret = extcon_register_notifier(rphy->edev, EXTCON_USB_HOST,
- &rport->event_nb);
+ ret = devm_extcon_register_notifier(rphy->dev, rphy->edev,
+ EXTCON_USB_HOST, &rport->event_nb);
if (ret)
dev_err(rphy->dev, "register USB HOST notifier failed\n");
}
--
1.9.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [PATCH 2/5] phy: rockchip-inno-usb2: Replace the extcon API
@ 2017-07-17 1:20 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-17 1:20 UTC (permalink / raw)
To: linux-arm-kernel
This patch uses the resource-managed extcon API for extcon_register_notifier()
and replaces the deprecated extcon API as following:
- extcon_get_cable_state_() -> extcon_get_state()
- extcon_set_cable_state_() -> extcon_set_state_sync()
Cc: linux-rockchip at lists.infradead.org
acked-by: Kishon Vijay Abraham I <kishon@ti.com>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
---
drivers/phy/rockchip/phy-rockchip-inno-usb2.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
index 626883d9d176..ef033089b7a0 100644
--- a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
+++ b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
@@ -545,7 +545,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
rockchip_usb2phy_power_off(rport->phy);
/* fall through */
case OTG_STATE_B_IDLE:
- if (extcon_get_cable_state_(rphy->edev, EXTCON_USB_HOST) > 0) {
+ if (extcon_get_state(rphy->edev, EXTCON_USB_HOST) > 0) {
dev_dbg(&rport->phy->dev, "usb otg host connect\n");
rport->state = OTG_STATE_A_HOST;
rockchip_usb2phy_power_on(rport->phy);
@@ -598,7 +598,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
rport->vbus_attached = vbus_attach;
if (notify_charger && rphy->edev) {
- extcon_set_cable_state_(rphy->edev,
+ extcon_set_state_sync(rphy->edev,
cable, vbus_attach);
if (cable == EXTCON_CHG_USB_SDP)
extcon_set_state_sync(rphy->edev,
@@ -619,7 +619,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
sch_work = true;
break;
case OTG_STATE_A_HOST:
- if (extcon_get_cable_state_(rphy->edev, EXTCON_USB_HOST) == 0) {
+ if (extcon_get_state(rphy->edev, EXTCON_USB_HOST) == 0) {
dev_dbg(&rport->phy->dev, "usb otg host disconnect\n");
rport->state = OTG_STATE_B_IDLE;
rockchip_usb2phy_power_off(rport->phy);
@@ -1006,8 +1006,8 @@ static int rockchip_usb2phy_otg_port_init(struct rockchip_usb2phy *rphy,
if (!IS_ERR(rphy->edev)) {
rport->event_nb.notifier_call = rockchip_otg_event;
- ret = extcon_register_notifier(rphy->edev, EXTCON_USB_HOST,
- &rport->event_nb);
+ ret = devm_extcon_register_notifier(rphy->dev, rphy->edev,
+ EXTCON_USB_HOST, &rport->event_nb);
if (ret)
dev_err(rphy->dev, "register USB HOST notifier failed\n");
}
--
1.9.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [PATCH 3/5] phy: phy-bcm-ns2-usbdrd: Replace the deprecated extcon API
[not found] ` <CGME20170717012058epcas1p10b22154ffb2184cae7453a8b557dbcca@epcas1p1.samsung.com>
@ 2017-07-17 1:20 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-17 1:20 UTC (permalink / raw)
To: kishon, balbi, gregkh
Cc: linux-kernel, linux-arm-kernel, linux-usb, cw00.choi, chanwoo,
myungjoo.ham, Raviteja Garimella
This patch replaces the deprecated extcon API as following:
- extcon_set_cable_state_() -> extcon_get_state()
Cc: Kishon Vijay Abraham I <kishon@ti.com>
Cc: Raviteja Garimella <raviteja.garimella@broadcom.com>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
---
drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c b/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c
index 9ae59e223131..d099a0c8cee5 100644
--- a/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c
+++ b/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c
@@ -253,16 +253,16 @@ static void extcon_work(struct work_struct *work)
vbus = gpiod_get_value_cansleep(driver->vbus_gpiod);
if (!id && vbus) { /* Host connected */
- extcon_set_cable_state_(driver->edev, EXTCON_USB_HOST, true);
+ extcon_set_state_sync(driver->edev, EXTCON_USB_HOST, true);
pr_debug("Host cable connected\n");
driver->data->new_state = EVT_HOST;
connect_change(driver);
} else if (id && !vbus) { /* Disconnected */
- extcon_set_cable_state_(driver->edev, EXTCON_USB_HOST, false);
- extcon_set_cable_state_(driver->edev, EXTCON_USB, false);
+ extcon_set_state_sync(driver->edev, EXTCON_USB_HOST, false);
+ extcon_set_state_sync(driver->edev, EXTCON_USB, false);
pr_debug("Cable disconnected\n");
} else if (id && vbus) { /* Device connected */
- extcon_set_cable_state_(driver->edev, EXTCON_USB, true);
+ extcon_set_state_sync(driver->edev, EXTCON_USB, true);
pr_debug("Device cable connected\n");
driver->data->new_state = EVT_DEVICE;
connect_change(driver);
--
1.9.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [PATCH 3/5] phy: phy-bcm-ns2-usbdrd: Replace the deprecated extcon API
@ 2017-07-17 1:20 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-17 1:20 UTC (permalink / raw)
To: linux-arm-kernel
This patch replaces the deprecated extcon API as following:
- extcon_set_cable_state_() -> extcon_get_state()
Cc: Kishon Vijay Abraham I <kishon@ti.com>
Cc: Raviteja Garimella <raviteja.garimella@broadcom.com>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
---
drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c b/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c
index 9ae59e223131..d099a0c8cee5 100644
--- a/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c
+++ b/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c
@@ -253,16 +253,16 @@ static void extcon_work(struct work_struct *work)
vbus = gpiod_get_value_cansleep(driver->vbus_gpiod);
if (!id && vbus) { /* Host connected */
- extcon_set_cable_state_(driver->edev, EXTCON_USB_HOST, true);
+ extcon_set_state_sync(driver->edev, EXTCON_USB_HOST, true);
pr_debug("Host cable connected\n");
driver->data->new_state = EVT_HOST;
connect_change(driver);
} else if (id && !vbus) { /* Disconnected */
- extcon_set_cable_state_(driver->edev, EXTCON_USB_HOST, false);
- extcon_set_cable_state_(driver->edev, EXTCON_USB, false);
+ extcon_set_state_sync(driver->edev, EXTCON_USB_HOST, false);
+ extcon_set_state_sync(driver->edev, EXTCON_USB, false);
pr_debug("Cable disconnected\n");
} else if (id && vbus) { /* Device connected */
- extcon_set_cable_state_(driver->edev, EXTCON_USB, true);
+ extcon_set_state_sync(driver->edev, EXTCON_USB, true);
pr_debug("Device cable connected\n");
driver->data->new_state = EVT_DEVICE;
connect_change(driver);
--
1.9.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [PATCH 4/5] usb: gadget: udc: Replace the deprecated extcon API
[not found] ` <CGME20170717012058epcas1p1080175f81148a406fcc9713d490fc894@epcas1p1.samsung.com>
@ 2017-07-17 1:20 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-17 1:20 UTC (permalink / raw)
To: kishon, balbi, gregkh
Cc: linux-kernel, linux-arm-kernel, linux-usb, cw00.choi, chanwoo,
myungjoo.ham, Raviteja Garimella
This patch replaces the deprecated extcon API as following:
- extcon_get_cable_state_() -> extcon_get_state()
Cc: Felipe Balbi <balbi@kernel.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Raviteja Garimella <raviteja.garimella@broadcom.com>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
---
drivers/usb/gadget/udc/snps_udc_plat.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/usb/gadget/udc/snps_udc_plat.c b/drivers/usb/gadget/udc/snps_udc_plat.c
index 2e11f19e07ae..0ce7b3ba60ff 100644
--- a/drivers/usb/gadget/udc/snps_udc_plat.c
+++ b/drivers/usb/gadget/udc/snps_udc_plat.c
@@ -184,7 +184,7 @@ static int udc_plat_probe(struct platform_device *pdev)
goto exit_phy;
}
- ret = extcon_get_cable_state_(udc->edev, EXTCON_USB);
+ ret = extcon_get_state(udc->edev, EXTCON_USB);
if (ret < 0) {
dev_err(dev, "Can't get cable state\n");
goto exit_extcon;
@@ -273,7 +273,7 @@ static int udc_plat_suspend(struct device *dev)
udc = dev_get_drvdata(dev);
stop_udc(udc);
- if (extcon_get_cable_state_(udc->edev, EXTCON_USB) > 0) {
+ if (extcon_get_state(udc->edev, EXTCON_USB) > 0) {
dev_dbg(udc->dev, "device -> idle\n");
stop_udc(udc);
}
@@ -303,7 +303,7 @@ static int udc_plat_resume(struct device *dev)
return ret;
}
- if (extcon_get_cable_state_(udc->edev, EXTCON_USB) > 0) {
+ if (extcon_get_state(udc->edev, EXTCON_USB) > 0) {
dev_dbg(udc->dev, "idle -> device\n");
start_udc(udc);
}
--
1.9.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [PATCH 4/5] usb: gadget: udc: Replace the deprecated extcon API
@ 2017-07-17 1:20 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-17 1:20 UTC (permalink / raw)
To: linux-arm-kernel
This patch replaces the deprecated extcon API as following:
- extcon_get_cable_state_() -> extcon_get_state()
Cc: Felipe Balbi <balbi@kernel.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Raviteja Garimella <raviteja.garimella@broadcom.com>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
---
drivers/usb/gadget/udc/snps_udc_plat.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/usb/gadget/udc/snps_udc_plat.c b/drivers/usb/gadget/udc/snps_udc_plat.c
index 2e11f19e07ae..0ce7b3ba60ff 100644
--- a/drivers/usb/gadget/udc/snps_udc_plat.c
+++ b/drivers/usb/gadget/udc/snps_udc_plat.c
@@ -184,7 +184,7 @@ static int udc_plat_probe(struct platform_device *pdev)
goto exit_phy;
}
- ret = extcon_get_cable_state_(udc->edev, EXTCON_USB);
+ ret = extcon_get_state(udc->edev, EXTCON_USB);
if (ret < 0) {
dev_err(dev, "Can't get cable state\n");
goto exit_extcon;
@@ -273,7 +273,7 @@ static int udc_plat_suspend(struct device *dev)
udc = dev_get_drvdata(dev);
stop_udc(udc);
- if (extcon_get_cable_state_(udc->edev, EXTCON_USB) > 0) {
+ if (extcon_get_state(udc->edev, EXTCON_USB) > 0) {
dev_dbg(udc->dev, "device -> idle\n");
stop_udc(udc);
}
@@ -303,7 +303,7 @@ static int udc_plat_resume(struct device *dev)
return ret;
}
- if (extcon_get_cable_state_(udc->edev, EXTCON_USB) > 0) {
+ if (extcon_get_state(udc->edev, EXTCON_USB) > 0) {
dev_dbg(udc->dev, "idle -> device\n");
start_udc(udc);
}
--
1.9.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [PATCH 5/5] extcon: Remove deprecated extcon_set/get_cable_state_()
[not found] ` <CGME20170717012058epcas1p136b3a1e55ec313d68b941bc34a8f0779@epcas1p1.samsung.com>
@ 2017-07-17 1:20 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-17 1:20 UTC (permalink / raw)
To: kishon, balbi, gregkh
Cc: linux-kernel, linux-arm-kernel, linux-usb, cw00.choi, chanwoo,
myungjoo.ham
The commit 575c2b867ee0 ("extcon: Rename the extcon_set/get_state()
to maintain the function naming pattern") renames the extcon function as
following: But, the extcon just keeps the old API to prevent the build error.
This patch removes the deprecatd extcon API.
- extcon_get_cable_state_() -> extcon_get_state()
- extcon_set_cable_state_() -> extcon_set_state_sync()
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
---
include/linux/extcon.h | 11 -----------
1 file changed, 11 deletions(-)
diff --git a/include/linux/extcon.h b/include/linux/extcon.h
index 7e206a9f88db..3ba02eecba2e 100644
--- a/include/linux/extcon.h
+++ b/include/linux/extcon.h
@@ -422,15 +422,4 @@ static inline int extcon_unregister_interest(struct extcon_specific_cable_nb
{
return -EINVAL;
}
-
-static inline int extcon_get_cable_state_(struct extcon_dev *edev, unsigned int id)
-{
- return extcon_get_state(edev, id);
-}
-
-static inline int extcon_set_cable_state_(struct extcon_dev *edev, unsigned int id,
- bool cable_state)
-{
- return extcon_set_state_sync(edev, id, cable_state);
-}
#endif /* __LINUX_EXTCON_H__ */
--
1.9.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [PATCH 5/5] extcon: Remove deprecated extcon_set/get_cable_state_()
@ 2017-07-17 1:20 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-17 1:20 UTC (permalink / raw)
To: linux-arm-kernel
The commit 575c2b867ee0 ("extcon: Rename the extcon_set/get_state()
to maintain the function naming pattern") renames the extcon function as
following: But, the extcon just keeps the old API to prevent the build error.
This patch removes the deprecatd extcon API.
- extcon_get_cable_state_() -> extcon_get_state()
- extcon_set_cable_state_() -> extcon_set_state_sync()
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
---
include/linux/extcon.h | 11 -----------
1 file changed, 11 deletions(-)
diff --git a/include/linux/extcon.h b/include/linux/extcon.h
index 7e206a9f88db..3ba02eecba2e 100644
--- a/include/linux/extcon.h
+++ b/include/linux/extcon.h
@@ -422,15 +422,4 @@ static inline int extcon_unregister_interest(struct extcon_specific_cable_nb
{
return -EINVAL;
}
-
-static inline int extcon_get_cable_state_(struct extcon_dev *edev, unsigned int id)
-{
- return extcon_get_state(edev, id);
-}
-
-static inline int extcon_set_cable_state_(struct extcon_dev *edev, unsigned int id,
- bool cable_state)
-{
- return extcon_set_state_sync(edev, id, cable_state);
-}
#endif /* __LINUX_EXTCON_H__ */
--
1.9.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* Re: [PATCH 0/5] phy: Replace the deprecated extcon API
2017-07-17 1:20 ` Chanwoo Choi
@ 2017-07-31 1:48 ` Chanwoo Choi
-1 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-31 1:48 UTC (permalink / raw)
To: kishon, balbi, gregkh
Cc: linux-kernel, linux-arm-kernel, linux-usb, chanwoo, myungjoo.ham
Dear Kishon and Felipe,
Please review the patch3/patch4.
On 2017년 07월 17일 10:20, Chanwoo Choi wrote:
> These patches replace the deprecated extcon API
> and remove them from extcon framework.
>
> The patch1 and patch2 were already acked by Kishon Vijay Abraham I.
> If patch3/patch4 are reviewed, I'll create the immutable branch
> and send the pull request to both usb and phy maintainer.
>
> Chanwoo Choi (5):
> phy: qcom-usb-hs: Replace the extcon API
> phy: rockchip-inno-usb2: Replace the extcon API
> phy: phy-bcm-ns2-usbdrd: Replace the deprecated extcon API
> usb: gadget: udc: Replace the deprecated extcon API
> extcon: Remove deprecated extcon_set/get_cable_state_()
>
> drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c | 8 ++++----
> drivers/phy/qualcomm/phy-qcom-usb-hs.c | 14 +++-----------
> drivers/phy/rockchip/phy-rockchip-inno-usb2.c | 10 +++++-----
> drivers/usb/gadget/udc/snps_udc_plat.c | 6 +++---
> include/linux/extcon.h | 11 -----------
> 5 files changed, 15 insertions(+), 34 deletions(-)
>
--
Best Regards,
Chanwoo Choi
Samsung Electronics
^ permalink raw reply [flat|nested] 22+ messages in thread
* [PATCH 0/5] phy: Replace the deprecated extcon API
@ 2017-07-31 1:48 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-07-31 1:48 UTC (permalink / raw)
To: linux-arm-kernel
Dear Kishon and Felipe,
Please review the patch3/patch4.
On 2017? 07? 17? 10:20, Chanwoo Choi wrote:
> These patches replace the deprecated extcon API
> and remove them from extcon framework.
>
> The patch1 and patch2 were already acked by Kishon Vijay Abraham I.
> If patch3/patch4 are reviewed, I'll create the immutable branch
> and send the pull request to both usb and phy maintainer.
>
> Chanwoo Choi (5):
> phy: qcom-usb-hs: Replace the extcon API
> phy: rockchip-inno-usb2: Replace the extcon API
> phy: phy-bcm-ns2-usbdrd: Replace the deprecated extcon API
> usb: gadget: udc: Replace the deprecated extcon API
> extcon: Remove deprecated extcon_set/get_cable_state_()
>
> drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c | 8 ++++----
> drivers/phy/qualcomm/phy-qcom-usb-hs.c | 14 +++-----------
> drivers/phy/rockchip/phy-rockchip-inno-usb2.c | 10 +++++-----
> drivers/usb/gadget/udc/snps_udc_plat.c | 6 +++---
> include/linux/extcon.h | 11 -----------
> 5 files changed, 15 insertions(+), 34 deletions(-)
>
--
Best Regards,
Chanwoo Choi
Samsung Electronics
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [PATCH 2/5] phy: rockchip-inno-usb2: Replace the extcon API
@ 2017-08-02 5:12 ` Kishon Vijay Abraham I
0 siblings, 0 replies; 22+ messages in thread
From: Kishon Vijay Abraham I @ 2017-08-02 5:12 UTC (permalink / raw)
To: Chanwoo Choi, balbi, gregkh
Cc: linux-kernel, linux-arm-kernel, linux-usb, chanwoo, myungjoo.ham,
linux-rockchip
On Monday 17 July 2017 06:50 AM, Chanwoo Choi wrote:
> This patch uses the resource-managed extcon API for extcon_register_notifier()
> and replaces the deprecated extcon API as following:
> - extcon_get_cable_state_() -> extcon_get_state()
> - extcon_set_cable_state_() -> extcon_set_state_sync()
>
> Cc: linux-rockchip@lists.infradead.org
> acked-by: Kishon Vijay Abraham I <kishon@ti.com>
^
should be 'A' here.
-Kishon
> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
> ---
> drivers/phy/rockchip/phy-rockchip-inno-usb2.c | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
> index 626883d9d176..ef033089b7a0 100644
> --- a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
> +++ b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
> @@ -545,7 +545,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
> rockchip_usb2phy_power_off(rport->phy);
> /* fall through */
> case OTG_STATE_B_IDLE:
> - if (extcon_get_cable_state_(rphy->edev, EXTCON_USB_HOST) > 0) {
> + if (extcon_get_state(rphy->edev, EXTCON_USB_HOST) > 0) {
> dev_dbg(&rport->phy->dev, "usb otg host connect\n");
> rport->state = OTG_STATE_A_HOST;
> rockchip_usb2phy_power_on(rport->phy);
> @@ -598,7 +598,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
> rport->vbus_attached = vbus_attach;
>
> if (notify_charger && rphy->edev) {
> - extcon_set_cable_state_(rphy->edev,
> + extcon_set_state_sync(rphy->edev,
> cable, vbus_attach);
> if (cable == EXTCON_CHG_USB_SDP)
> extcon_set_state_sync(rphy->edev,
> @@ -619,7 +619,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
> sch_work = true;
> break;
> case OTG_STATE_A_HOST:
> - if (extcon_get_cable_state_(rphy->edev, EXTCON_USB_HOST) == 0) {
> + if (extcon_get_state(rphy->edev, EXTCON_USB_HOST) == 0) {
> dev_dbg(&rport->phy->dev, "usb otg host disconnect\n");
> rport->state = OTG_STATE_B_IDLE;
> rockchip_usb2phy_power_off(rport->phy);
> @@ -1006,8 +1006,8 @@ static int rockchip_usb2phy_otg_port_init(struct rockchip_usb2phy *rphy,
> if (!IS_ERR(rphy->edev)) {
> rport->event_nb.notifier_call = rockchip_otg_event;
>
> - ret = extcon_register_notifier(rphy->edev, EXTCON_USB_HOST,
> - &rport->event_nb);
> + ret = devm_extcon_register_notifier(rphy->dev, rphy->edev,
> + EXTCON_USB_HOST, &rport->event_nb);
> if (ret)
> dev_err(rphy->dev, "register USB HOST notifier failed\n");
> }
>
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [PATCH 2/5] phy: rockchip-inno-usb2: Replace the extcon API
@ 2017-08-02 5:12 ` Kishon Vijay Abraham I
0 siblings, 0 replies; 22+ messages in thread
From: Kishon Vijay Abraham I @ 2017-08-02 5:12 UTC (permalink / raw)
To: Chanwoo Choi, balbi-DgEjT+Ai2ygdnm+yROfE0A,
gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r
Cc: linux-usb-u79uwXL29TY76Z2rM5mHXA,
linux-kernel-u79uwXL29TY76Z2rM5mHXA,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
myungjoo.ham-Sze3O3UU22JBDgjK7y7TUQ,
chanwoo-DgEjT+Ai2ygdnm+yROfE0A,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r
On Monday 17 July 2017 06:50 AM, Chanwoo Choi wrote:
> This patch uses the resource-managed extcon API for extcon_register_notifier()
> and replaces the deprecated extcon API as following:
> - extcon_get_cable_state_() -> extcon_get_state()
> - extcon_set_cable_state_() -> extcon_set_state_sync()
>
> Cc: linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
> acked-by: Kishon Vijay Abraham I <kishon-l0cyMroinI0@public.gmane.org>
^
should be 'A' here.
-Kishon
> Signed-off-by: Chanwoo Choi <cw00.choi-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
> ---
> drivers/phy/rockchip/phy-rockchip-inno-usb2.c | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
> index 626883d9d176..ef033089b7a0 100644
> --- a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
> +++ b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
> @@ -545,7 +545,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
> rockchip_usb2phy_power_off(rport->phy);
> /* fall through */
> case OTG_STATE_B_IDLE:
> - if (extcon_get_cable_state_(rphy->edev, EXTCON_USB_HOST) > 0) {
> + if (extcon_get_state(rphy->edev, EXTCON_USB_HOST) > 0) {
> dev_dbg(&rport->phy->dev, "usb otg host connect\n");
> rport->state = OTG_STATE_A_HOST;
> rockchip_usb2phy_power_on(rport->phy);
> @@ -598,7 +598,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
> rport->vbus_attached = vbus_attach;
>
> if (notify_charger && rphy->edev) {
> - extcon_set_cable_state_(rphy->edev,
> + extcon_set_state_sync(rphy->edev,
> cable, vbus_attach);
> if (cable == EXTCON_CHG_USB_SDP)
> extcon_set_state_sync(rphy->edev,
> @@ -619,7 +619,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
> sch_work = true;
> break;
> case OTG_STATE_A_HOST:
> - if (extcon_get_cable_state_(rphy->edev, EXTCON_USB_HOST) == 0) {
> + if (extcon_get_state(rphy->edev, EXTCON_USB_HOST) == 0) {
> dev_dbg(&rport->phy->dev, "usb otg host disconnect\n");
> rport->state = OTG_STATE_B_IDLE;
> rockchip_usb2phy_power_off(rport->phy);
> @@ -1006,8 +1006,8 @@ static int rockchip_usb2phy_otg_port_init(struct rockchip_usb2phy *rphy,
> if (!IS_ERR(rphy->edev)) {
> rport->event_nb.notifier_call = rockchip_otg_event;
>
> - ret = extcon_register_notifier(rphy->edev, EXTCON_USB_HOST,
> - &rport->event_nb);
> + ret = devm_extcon_register_notifier(rphy->dev, rphy->edev,
> + EXTCON_USB_HOST, &rport->event_nb);
> if (ret)
> dev_err(rphy->dev, "register USB HOST notifier failed\n");
> }
>
^ permalink raw reply [flat|nested] 22+ messages in thread
* [PATCH 2/5] phy: rockchip-inno-usb2: Replace the extcon API
@ 2017-08-02 5:12 ` Kishon Vijay Abraham I
0 siblings, 0 replies; 22+ messages in thread
From: Kishon Vijay Abraham I @ 2017-08-02 5:12 UTC (permalink / raw)
To: linux-arm-kernel
On Monday 17 July 2017 06:50 AM, Chanwoo Choi wrote:
> This patch uses the resource-managed extcon API for extcon_register_notifier()
> and replaces the deprecated extcon API as following:
> - extcon_get_cable_state_() -> extcon_get_state()
> - extcon_set_cable_state_() -> extcon_set_state_sync()
>
> Cc: linux-rockchip at lists.infradead.org
> acked-by: Kishon Vijay Abraham I <kishon@ti.com>
^
should be 'A' here.
-Kishon
> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
> ---
> drivers/phy/rockchip/phy-rockchip-inno-usb2.c | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
> index 626883d9d176..ef033089b7a0 100644
> --- a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
> +++ b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
> @@ -545,7 +545,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
> rockchip_usb2phy_power_off(rport->phy);
> /* fall through */
> case OTG_STATE_B_IDLE:
> - if (extcon_get_cable_state_(rphy->edev, EXTCON_USB_HOST) > 0) {
> + if (extcon_get_state(rphy->edev, EXTCON_USB_HOST) > 0) {
> dev_dbg(&rport->phy->dev, "usb otg host connect\n");
> rport->state = OTG_STATE_A_HOST;
> rockchip_usb2phy_power_on(rport->phy);
> @@ -598,7 +598,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
> rport->vbus_attached = vbus_attach;
>
> if (notify_charger && rphy->edev) {
> - extcon_set_cable_state_(rphy->edev,
> + extcon_set_state_sync(rphy->edev,
> cable, vbus_attach);
> if (cable == EXTCON_CHG_USB_SDP)
> extcon_set_state_sync(rphy->edev,
> @@ -619,7 +619,7 @@ static void rockchip_usb2phy_otg_sm_work(struct work_struct *work)
> sch_work = true;
> break;
> case OTG_STATE_A_HOST:
> - if (extcon_get_cable_state_(rphy->edev, EXTCON_USB_HOST) == 0) {
> + if (extcon_get_state(rphy->edev, EXTCON_USB_HOST) == 0) {
> dev_dbg(&rport->phy->dev, "usb otg host disconnect\n");
> rport->state = OTG_STATE_B_IDLE;
> rockchip_usb2phy_power_off(rport->phy);
> @@ -1006,8 +1006,8 @@ static int rockchip_usb2phy_otg_port_init(struct rockchip_usb2phy *rphy,
> if (!IS_ERR(rphy->edev)) {
> rport->event_nb.notifier_call = rockchip_otg_event;
>
> - ret = extcon_register_notifier(rphy->edev, EXTCON_USB_HOST,
> - &rport->event_nb);
> + ret = devm_extcon_register_notifier(rphy->dev, rphy->edev,
> + EXTCON_USB_HOST, &rport->event_nb);
> if (ret)
> dev_err(rphy->dev, "register USB HOST notifier failed\n");
> }
>
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [PATCH 3/5] phy: phy-bcm-ns2-usbdrd: Replace the deprecated extcon API
2017-07-17 1:20 ` Chanwoo Choi
@ 2017-08-02 5:12 ` Kishon Vijay Abraham I
-1 siblings, 0 replies; 22+ messages in thread
From: Kishon Vijay Abraham I @ 2017-08-02 5:12 UTC (permalink / raw)
To: Chanwoo Choi, balbi, gregkh
Cc: linux-kernel, linux-arm-kernel, linux-usb, chanwoo, myungjoo.ham,
Raviteja Garimella
On Monday 17 July 2017 06:50 AM, Chanwoo Choi wrote:
> This patch replaces the deprecated extcon API as following:
> - extcon_set_cable_state_() -> extcon_get_state()
>
> Cc: Kishon Vijay Abraham I <kishon@ti.com>
> Cc: Raviteja Garimella <raviteja.garimella@broadcom.com>
> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
Acked-by: Kishon Vijay Abraham I <kishon@ti.com>
> ---
> drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c b/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c
> index 9ae59e223131..d099a0c8cee5 100644
> --- a/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c
> +++ b/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c
> @@ -253,16 +253,16 @@ static void extcon_work(struct work_struct *work)
> vbus = gpiod_get_value_cansleep(driver->vbus_gpiod);
>
> if (!id && vbus) { /* Host connected */
> - extcon_set_cable_state_(driver->edev, EXTCON_USB_HOST, true);
> + extcon_set_state_sync(driver->edev, EXTCON_USB_HOST, true);
> pr_debug("Host cable connected\n");
> driver->data->new_state = EVT_HOST;
> connect_change(driver);
> } else if (id && !vbus) { /* Disconnected */
> - extcon_set_cable_state_(driver->edev, EXTCON_USB_HOST, false);
> - extcon_set_cable_state_(driver->edev, EXTCON_USB, false);
> + extcon_set_state_sync(driver->edev, EXTCON_USB_HOST, false);
> + extcon_set_state_sync(driver->edev, EXTCON_USB, false);
> pr_debug("Cable disconnected\n");
> } else if (id && vbus) { /* Device connected */
> - extcon_set_cable_state_(driver->edev, EXTCON_USB, true);
> + extcon_set_state_sync(driver->edev, EXTCON_USB, true);
> pr_debug("Device cable connected\n");
> driver->data->new_state = EVT_DEVICE;
> connect_change(driver);
>
^ permalink raw reply [flat|nested] 22+ messages in thread
* [PATCH 3/5] phy: phy-bcm-ns2-usbdrd: Replace the deprecated extcon API
@ 2017-08-02 5:12 ` Kishon Vijay Abraham I
0 siblings, 0 replies; 22+ messages in thread
From: Kishon Vijay Abraham I @ 2017-08-02 5:12 UTC (permalink / raw)
To: linux-arm-kernel
On Monday 17 July 2017 06:50 AM, Chanwoo Choi wrote:
> This patch replaces the deprecated extcon API as following:
> - extcon_set_cable_state_() -> extcon_get_state()
>
> Cc: Kishon Vijay Abraham I <kishon@ti.com>
> Cc: Raviteja Garimella <raviteja.garimella@broadcom.com>
> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
Acked-by: Kishon Vijay Abraham I <kishon@ti.com>
> ---
> drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c b/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c
> index 9ae59e223131..d099a0c8cee5 100644
> --- a/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c
> +++ b/drivers/phy/broadcom/phy-bcm-ns2-usbdrd.c
> @@ -253,16 +253,16 @@ static void extcon_work(struct work_struct *work)
> vbus = gpiod_get_value_cansleep(driver->vbus_gpiod);
>
> if (!id && vbus) { /* Host connected */
> - extcon_set_cable_state_(driver->edev, EXTCON_USB_HOST, true);
> + extcon_set_state_sync(driver->edev, EXTCON_USB_HOST, true);
> pr_debug("Host cable connected\n");
> driver->data->new_state = EVT_HOST;
> connect_change(driver);
> } else if (id && !vbus) { /* Disconnected */
> - extcon_set_cable_state_(driver->edev, EXTCON_USB_HOST, false);
> - extcon_set_cable_state_(driver->edev, EXTCON_USB, false);
> + extcon_set_state_sync(driver->edev, EXTCON_USB_HOST, false);
> + extcon_set_state_sync(driver->edev, EXTCON_USB, false);
> pr_debug("Cable disconnected\n");
> } else if (id && vbus) { /* Device connected */
> - extcon_set_cable_state_(driver->edev, EXTCON_USB, true);
> + extcon_set_state_sync(driver->edev, EXTCON_USB, true);
> pr_debug("Device cable connected\n");
> driver->data->new_state = EVT_DEVICE;
> connect_change(driver);
>
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [PATCH 2/5] phy: rockchip-inno-usb2: Replace the extcon API
@ 2017-08-03 8:11 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-08-03 8:11 UTC (permalink / raw)
To: Kishon Vijay Abraham I, balbi, gregkh
Cc: linux-kernel, linux-arm-kernel, linux-usb, chanwoo, myungjoo.ham,
linux-rockchip
Hi,
On 2017년 08월 02일 14:12, Kishon Vijay Abraham I wrote:
>
>
> On Monday 17 July 2017 06:50 AM, Chanwoo Choi wrote:
>> This patch uses the resource-managed extcon API for extcon_register_notifier()
>> and replaces the deprecated extcon API as following:
>> - extcon_get_cable_state_() -> extcon_get_state()
>> - extcon_set_cable_state_() -> extcon_set_state_sync()
>>
>> Cc: linux-rockchip@lists.infradead.org
>> acked-by: Kishon Vijay Abraham I <kishon@ti.com>
> ^
> should be 'A' here.
My mistake. I'll fix it.
[snip]
--
Best Regards,
Chanwoo Choi
Samsung Electronics
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [PATCH 2/5] phy: rockchip-inno-usb2: Replace the extcon API
@ 2017-08-03 8:11 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-08-03 8:11 UTC (permalink / raw)
To: Kishon Vijay Abraham I, balbi-DgEjT+Ai2ygdnm+yROfE0A,
gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r
Cc: linux-kernel-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-usb-u79uwXL29TY76Z2rM5mHXA, chanwoo-DgEjT+Ai2ygdnm+yROfE0A,
myungjoo.ham-Sze3O3UU22JBDgjK7y7TUQ,
linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r
Hi,
On 2017년 08월 02일 14:12, Kishon Vijay Abraham I wrote:
>
>
> On Monday 17 July 2017 06:50 AM, Chanwoo Choi wrote:
>> This patch uses the resource-managed extcon API for extcon_register_notifier()
>> and replaces the deprecated extcon API as following:
>> - extcon_get_cable_state_() -> extcon_get_state()
>> - extcon_set_cable_state_() -> extcon_set_state_sync()
>>
>> Cc: linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
>> acked-by: Kishon Vijay Abraham I <kishon-l0cyMroinI0@public.gmane.org>
> ^
> should be 'A' here.
My mistake. I'll fix it.
[snip]
--
Best Regards,
Chanwoo Choi
Samsung Electronics
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 22+ messages in thread
* [PATCH 2/5] phy: rockchip-inno-usb2: Replace the extcon API
@ 2017-08-03 8:11 ` Chanwoo Choi
0 siblings, 0 replies; 22+ messages in thread
From: Chanwoo Choi @ 2017-08-03 8:11 UTC (permalink / raw)
To: linux-arm-kernel
Hi,
On 2017? 08? 02? 14:12, Kishon Vijay Abraham I wrote:
>
>
> On Monday 17 July 2017 06:50 AM, Chanwoo Choi wrote:
>> This patch uses the resource-managed extcon API for extcon_register_notifier()
>> and replaces the deprecated extcon API as following:
>> - extcon_get_cable_state_() -> extcon_get_state()
>> - extcon_set_cable_state_() -> extcon_set_state_sync()
>>
>> Cc: linux-rockchip at lists.infradead.org
>> acked-by: Kishon Vijay Abraham I <kishon@ti.com>
> ^
> should be 'A' here.
My mistake. I'll fix it.
[snip]
--
Best Regards,
Chanwoo Choi
Samsung Electronics
^ permalink raw reply [flat|nested] 22+ messages in thread
end of thread, other threads:[~2017-08-03 8:11 UTC | newest]
Thread overview: 22+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <CGME20170717012057epcas1p11fe3d445ed16c7f94b57922b0a8f243a@epcas1p1.samsung.com>
2017-07-17 1:20 ` [PATCH 0/5] phy: Replace the deprecated extcon API Chanwoo Choi
2017-07-17 1:20 ` Chanwoo Choi
[not found] ` <CGME20170717012058epcas1p181ca458cd4c80643ee7077e9ee78f7bb@epcas1p1.samsung.com>
2017-07-17 1:20 ` [PATCH 1/5] phy: qcom-usb-hs: Replace the " Chanwoo Choi
2017-07-17 1:20 ` Chanwoo Choi
[not found] ` <CGME20170717012058epcas1p157e9a296eb5e415ae24bb51a1e6026db@epcas1p1.samsung.com>
2017-07-17 1:20 ` [PATCH 2/5] phy: rockchip-inno-usb2: " Chanwoo Choi
2017-07-17 1:20 ` Chanwoo Choi
2017-08-02 5:12 ` Kishon Vijay Abraham I
2017-08-02 5:12 ` Kishon Vijay Abraham I
2017-08-02 5:12 ` Kishon Vijay Abraham I
2017-08-03 8:11 ` Chanwoo Choi
2017-08-03 8:11 ` Chanwoo Choi
2017-08-03 8:11 ` Chanwoo Choi
[not found] ` <CGME20170717012058epcas1p10b22154ffb2184cae7453a8b557dbcca@epcas1p1.samsung.com>
2017-07-17 1:20 ` [PATCH 3/5] phy: phy-bcm-ns2-usbdrd: Replace the deprecated " Chanwoo Choi
2017-07-17 1:20 ` Chanwoo Choi
2017-08-02 5:12 ` Kishon Vijay Abraham I
2017-08-02 5:12 ` Kishon Vijay Abraham I
[not found] ` <CGME20170717012058epcas1p1080175f81148a406fcc9713d490fc894@epcas1p1.samsung.com>
2017-07-17 1:20 ` [PATCH 4/5] usb: gadget: udc: " Chanwoo Choi
2017-07-17 1:20 ` Chanwoo Choi
[not found] ` <CGME20170717012058epcas1p136b3a1e55ec313d68b941bc34a8f0779@epcas1p1.samsung.com>
2017-07-17 1:20 ` [PATCH 5/5] extcon: Remove deprecated extcon_set/get_cable_state_() Chanwoo Choi
2017-07-17 1:20 ` Chanwoo Choi
2017-07-31 1:48 ` [PATCH 0/5] phy: Replace the deprecated extcon API Chanwoo Choi
2017-07-31 1:48 ` Chanwoo Choi
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.