From patchwork Sun Apr 29 17:13:05 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Akinobu Mita X-Patchwork-Id: 10370613 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 53DD360384 for ; Sun, 29 Apr 2018 17:13:58 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 420A928A18 for ; Sun, 29 Apr 2018 17:13:58 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 35CA128A21; Sun, 29 Apr 2018 17:13:58 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI 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 C6CE528A18 for ; Sun, 29 Apr 2018 17:13:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754007AbeD2RNx (ORCPT ); Sun, 29 Apr 2018 13:13:53 -0400 Received: from mail-pg0-f67.google.com ([74.125.83.67]:32890 "EHLO mail-pg0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753989AbeD2RNu (ORCPT ); Sun, 29 Apr 2018 13:13:50 -0400 Received: by mail-pg0-f67.google.com with SMTP id i194-v6so4808980pgd.0; Sun, 29 Apr 2018 10:13:50 -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=CVAKPmQec39p3uh/4JByYaAw9g51rBYwDavrbK7zlJk=; b=R2z0m5Vv4xe4o3QQCDzifmijJk1sNVooscitqOA7U0DxQIVogjv3SZw5PLepf04iKl l3KbD76Z3WChf2tNxz5LMKlTxd9hEWx7bHnt3sIm9tbjBujMNXIEC8HzzurMwGm3wKmH SnKIXqr0Ho3SWDJOX5NEJ3NfqKBRoQONjgalQ+HMpwdqYxvy2M70/c8E9QfWdfZFIci7 mgtM+PkhbcVDND95B17QFyGxxCBN/RrElZAR5IqsqKJFWZ94OCGKkX8f9Ho3uA1STzdS uyHGeZ7d4nXfygOw5DPjlNQ8d+534ETq1n4F130JW4HbxtyNB63wqjLBA89iXd8mBJVx HLYw== 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=CVAKPmQec39p3uh/4JByYaAw9g51rBYwDavrbK7zlJk=; b=HbLLCSQAc2PdFxwVaAWuC3rWqCtxhxxk7ApvhNejN0KwNyESkhcBguSYLd1mFJcUAg Khoc1HyEXYAC1maVxVPKUT6q1DJA4m08WM25XyYG1xrwPDDj9vbLhrL2QQ8/Il93hcTc IwmZ8kuxmeQxa1LUw4dSL4kSi5Eq9yyBj+D4TXpUE+G3kJRTgmO88hlvr6DOWG3gt7GW AeEzdax/0+6rjFpRP2v1cADpWqqFGMz2IcmICDLgZjVPvio8s1KJsghBo78D4bEaVCun iJv5aksTFs6h97X49ZCvyqYzIuzgkZLywlGhm78xLTWZzzGS8FLxPwnmnxFIfLdS6nEd pyxg== X-Gm-Message-State: ALQs6tAkzuIxhlg4gO2jYylSvhaLcrEWNbQ4VRW/6GuovAbhPppOf6E1 25jXPCuCCR5662DBOlu9QM7iLA== X-Google-Smtp-Source: AB8JxZqlJ71DKCrWn17IueE8q1QNlB0bZ76mRkshRT/5PrRjxmYbQn9euj4ORa0X13+RAz/7ZXe9QA== X-Received: by 2002:a17:902:8a:: with SMTP id a10-v6mr9598427pla.89.1525022029959; Sun, 29 Apr 2018 10:13:49 -0700 (PDT) Received: from localhost.localdomain ([240f:4:c2bc:1:754e:5a21:c35f:52a1]) by smtp.gmail.com with ESMTPSA id e10sm10168022pfn.67.2018.04.29.10.13.47 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 29 Apr 2018 10:13:49 -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 v4 06/14] media: ov772x: use generic names for reset and powerdown gpios Date: Mon, 30 Apr 2018 02:13:05 +0900 Message-Id: <1525021993-17789-7-git-send-email-akinobu.mita@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1525021993-17789-1-git-send-email-akinobu.mita@gmail.com> References: <1525021993-17789-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 --- * v4 - 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; }