Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp731000rwb; Wed, 28 Sep 2022 08:24:42 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4yJmHFvYRt4775WL9IVAOAwr0y31hzeE9YbCHvXAbhX9jVADafCNHYvuhzMBSH7It8iFoz X-Received: by 2002:a17:902:b710:b0:178:3128:b593 with SMTP id d16-20020a170902b71000b001783128b593mr367149pls.50.1664378682069; Wed, 28 Sep 2022 08:24:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664378682; cv=none; d=google.com; s=arc-20160816; b=ZsmUkLpvmp9dTK1U3JXkvL1RPzfYcCP+drqQbTY309HDFkRBt3K0NUHrmUHOdGpifS yiVDi2HLHlyMcEgeVWe5aG/McFTf8r9J0+vI+qQy4QvMBQ4I3Ujjwj+sfcrBsxjuXYm4 C1DV3X3+Q1rVbOMCBc6CnBPFSNHNyi94SUJjOflTXlaeDCi++QzlAvIEZSQKtlDF6OBN jteYnBCTGlMAW4qFiWs1v239k8ceV1iPjNfstoXE9L0San/Jwhv+x3WlFW8Wp1rLPZio ravMWOfPHsSM2OHRCqmdA067T+iie2xr8n7nEiVXdhFJVDf/FY6ZImVUAlMlxKLw5ykf JcQQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=hu04EyaKVT2l883oXPdkvoST6eyfvHXkRlNf3FhNvng=; b=FoJNRYBJatLIVI0JrI2TWuMZmHO/p5iAUCzrq86tbGD5EYARVVBhFI6L86q2ufyOtQ cfIRL9Gbs0KJXyPfMORCcfFiZ9pCpXm05ezFrBWEn8nhDBOUptcAOC+fVQ7AqnRIhFQt aD0+8CZqmFJT4ujM42dcPeN5SHPsK0vfldHdL55Z+bGrRFfoOZIsuU+57TkzGDZCj9g3 Fu2UbJmo51FOCzatAHlVzD7KBsJtrqAQx4sSz5sjwaMhUr64YHe/LH+Tnl1Jdpmf+JAY jFJjmEmU8EgACx+bDT95VU907L4lSzh1Z2kWdclTa/3LtZ9XN/FJkKftkaselC/yGN/z /A5A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k9-20020a636f09000000b0042bd54984e5si5704919pgc.722.2022.09.28.08.24.30; Wed, 28 Sep 2022 08:24:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234046AbiI1PPh (ORCPT + 99 others); Wed, 28 Sep 2022 11:15:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52390 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232294AbiI1PPf (ORCPT ); Wed, 28 Sep 2022 11:15:35 -0400 Received: from netrider.rowland.org (netrider.rowland.org [192.131.102.5]) by lindbergh.monkeyblade.net (Postfix) with SMTP id BD8CF3F1D5 for ; Wed, 28 Sep 2022 08:15:32 -0700 (PDT) Received: (qmail 489543 invoked by uid 1000); 28 Sep 2022 11:15:31 -0400 Date: Wed, 28 Sep 2022 11:15:31 -0400 From: Alan Stern To: Dmitry Torokhov Cc: Krzysztof Kozlowski , Alim Akhtar , Greg Kroah-Hartman , linux-usb@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 2/2] usb: host: ehci-exynos: switch to using gpiod API Message-ID: References: <20220927220504.3744878-1-dmitry.torokhov@gmail.com> <20220927220504.3744878-2-dmitry.torokhov@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220927220504.3744878-2-dmitry.torokhov@gmail.com> X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,SPF_HELO_PASS,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Sep 27, 2022 at 03:05:04PM -0700, Dmitry Torokhov wrote: > This patch switches the driver from using legacy gpio API to the newer > gpiod API. > > Signed-off-by: Dmitry Torokhov > --- Acked-by: Alan Stern > drivers/usb/host/ehci-exynos.c | 17 +++++------------ > 1 file changed, 5 insertions(+), 12 deletions(-) > > diff --git a/drivers/usb/host/ehci-exynos.c b/drivers/usb/host/ehci-exynos.c > index c8e152c2e0ce..a333231616f4 100644 > --- a/drivers/usb/host/ehci-exynos.c > +++ b/drivers/usb/host/ehci-exynos.c > @@ -13,7 +13,7 @@ > #include > #include > #include > -#include > +#include > #include > #include > #include > @@ -131,20 +131,13 @@ static void exynos_ehci_phy_disable(struct device *dev) > > static void exynos_setup_vbus_gpio(struct device *dev) > { > + struct gpio_desc *gpio; > int err; > - int gpio; > > - if (!dev->of_node) > - return; > - > - gpio = of_get_named_gpio(dev->of_node, "samsung,vbus-gpio", 0); > - if (!gpio_is_valid(gpio)) > - return; > - > - err = devm_gpio_request_one(dev, gpio, GPIOF_OUT_INIT_HIGH, > - "ehci_vbus_gpio"); > + gpio = devm_gpiod_get_optional(dev, "samsung,vbus", GPIOD_OUT_HIGH); > + err = PTR_ERR_OR_ZERO(gpio); > if (err) > - dev_err(dev, "can't request ehci vbus gpio %d", gpio); > + dev_err(dev, "can't request ehci vbus gpio: %d\n", err); > } > > static int exynos_ehci_probe(struct platform_device *pdev) > -- > 2.38.0.rc1.362.ged0d419d3c-goog >