From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E0B1CC10F13 for ; Thu, 11 Apr 2019 09:31:51 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A11782184B for ; Thu, 11 Apr 2019 09:31:51 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="JFPWe62F"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=bgdev-pl.20150623.gappssmtp.com header.i=@bgdev-pl.20150623.gappssmtp.com header.b="LlyzkDPY" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A11782184B Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=bgdev.pl Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=5Ob875eQj2NJNnaQ5h6I6i+vGLHsgJjOl1FCpcHGZJM=; b=JFPWe62F06DXLV 8Qa4VYHQjppv0OpU6EGsOp/sINj5UF71Yxrf16WH2qQsVb1rWKe51ZPDlromUi4Bm87Wibdo2EJaB LuCFQ8jRw784GkES8nVY+mJ+mhILor2mN8Abln7RTJF1FvzU6E+019dGkYj+KW+jQ4tXYvawSkr8i b7DxXERk4sSlYim4ygs6C51vM2KI7bpC19QP0XBKNgw2WkUszlEOTxFM5oL5wrke9uS/QiWEUMLJI qqPrPaVnR4K5nZYo4MaIO7meDLex5Kna/pU+TFhAm/Xi9hExHhmijiYB9A3mmjDXwVv+dMp6h6Ige tXMS7p083P9r0VDIeaNQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1hEW3Y-0005gw-U0; Thu, 11 Apr 2019 09:31:40 +0000 Received: from mail-wr1-x444.google.com ([2a00:1450:4864:20::444]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1hEW2Y-0004N2-Ll for linux-arm-kernel@lists.infradead.org; Thu, 11 Apr 2019 09:30:42 +0000 Received: by mail-wr1-x444.google.com with SMTP id k11so6377909wro.5 for ; Thu, 11 Apr 2019 02:30:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=GEMwZ7dACVPBfzPjV5lUAEHUp2v66lOC+jNy0RoKMOY=; b=LlyzkDPYBbaZhaZxDaCJQeEcRJlsiMK88jKOOYPHgM4JHgEAMT4mXUIzyQ4bGj/Sho HPL+a898sCKZQFA3IkjD8+Tg0UXsxgqVymMXWuakC1Xa6dk7F8Oni4qVjc5FsCT1UBSL UDXgxaYCostRpOyFVQYM5l3mJ5IWlZLLFfHEPD7m0rNDIvw7t8pygFYCx+ExK93cggyE ZgMRZteuozoCHXFz0u97rjYaLukxANYOREJNMzFABXsUV12i1tQEgEa3HJ5gzYhVfYk2 ToSma/VCEARgw+B7FrjK+FNXa6LHzwlXtwuCHrE1kFxwbBSkIbUQYqijq/NykWbxEj5M vInw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=GEMwZ7dACVPBfzPjV5lUAEHUp2v66lOC+jNy0RoKMOY=; b=A5PqznpDrKY7rwC47TxiE1ZXDCEOowip1/IdeKCjBvGqSbzNyer+ecppqNsY6iDUev rIf4/kWBUeAb5g4H39eF37O8VK+5Nkanx4168WKE405gL9qrVvkXGqMi9BXk7aC9VB1q S6uX7Rd+KbdFlikCZCe8ctdzjoFwUWdFVnDHFORW/w9q6SV6UNn6ppGCggPIudFFNLS+ v839BynEPPbGKczEPKOv9ovRBphxyKcogJ2Hb/2BhVBVSwy91oqDYxNfc0uwww0BK+3g R1kXDag6RUKXhbCksoZUUipcwe1XAPy3hrpVE5kes3tEHBZkZ7XzJietA8iM3pE7kvRs MmRQ== X-Gm-Message-State: APjAAAUgDe+54Y1E2xRRT1c8UhkN4JtZaUPs6g+JxXcKvBPtyIxjbUkN nV3XFUg8grwgx0X230ktdXduDA== X-Google-Smtp-Source: APXvYqzCqKZqTCUAbmAkyBuRWTsPX7ZNDJpnNQwb4R31fGKGfvuHcm/TQXGa4undHOlTqs9Fw2CNog== X-Received: by 2002:adf:e449:: with SMTP id t9mr29387776wrm.204.1554975036963; Thu, 11 Apr 2019 02:30:36 -0700 (PDT) Received: from debian-brgl.home ([2a01:cb1d:af:5b00:6d6c:8493:1ab5:dad7]) by smtp.gmail.com with ESMTPSA id a9sm37517228wrt.29.2019.04.11.02.30.35 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 11 Apr 2019 02:30:36 -0700 (PDT) From: Bartosz Golaszewski To: Sekhar Nori , Kevin Hilman , Alan Stern , Greg Kroah-Hartman Subject: [PATCH v4 6/6] usb: ohci-da8xx: drop the vbus GPIO Date: Thu, 11 Apr 2019 11:30:24 +0200 Message-Id: <20190411093024.23555-7-brgl@bgdev.pl> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190411093024.23555-1-brgl@bgdev.pl> References: <20190411093024.23555-1-brgl@bgdev.pl> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190411_023039_308977_ED389D4A X-CRM114-Status: GOOD ( 13.44 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Bartosz Golaszewski , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Bartosz Golaszewski All users now setup a fixed regulator for the vbus supply. We can drop the vbus GPIO code. Signed-off-by: Bartosz Golaszewski Acked-by: Alan Stern --- drivers/usb/host/ohci-da8xx.c | 21 +-------------------- 1 file changed, 1 insertion(+), 20 deletions(-) diff --git a/drivers/usb/host/ohci-da8xx.c b/drivers/usb/host/ohci-da8xx.c index 6158408b1ea0..674641c94c9e 100644 --- a/drivers/usb/host/ohci-da8xx.c +++ b/drivers/usb/host/ohci-da8xx.c @@ -40,7 +40,6 @@ struct da8xx_ohci_hcd { struct phy *usb11_phy; struct regulator *vbus_reg; struct notifier_block nb; - struct gpio_desc *vbus_gpio; struct gpio_desc *oc_gpio; }; @@ -91,11 +90,6 @@ static int ohci_da8xx_set_power(struct usb_hcd *hcd, int on) struct device *dev = hcd->self.controller; int ret; - if (da8xx_ohci->vbus_gpio) { - gpiod_set_value_cansleep(da8xx_ohci->vbus_gpio, on); - return 0; - } - if (!da8xx_ohci->vbus_reg) return 0; @@ -120,9 +114,6 @@ static int ohci_da8xx_get_power(struct usb_hcd *hcd) { struct da8xx_ohci_hcd *da8xx_ohci = to_da8xx_ohci(hcd); - if (da8xx_ohci->vbus_gpio) - return gpiod_get_value_cansleep(da8xx_ohci->vbus_gpio); - if (da8xx_ohci->vbus_reg) return regulator_is_enabled(da8xx_ohci->vbus_reg); @@ -155,9 +146,6 @@ static int ohci_da8xx_has_set_power(struct usb_hcd *hcd) { struct da8xx_ohci_hcd *da8xx_ohci = to_da8xx_ohci(hcd); - if (da8xx_ohci->vbus_gpio) - return 1; - if (da8xx_ohci->vbus_reg) return 1; @@ -209,9 +197,7 @@ static irqreturn_t ohci_da8xx_oc_thread(int irq, void *data) int ret; if (gpiod_get_value_cansleep(da8xx_ohci->oc_gpio)) { - if (da8xx_ohci->vbus_gpio) { - gpiod_set_value_cansleep(da8xx_ohci->vbus_gpio, 0); - } else if (da8xx_ohci->vbus_reg) { + if (da8xx_ohci->vbus_reg) { ret = regulator_disable(da8xx_ohci->vbus_reg); if (ret) dev_err(dev, @@ -432,11 +418,6 @@ static int ohci_da8xx_probe(struct platform_device *pdev) } } - da8xx_ohci->vbus_gpio = devm_gpiod_get_optional(dev, "vbus", - GPIOD_OUT_HIGH); - if (IS_ERR(da8xx_ohci->vbus_gpio)) - goto err; - da8xx_ohci->oc_gpio = devm_gpiod_get_optional(dev, "oc", GPIOD_IN); if (IS_ERR(da8xx_ohci->oc_gpio)) goto err; -- 2.21.0 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel