From patchwork Tue Apr 9 07:07:14 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 161963 Delivered-To: patch@linaro.org Received: by 2002:a02:c6d8:0:0:0:0:0 with SMTP id r24csp4607618jan; Tue, 9 Apr 2019 00:07:21 -0700 (PDT) X-Google-Smtp-Source: APXvYqxRW0SFJlMnPhwnLULHl5j5m8lCwo6nVBTmuop52+XUAvZVrGcrzdwykyrtFHFrripxjRQX X-Received: by 2002:a17:902:781:: with SMTP id 1mr34718434plj.300.1554793641269; Tue, 09 Apr 2019 00:07:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554793641; cv=none; d=google.com; s=arc-20160816; b=Nfd/JchlaQgdYrWoBpove6fZGpf/N/OAQQNg132jq9naRxtpo1HUoPnxtl3A7Pt9Ls Ilj9E2mikdhT+l2L1v420LAoXjBo+HdlaJQGzsfMeJv4BzriLzo5hcaO2WWlvr1e8MP+ 4AvJt+YG2VGXb2w+fPVo3ekOi9G/dvnXoGGl1H/57CVk2ES9u8d7iiwZuvYYGzaiTuPm YnR01ktDh7QPEDdBR5QIJEIYMc1vP2xq76Rqkaamrm9zx4i2G4cYjDfpEvsXx8nbEMwY FWb7nybXkYdZZruETNsNAS//gC6IZ7VPoft8LkYW8mN+gvpP6byI03uoq0pbQ9rOnMd7 +ydg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=0keM1F/MC7QTgfcef75dXLHoeoSet9qtnuM/MkGfPPs=; b=TLTu4ZzPxVWy6pgcQO6dyzoV7t/G7T828TTXht7Iu7QExS7VnCkQcW6JbtQQKoSGZE 3uF3Hh5fSwVTXg9mew5SzKuVCjeGPBrjWk4aW6y/C9ESOqnVYFOVxT9bFqs3ckMaCDCc 14t07yTwvc5XjWIvIcYMScXrL7NbOfT1ZmZUjDYj5m0fEEc1XX//U0AJw92iatEdytRk srRoFBIHx1J9Qa5ZwOqSUgN5SDx6rEaMxVMDYuamVD1wIJMegY5cy+ng/aHNAoTTezOp luM8WbITmeRjv/Vv6UyreYCapnTdLcAZeSiZUzDSIm0QdEU+XpKkc2EHjHXGIuosZGdL K+pA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Lq2z3l9n; spf=pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m7si2749892pgb.374.2019.04.09.00.07.21; Tue, 09 Apr 2019 00:07:21 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-gpio-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=@linaro.org header.s=google header.b=Lq2z3l9n; spf=pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726352AbfDIHHU (ORCPT + 5 others); Tue, 9 Apr 2019 03:07:20 -0400 Received: from mail-lf1-f65.google.com ([209.85.167.65]:33156 "EHLO mail-lf1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726062AbfDIHHU (ORCPT ); Tue, 9 Apr 2019 03:07:20 -0400 Received: by mail-lf1-f65.google.com with SMTP id v14so11494984lfi.0 for ; Tue, 09 Apr 2019 00:07:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=0keM1F/MC7QTgfcef75dXLHoeoSet9qtnuM/MkGfPPs=; b=Lq2z3l9ncKep0sgcg6PnqT1FQDa9wmINF89m1txrXWG5x2+lvT40ceMU209ojL/5GZ G+1Ni5fPyEC7rDlbaX2inrdnqzSgl8vbCUPRMKd36NURjRzoRvsLwEAu+AXXk2bATTFn c+viLJ51pFXorAs1K5x1h+UFlwx4JiThlqOcZug2CHJoY/JAZ0FKLKD1BTWf3fdpCtYV qpL/MwQB5YvPj9aDoa+VTDC+zSh4gnY8eHLwlEOV2vjLPVfAY+46zi6M75ttAytRKybZ gKeefE10OPE8AiGlFM7VSqFL17b68bKu9GJLCdYX8nDIEQ4SyeaeUT9aRlf2Jg/09kHw jsFw== 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:mime-version :content-transfer-encoding; bh=0keM1F/MC7QTgfcef75dXLHoeoSet9qtnuM/MkGfPPs=; b=GLJ/rI//zKLHcHDfK8rhJ/SLpEM1/0cIcfAjY22IqVUsOPwvD1JNejCmZwUsGHW7TX HH5mDpwlhDtJI8vg9irXtZ2I1Y3YVCGhJO/VtzvmRReexAOxWaMfmeNKRvQdpgA1hC2d 8Fm1AlAgi/YtG/hIUwpMpo6Bv6uYqqP3quyLZSSK8+UOV3Wg0HCFEiA7VHD4f96NwVe1 Ha9OI2ualr6ETJtl6sPoll0DpsXd2D0RKX5MDsiJYezpSP0+7FcCcI6EajVX6qsZj+8L m2SziNdesm5eqvIBmqTy/ICFoYaaq+8eiuTtYx7vq0hTNFvJ0IGe2mP3Jxi9CbphMixw qkOw== X-Gm-Message-State: APjAAAWaq8ZCj7BX0ZhDLmoKYKHB941hpqdwOlGNybBo/AfxEyjfMBz3 srMTfm2mT/XfqEcW63Hd7DOw0fYK0dw= X-Received: by 2002:ac2:51a1:: with SMTP id f1mr17796090lfk.25.1554793637988; Tue, 09 Apr 2019 00:07:17 -0700 (PDT) Received: from genomnajs.ideon.se ([85.235.10.227]) by smtp.gmail.com with ESMTPSA id e3sm6383834lfn.80.2019.04.09.00.07.16 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 09 Apr 2019 00:07:16 -0700 (PDT) From: Linus Walleij To: linux-gpio@vger.kernel.org Cc: Linus Walleij , Nathan Chancellor , YueHaibing , Jesper Nilsson Subject: [PATCH] pinctrl: artpec6: Drop unused function and rename Date: Tue, 9 Apr 2019 09:07:14 +0200 Message-Id: <20190409070714.8164-1-linus.walleij@linaro.org> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Sender: linux-gpio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org The pincontrol callbacks used to be symmetric: enable/disable. However for a while we only have one function that set the muxing, no disabling. Drop the unused disable function, and rename the *enable() function to *set(). Reported-by: Nathan Chancellor Cc: YueHaibing Cc: Jesper Nilsson Signed-off-by: Linus Walleij --- drivers/pinctrl/pinctrl-artpec6.c | 21 ++++----------------- 1 file changed, 4 insertions(+), 17 deletions(-) -- 2.20.1 Reviewed-by: Nathan Chancellor Acked-by: Jesper Nilsson diff --git a/drivers/pinctrl/pinctrl-artpec6.c b/drivers/pinctrl/pinctrl-artpec6.c index e836850bd268..e3239cf926f9 100644 --- a/drivers/pinctrl/pinctrl-artpec6.c +++ b/drivers/pinctrl/pinctrl-artpec6.c @@ -688,9 +688,9 @@ static void artpec6_pmx_select_func(struct pinctrl_dev *pctldev, } } -static int artpec6_pmx_enable(struct pinctrl_dev *pctldev, - unsigned int function, - unsigned int group) +static int artpec6_pmx_set(struct pinctrl_dev *pctldev, + unsigned int function, + unsigned int group) { struct artpec6_pmx *pmx = pinctrl_dev_get_drvdata(pctldev); @@ -703,19 +703,6 @@ static int artpec6_pmx_enable(struct pinctrl_dev *pctldev, return 0; } -static void artpec6_pmx_disable(struct pinctrl_dev *pctldev, - unsigned int function, - unsigned int group) -{ - struct artpec6_pmx *pmx = pinctrl_dev_get_drvdata(pctldev); - - dev_dbg(pmx->dev, "disabling %s function for pin group %s\n", - artpec6_pmx_get_fname(pctldev, function), - artpec6_get_group_name(pctldev, group)); - - artpec6_pmx_select_func(pctldev, function, group, false); -} - static int artpec6_pmx_request_gpio(struct pinctrl_dev *pctldev, struct pinctrl_gpio_range *range, unsigned int pin) @@ -739,7 +726,7 @@ static const struct pinmux_ops artpec6_pmx_ops = { .get_functions_count = artpec6_pmx_get_functions_count, .get_function_name = artpec6_pmx_get_fname, .get_function_groups = artpec6_pmx_get_fgroups, - .set_mux = artpec6_pmx_enable, + .set_mux = artpec6_pmx_set, .gpio_request_enable = artpec6_pmx_request_gpio, };