From patchwork Sun May 6 14:19:21 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Akinobu Mita X-Patchwork-Id: 10382819 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id BD7E46037F for ; Sun, 6 May 2018 14:20:26 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A8D3E2892B for ; Sun, 6 May 2018 14:20:26 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 989C828A2D; Sun, 6 May 2018 14:20:26 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, MAILING_LIST_MULTI, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 60EF62892B for ; Sun, 6 May 2018 14:20:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751796AbeEFOUE (ORCPT ); Sun, 6 May 2018 10:20:04 -0400 Received: from mail-pg0-f67.google.com ([74.125.83.67]:34336 "EHLO mail-pg0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751777AbeEFOUD (ORCPT ); Sun, 6 May 2018 10:20:03 -0400 Received: by mail-pg0-f67.google.com with SMTP id g20-v6so11772303pgv.1; Sun, 06 May 2018 07:20:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=jgu6WggUbTOQp0RiX3b55pgj7veJg22ii4FHEKMQfBQ=; b=ckA8YB0ePBPtOXQI3027LAKEFIrRQ7q1j/7UPrr7Z1E2+50VHiaPfz4kiTGx3+922q sSjAhtaZAvd1H6z5tHmMmjDfYqdm5PIP5NyA7yVKxf6jFLqXSP0ALxjphvgDGEbzFFHc GiAOn+OrrHcDcNDIXj/sNN9Skk97jJOIKFo5I/6j2JKToi2uA5HgxNQ7Z/Sf4hsIXwM0 4ccFCYyWTG2NslXYTIWj9mBYu5YCNoTuzcf7yovj2i1AcszNgXCUobRz0e2hbSQUHh7r b8rJxjXW37UpOVOZJov3PH85iCIuMNBn4scKnh8gNyGUhXDt0DA2j2Hy9Alw3b5UWLtG MI4Q== 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; bh=jgu6WggUbTOQp0RiX3b55pgj7veJg22ii4FHEKMQfBQ=; b=XLoQkO0TeaMmgU1LSyQxg6skU0jBxEyL3GsoGIdTS3QlgkP3EgSz0ee0z5t/+rcxTg a8okUziIbLDthQVU34fp4uAWTPgMlvSFTO7Qf1ZHByrRSYkA/Jp/kpRzAYU6y0+ntLNe 9MLT2IZiIMANGI1OlJCmOZVsl7pgWa7kc+LC5ZEZhI6WH4LgwcHm3wQQT7e/lRysMgLL Yei/tUbaVwqKv0oIf/lkDTubcckEC9je52ZO920vOLq+4acq1o2zMZUV7i0IrMPGoNSM N0wyHPHoJehQ3kZ9fU9flmINAHjpNfJ+k9GNOxr3wNNcdTEu1Kv1UwhJXWFha1e/r/Wi 8GkA== X-Gm-Message-State: ALQs6tDV1KHxWrXoEkTtopJ3fsZ0kmKOqi2sGEf5daBKAajku1O3l3dX t636Kpnd3McFYgT9zELyg6nt0A== X-Google-Smtp-Source: AB8JxZrYcFiMhpoSUGETISf2iir3inOEgQDggU3sZaMev+lyXryNGIpDnONko+NY7qrcPKjwhtYYVg== X-Received: by 2002:a17:902:a616:: with SMTP id u22-v6mr10429547plq.186.1525616402527; Sun, 06 May 2018 07:20:02 -0700 (PDT) Received: from localhost.localdomain ([240f:4:c2bc:1:141a:15e1:5268:11ce]) by smtp.gmail.com with ESMTPSA id s88sm58766771pfe.43.2018.05.06.07.20.00 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 06 May 2018 07:20:02 -0700 (PDT) From: Akinobu Mita To: linux-media@vger.kernel.org, devicetree@vger.kernel.org Cc: Akinobu Mita , Jacopo Mondi , Laurent Pinchart , Hans Verkuil , Sakari Ailus , Mauro Carvalho Chehab Subject: [PATCH v5 06/14] media: ov772x: use generic names for reset and powerdown gpios Date: Sun, 6 May 2018 23:19:21 +0900 Message-Id: <1525616369-8843-7-git-send-email-akinobu.mita@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1525616369-8843-1-git-send-email-akinobu.mita@gmail.com> References: <1525616369-8843-1-git-send-email-akinobu.mita@gmail.com> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The ov772x driver uses "rstb-gpios" and "pwdn-gpios" for reset and powerdown pins. However, using generic names for these gpios is preferred. ("reset-gpios" and "powerdown-gpios" respectively) There is only one mainline user for these gpios, so rename to generic names. Cc: Jacopo Mondi Cc: Laurent Pinchart Cc: Hans Verkuil Cc: Sakari Ailus Cc: Mauro Carvalho Chehab Reviewed-by: Jacopo Mondi Signed-off-by: Akinobu Mita --- * v5 - No changes arch/sh/boards/mach-migor/setup.c | 5 +++-- drivers/media/i2c/ov772x.c | 8 ++++---- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/arch/sh/boards/mach-migor/setup.c b/arch/sh/boards/mach-migor/setup.c index 271dfc2..73b9ee4 100644 --- a/arch/sh/boards/mach-migor/setup.c +++ b/arch/sh/boards/mach-migor/setup.c @@ -351,8 +351,9 @@ static struct platform_device migor_ceu_device = { static struct gpiod_lookup_table ov7725_gpios = { .dev_id = "0-0021", .table = { - GPIO_LOOKUP("sh7722_pfc", GPIO_PTT0, "pwdn", GPIO_ACTIVE_HIGH), - GPIO_LOOKUP("sh7722_pfc", GPIO_PTT3, "rstb", GPIO_ACTIVE_LOW), + GPIO_LOOKUP("sh7722_pfc", GPIO_PTT0, "powerdown", + GPIO_ACTIVE_HIGH), + GPIO_LOOKUP("sh7722_pfc", GPIO_PTT3, "reset", GPIO_ACTIVE_LOW), }, }; diff --git a/drivers/media/i2c/ov772x.c b/drivers/media/i2c/ov772x.c index bb5327f..97a65ce 100644 --- a/drivers/media/i2c/ov772x.c +++ b/drivers/media/i2c/ov772x.c @@ -837,10 +837,10 @@ static int ov772x_power_on(struct ov772x_priv *priv) * available to handle this cleanly, request the GPIO temporarily * to avoid conflicts. */ - priv->rstb_gpio = gpiod_get_optional(&client->dev, "rstb", + priv->rstb_gpio = gpiod_get_optional(&client->dev, "reset", GPIOD_OUT_LOW); if (IS_ERR(priv->rstb_gpio)) { - dev_info(&client->dev, "Unable to get GPIO \"rstb\""); + dev_info(&client->dev, "Unable to get GPIO \"reset\""); return PTR_ERR(priv->rstb_gpio); } @@ -1307,10 +1307,10 @@ static int ov772x_probe(struct i2c_client *client, goto error_ctrl_free; } - priv->pwdn_gpio = gpiod_get_optional(&client->dev, "pwdn", + priv->pwdn_gpio = gpiod_get_optional(&client->dev, "powerdown", GPIOD_OUT_LOW); if (IS_ERR(priv->pwdn_gpio)) { - dev_info(&client->dev, "Unable to get GPIO \"pwdn\""); + dev_info(&client->dev, "Unable to get GPIO \"powerdown\""); ret = PTR_ERR(priv->pwdn_gpio); goto error_clk_put; }