Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp276754imu; Fri, 25 Jan 2019 02:04:42 -0800 (PST) X-Google-Smtp-Source: ALg8bN5SJU6osQpxQvtbe/Q6J604nAFHi1ejdA5VDcS+Jc6gC3nvVKrHL9B9R9tJ6wMuqGi+3ih7 X-Received: by 2002:a17:902:24a2:: with SMTP id w31mr10128039pla.216.1548410682666; Fri, 25 Jan 2019 02:04:42 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1548410682; cv=pass; d=google.com; s=arc-20160816; b=KNzMF+pV7RjcZkugswK+kv6dS7jz3EpNwRwYG4DBACmsnNCyxSTcGaeM06FMqgJRTS OTpi9yHwPV6q0/aQIThtxDs5HQLNGRDNnz6B6rZTCLwNvVQKGXIxQwSYRqxam0Iz9ECS 1eUP9aANvTrQhuilkapwPrk3NQyxDo9rkewAfys0sC8856It7cTS/E5fh3tO0kNwvjcW AJW7wP0hx9KJ6xDDQchB8f0sF3CWnM3FzfjzcggBPCgaA2fBGEUZoj1dWyh6Jq4B+uUi YqIusRrkrLlzqHnMfNCU343/ZX7DaCSePcyFXK14kf21Tn4WMeZswaUS74x4nKHWixZB eHtw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:domainkey-signature; bh=zOerpnsi7emxJLbwvkp7Bj1xH8BVCLKx7diIq24Rrgk=; b=eKhNOp8PW30jDrYWc+XdmNm3wvBbY7yYEqKbvKqKIV0ErwqmPWAK1lTWiOgkh9jtAR IFGp6oM3YxUA7RYou2ME7+p3BVjTasAVC9YF3BiK01OA6BynerLtH04fY5uXXFbTcUgv NVVOzIhel3BXsPsATyCH2cuwHbcc03UAIxGOsGKu9yzDUD9gwUOvr/+LoFfVRkWBmUXB TCeU4CsQ6MdHby7/TgPXy/c9Vj4GZKfIcCHMxvvdV7GU9b47pm+2snPypysJrSY8rOow vsCWFSviVWNTOE1CPQ6q+Qi2v6y2/JjYy0lRfSHMZLJN6XGQYIE21ilLbDnPqdX1vtVj 9REw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@zoho.com header.s=default header.b=WcXGHe8M; arc=pass (i=1 spf=pass spfdomain=zoho.com dkim=pass dkdomain=zoho.com dmarc=pass fromdomain=zoho.com>); spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=zoho.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u7si23656011pgg.357.2019.01.25.02.04.26; Fri, 25 Jan 2019 02:04:42 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@zoho.com header.s=default header.b=WcXGHe8M; arc=pass (i=1 spf=pass spfdomain=zoho.com dkim=pass dkdomain=zoho.com dmarc=pass fromdomain=zoho.com>); spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=zoho.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729302AbfAYKCR (ORCPT + 99 others); Fri, 25 Jan 2019 05:02:17 -0500 Received: from sender-pp-092.zoho.com ([135.84.80.237]:25357 "EHLO sender-pp-092.zoho.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726926AbfAYKCQ (ORCPT ); Fri, 25 Jan 2019 05:02:16 -0500 ARC-Seal: i=1; a=rsa-sha256; t=1548410484; cv=none; d=zoho.com; s=zohoarc; b=d9bPZPfVqbudfcWP4Gap9oHTms1wEgscnXwpntyrSa6islTa4Qd3ko7EO1ClWzZ7p7XQfae1KMNOTm9PRDJHUCaUk3TAX6YcH5y3P40BHTrOiQQ5rAK4Gpm/UzK+ZpLLYCxVdBJAeW8xG8qA2D3iJguT6E7GJzCWxj/GOSW/icY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1548410484; h=Cc:Date:From:In-Reply-To:Message-ID:References:Subject:To:ARC-Authentication-Results; bh=zOerpnsi7emxJLbwvkp7Bj1xH8BVCLKx7diIq24Rrgk=; b=TD9c+Ye30WXDn/sNeHeeW4iel7+hC/KFQgbxEgfOzrBe5QLcqSC314NLmtsO2Z1dUqBZj6sXgRNOdSG/biM9PMKHKaCnDHZHNf7IhZEwgoZGe5aeXkYdHj0YQFvL2FNaZNWIYt49XttXhjDtQCDLxGpCl4cddOJsu1yVwqlQLiE= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass header.i=zoho.com; spf=pass smtp.mailfrom=zhouyanjie@zoho.com; dmarc=pass header.from= header.from= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=zapps768; d=zoho.com; h=from:to:cc:subject:date:message-id:in-reply-to:references; b=HQyhgiXgyyICFSCIc2L61LzZ9y2E95zc1Yatgq7AqKIAFEztsqJM5XdtIRfENozO2ZwNu1dJOmoz xuH8jUGi406WOprqfDLxaiXailnIPSbzgf+ZixiHnptJMLc/FPe2 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1548410484; s=default; d=zoho.com; i=zhouyanjie@zoho.com; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References; l=5745; bh=zOerpnsi7emxJLbwvkp7Bj1xH8BVCLKx7diIq24Rrgk=; b=WcXGHe8MWFqD6B/PtQZODOY0z3FUw4uBByBddS0+6kI+oqYwUtzrM+nj87KLV8gQ psQFwIe/fpZ0QWZgFIfFdFSjRXcZ/Fj/B6Yp2jxGOc6qyb7bbarfLtSjRHGf3Qo8u0b topcPKbXPrs9+42gHJXaZR3qLZ+TGCw9GW2O0SA8= Received: from localhost.localdomain (182.149.160.17 [182.149.160.17]) by mx.zohomail.com with SMTPS id 1548410482351365.5582196128695; Fri, 25 Jan 2019 02:01:22 -0800 (PST) From: Zhou Yanjie To: linus.walleij@linaro.org Cc: linux-mips@vger.kernel.org, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, paul.burton@mips.com, paul@crapouillou.net, syq@debian.org, jiaxun.yang@flygoat.com, 772753199@qq.com Subject: [PATCH RESEND 3/4] Pinctrl: Ingenic: Unify the function name prefix to "ingenic_gpio_". Date: Fri, 25 Jan 2019 17:59:52 +0800 Message-Id: <1548410393-6981-4-git-send-email-zhouyanjie@zoho.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1548410393-6981-1-git-send-email-zhouyanjie@zoho.com> References: <1548410393-6981-1-git-send-email-zhouyanjie@zoho.com> X-ZohoMailClient: External Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org In the original code, some function names begin with "ingenic_gpio_", and some with "gpio_ingenic_". For the sake of uniform style, all of them are changed to the beginning of "ingenic_gpio_". Signed-off-by: Zhou Yanjie --- drivers/pinctrl/pinctrl-ingenic.c | 46 +++++++++++++++++++-------------------- 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/drivers/pinctrl/pinctrl-ingenic.c b/drivers/pinctrl/pinctrl-ingenic.c index 6501f35..2b3f7e4 100644 --- a/drivers/pinctrl/pinctrl-ingenic.c +++ b/drivers/pinctrl/pinctrl-ingenic.c @@ -715,7 +715,7 @@ static const struct ingenic_chip_info jz4780_chip_info = { .pull_downs = jz4770_pull_downs, }; -static u32 gpio_ingenic_read_reg(struct ingenic_gpio_chip *jzgc, u8 reg) +static u32 ingenic_gpio_read_reg(struct ingenic_gpio_chip *jzgc, u8 reg) { unsigned int val; @@ -724,7 +724,7 @@ static u32 gpio_ingenic_read_reg(struct ingenic_gpio_chip *jzgc, u8 reg) return (u32) val; } -static void gpio_ingenic_set_bit(struct ingenic_gpio_chip *jzgc, +static void ingenic_gpio_set_bit(struct ingenic_gpio_chip *jzgc, u8 reg, u8 offset, bool set) { if (set) @@ -738,7 +738,7 @@ static void gpio_ingenic_set_bit(struct ingenic_gpio_chip *jzgc, static inline bool ingenic_gpio_get_value(struct ingenic_gpio_chip *jzgc, u8 offset) { - unsigned int val = gpio_ingenic_read_reg(jzgc, GPIO_PIN); + unsigned int val = ingenic_gpio_read_reg(jzgc, GPIO_PIN); return !!(val & BIT(offset)); } @@ -747,9 +747,9 @@ static void ingenic_gpio_set_value(struct ingenic_gpio_chip *jzgc, u8 offset, int value) { if (jzgc->jzpc->version >= ID_JZ4770) - gpio_ingenic_set_bit(jzgc, JZ4770_GPIO_PAT0, offset, !!value); + ingenic_gpio_set_bit(jzgc, JZ4770_GPIO_PAT0, offset, !!value); else - gpio_ingenic_set_bit(jzgc, JZ4740_GPIO_DATA, offset, !!value); + ingenic_gpio_set_bit(jzgc, JZ4740_GPIO_DATA, offset, !!value); } static void irq_set_type(struct ingenic_gpio_chip *jzgc, @@ -767,21 +767,21 @@ static void irq_set_type(struct ingenic_gpio_chip *jzgc, switch (type) { case IRQ_TYPE_EDGE_RISING: - gpio_ingenic_set_bit(jzgc, reg2, offset, true); - gpio_ingenic_set_bit(jzgc, reg1, offset, true); + ingenic_gpio_set_bit(jzgc, reg2, offset, true); + ingenic_gpio_set_bit(jzgc, reg1, offset, true); break; case IRQ_TYPE_EDGE_FALLING: - gpio_ingenic_set_bit(jzgc, reg2, offset, false); - gpio_ingenic_set_bit(jzgc, reg1, offset, true); + ingenic_gpio_set_bit(jzgc, reg2, offset, false); + ingenic_gpio_set_bit(jzgc, reg1, offset, true); break; case IRQ_TYPE_LEVEL_HIGH: - gpio_ingenic_set_bit(jzgc, reg2, offset, true); - gpio_ingenic_set_bit(jzgc, reg1, offset, false); + ingenic_gpio_set_bit(jzgc, reg2, offset, true); + ingenic_gpio_set_bit(jzgc, reg1, offset, false); break; case IRQ_TYPE_LEVEL_LOW: default: - gpio_ingenic_set_bit(jzgc, reg2, offset, false); - gpio_ingenic_set_bit(jzgc, reg1, offset, false); + ingenic_gpio_set_bit(jzgc, reg2, offset, false); + ingenic_gpio_set_bit(jzgc, reg1, offset, false); break; } } @@ -791,7 +791,7 @@ static void ingenic_gpio_irq_mask(struct irq_data *irqd) struct gpio_chip *gc = irq_data_get_irq_chip_data(irqd); struct ingenic_gpio_chip *jzgc = gpiochip_get_data(gc); - gpio_ingenic_set_bit(jzgc, GPIO_MSK, irqd->hwirq, true); + ingenic_gpio_set_bit(jzgc, GPIO_MSK, irqd->hwirq, true); } static void ingenic_gpio_irq_unmask(struct irq_data *irqd) @@ -799,7 +799,7 @@ static void ingenic_gpio_irq_unmask(struct irq_data *irqd) struct gpio_chip *gc = irq_data_get_irq_chip_data(irqd); struct ingenic_gpio_chip *jzgc = gpiochip_get_data(gc); - gpio_ingenic_set_bit(jzgc, GPIO_MSK, irqd->hwirq, false); + ingenic_gpio_set_bit(jzgc, GPIO_MSK, irqd->hwirq, false); } static void ingenic_gpio_irq_enable(struct irq_data *irqd) @@ -809,9 +809,9 @@ static void ingenic_gpio_irq_enable(struct irq_data *irqd) int irq = irqd->hwirq; if (jzgc->jzpc->version >= ID_JZ4770) - gpio_ingenic_set_bit(jzgc, JZ4770_GPIO_INT, irq, true); + ingenic_gpio_set_bit(jzgc, JZ4770_GPIO_INT, irq, true); else - gpio_ingenic_set_bit(jzgc, JZ4740_GPIO_SELECT, irq, true); + ingenic_gpio_set_bit(jzgc, JZ4740_GPIO_SELECT, irq, true); ingenic_gpio_irq_unmask(irqd); } @@ -825,9 +825,9 @@ static void ingenic_gpio_irq_disable(struct irq_data *irqd) ingenic_gpio_irq_mask(irqd); if (jzgc->jzpc->version >= ID_JZ4770) - gpio_ingenic_set_bit(jzgc, JZ4770_GPIO_INT, irq, false); + ingenic_gpio_set_bit(jzgc, JZ4770_GPIO_INT, irq, false); else - gpio_ingenic_set_bit(jzgc, JZ4740_GPIO_SELECT, irq, false); + ingenic_gpio_set_bit(jzgc, JZ4740_GPIO_SELECT, irq, false); } static void ingenic_gpio_irq_ack(struct irq_data *irqd) @@ -850,9 +850,9 @@ static void ingenic_gpio_irq_ack(struct irq_data *irqd) } if (jzgc->jzpc->version >= ID_JZ4770) - gpio_ingenic_set_bit(jzgc, JZ4770_GPIO_FLAG, irq, false); + ingenic_gpio_set_bit(jzgc, JZ4770_GPIO_FLAG, irq, false); else - gpio_ingenic_set_bit(jzgc, JZ4740_GPIO_DATA, irq, true); + ingenic_gpio_set_bit(jzgc, JZ4740_GPIO_DATA, irq, true); } static int ingenic_gpio_irq_set_type(struct irq_data *irqd, unsigned int type) @@ -907,9 +907,9 @@ static void ingenic_gpio_irq_handler(struct irq_desc *desc) chained_irq_enter(irq_chip, desc); if (jzgc->jzpc->version >= ID_JZ4770) - flag = gpio_ingenic_read_reg(jzgc, JZ4770_GPIO_FLAG); + flag = ingenic_gpio_read_reg(jzgc, JZ4770_GPIO_FLAG); else - flag = gpio_ingenic_read_reg(jzgc, JZ4740_GPIO_FLAG); + flag = ingenic_gpio_read_reg(jzgc, JZ4740_GPIO_FLAG); for_each_set_bit(i, &flag, 32) generic_handle_irq(irq_linear_revmap(gc->irq.domain, i)); -- 2.7.4