From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751887AbdAJUtU (ORCPT ); Tue, 10 Jan 2017 15:49:20 -0500 Received: from fllnx209.ext.ti.com ([198.47.19.16]:23128 "EHLO fllnx209.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751155AbdAJUtS (ORCPT ); Tue, 10 Jan 2017 15:49:18 -0500 Date: Tue, 10 Jan 2017 14:47:23 -0600 From: Bin Liu To: Chanwoo Choi CC: , , , , , , Subject: Re: [PATCH v2] usb: musb: sunxi: Uses the resource-managed extcon API when registering extcon notifier Message-ID: <20170110204653.GD2479@uda0271908> Mail-Followup-To: Bin Liu , Chanwoo Choi , gregkh@linuxfoundation.org, maxime.ripard@free-electrons.com, wens@csie.org, linux-usb@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, chanwoo@kernel.org References: <1483071550-8683-1-git-send-email-cw00.choi@samsung.com> <58749956.1030800@samsung.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <58749956.1030800@samsung.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 10, 2017 at 05:20:38PM +0900, Chanwoo Choi wrote: > Hi Felipe, > > This patch got the acked-by from Bin Liu and. > Could you please apply this patch? I have picked this one. Regards, -Bin. > > On 2016년 12월 30일 13:19, Chanwoo Choi wrote: > > This patch just uses the resource-managed extcon API when registering > > the extcon notifier. > > > > Signed-off-by: Chanwoo Choi > > Acked-by: Maxime Ripard > > Acked-by: Bin Liu > > --- > > Changes from v1: > > - Rebase this patch based on v4.10-rc1. > > - Add acked-by tag from Maxime Ripard and Bin Lin. > > - Drop the phy/power-supply/chipidea patches. > > > > drivers/usb/musb/sunxi.c | 12 +++--------- > > 1 file changed, 3 insertions(+), 9 deletions(-) > > > > diff --git a/drivers/usb/musb/sunxi.c b/drivers/usb/musb/sunxi.c > > index d0be0eadd0d9..2332294dee0f 100644 > > --- a/drivers/usb/musb/sunxi.c > > +++ b/drivers/usb/musb/sunxi.c > > @@ -251,14 +251,14 @@ static int sunxi_musb_init(struct musb *musb) > > writeb(SUNXI_MUSB_VEND0_PIO_MODE, musb->mregs + SUNXI_MUSB_VEND0); > > > > /* Register notifier before calling phy_init() */ > > - ret = extcon_register_notifier(glue->extcon, EXTCON_USB_HOST, > > - &glue->host_nb); > > + ret = devm_extcon_register_notifier(glue->dev, glue->extcon, > > + EXTCON_USB_HOST, &glue->host_nb); > > if (ret) > > goto error_reset_assert; > > > > ret = phy_init(glue->phy); > > if (ret) > > - goto error_unregister_notifier; > > + goto error_reset_assert; > > > > musb->isr = sunxi_musb_interrupt; > > > > @@ -267,9 +267,6 @@ static int sunxi_musb_init(struct musb *musb) > > > > return 0; > > > > -error_unregister_notifier: > > - extcon_unregister_notifier(glue->extcon, EXTCON_USB_HOST, > > - &glue->host_nb); > > error_reset_assert: > > if (test_bit(SUNXI_MUSB_FL_HAS_RESET, &glue->flags)) > > reset_control_assert(glue->rst); > > @@ -293,9 +290,6 @@ static int sunxi_musb_exit(struct musb *musb) > > > > phy_exit(glue->phy); > > > > - extcon_unregister_notifier(glue->extcon, EXTCON_USB_HOST, > > - &glue->host_nb); > > - > > if (test_bit(SUNXI_MUSB_FL_HAS_RESET, &glue->flags)) > > reset_control_assert(glue->rst); > > > > > > > -- > Best Regards, > Chanwoo Choi > S/W Center, Samsung Electronics From mboxrd@z Thu Jan 1 00:00:00 1970 From: b-liu@ti.com (Bin Liu) Date: Tue, 10 Jan 2017 14:47:23 -0600 Subject: [PATCH v2] usb: musb: sunxi: Uses the resource-managed extcon API when registering extcon notifier In-Reply-To: <58749956.1030800@samsung.com> References: <1483071550-8683-1-git-send-email-cw00.choi@samsung.com> <58749956.1030800@samsung.com> Message-ID: <20170110204653.GD2479@uda0271908> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On Tue, Jan 10, 2017 at 05:20:38PM +0900, Chanwoo Choi wrote: > Hi Felipe, > > This patch got the acked-by from Bin Liu and. > Could you please apply this patch? I have picked this one. Regards, -Bin. > > On 2016? 12? 30? 13:19, Chanwoo Choi wrote: > > This patch just uses the resource-managed extcon API when registering > > the extcon notifier. > > > > Signed-off-by: Chanwoo Choi > > Acked-by: Maxime Ripard > > Acked-by: Bin Liu > > --- > > Changes from v1: > > - Rebase this patch based on v4.10-rc1. > > - Add acked-by tag from Maxime Ripard and Bin Lin. > > - Drop the phy/power-supply/chipidea patches. > > > > drivers/usb/musb/sunxi.c | 12 +++--------- > > 1 file changed, 3 insertions(+), 9 deletions(-) > > > > diff --git a/drivers/usb/musb/sunxi.c b/drivers/usb/musb/sunxi.c > > index d0be0eadd0d9..2332294dee0f 100644 > > --- a/drivers/usb/musb/sunxi.c > > +++ b/drivers/usb/musb/sunxi.c > > @@ -251,14 +251,14 @@ static int sunxi_musb_init(struct musb *musb) > > writeb(SUNXI_MUSB_VEND0_PIO_MODE, musb->mregs + SUNXI_MUSB_VEND0); > > > > /* Register notifier before calling phy_init() */ > > - ret = extcon_register_notifier(glue->extcon, EXTCON_USB_HOST, > > - &glue->host_nb); > > + ret = devm_extcon_register_notifier(glue->dev, glue->extcon, > > + EXTCON_USB_HOST, &glue->host_nb); > > if (ret) > > goto error_reset_assert; > > > > ret = phy_init(glue->phy); > > if (ret) > > - goto error_unregister_notifier; > > + goto error_reset_assert; > > > > musb->isr = sunxi_musb_interrupt; > > > > @@ -267,9 +267,6 @@ static int sunxi_musb_init(struct musb *musb) > > > > return 0; > > > > -error_unregister_notifier: > > - extcon_unregister_notifier(glue->extcon, EXTCON_USB_HOST, > > - &glue->host_nb); > > error_reset_assert: > > if (test_bit(SUNXI_MUSB_FL_HAS_RESET, &glue->flags)) > > reset_control_assert(glue->rst); > > @@ -293,9 +290,6 @@ static int sunxi_musb_exit(struct musb *musb) > > > > phy_exit(glue->phy); > > > > - extcon_unregister_notifier(glue->extcon, EXTCON_USB_HOST, > > - &glue->host_nb); > > - > > if (test_bit(SUNXI_MUSB_FL_HAS_RESET, &glue->flags)) > > reset_control_assert(glue->rst); > > > > > > > -- > Best Regards, > Chanwoo Choi > S/W Center, Samsung Electronics