From patchwork Wed Mar 4 10:41:56 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stanimir Varbanov X-Patchwork-Id: 446186 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 8D4EB14012C for ; Wed, 4 Mar 2015 21:42:58 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933627AbbCDKmM (ORCPT ); Wed, 4 Mar 2015 05:42:12 -0500 Received: from ns.mm-sol.com ([37.157.136.199]:34289 "EHLO extserv.mm-sol.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933341AbbCDKmI (ORCPT ); Wed, 4 Mar 2015 05:42:08 -0500 Received: from localhost.localdomain (unknown [37.157.136.206]) by extserv.mm-sol.com (Postfix) with ESMTPSA id CC01FC8A3; Wed, 4 Mar 2015 12:42:06 +0200 (EET) From: Stanimir Varbanov To: Linus Walleij Cc: linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, Bjorn Andersson , Stephen Boyd Subject: [PATCH v2 1/2] pinctrl: qcom: enable generic pinconf Date: Wed, 4 Mar 2015 12:41:56 +0200 Message-Id: <1425465717-27747-2-git-send-email-svarbanov@mm-sol.com> X-Mailer: git-send-email 1.7.0.4 In-Reply-To: <1425465717-27747-1-git-send-email-svarbanov@mm-sol.com> References: <1425465717-27747-1-git-send-email-svarbanov@mm-sol.com> Sender: linux-gpio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org This makes the pinctrl driver to use the generic pinconf interface. Mainly it gives us a way to use debugfs to dump group configurations. Signed-off-by: Stanimir Varbanov Reviewed-by: Linus Walleij Acked-by: Bjorn Andersson Reviewed-by: Stephen Boyd --- drivers/pinctrl/qcom/pinctrl-msm.c | 6 ++---- 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/pinctrl/qcom/pinctrl-msm.c b/drivers/pinctrl/qcom/pinctrl-msm.c index a535f9c..d36e511 100644 --- a/drivers/pinctrl/qcom/pinctrl-msm.c +++ b/drivers/pinctrl/qcom/pinctrl-msm.c @@ -197,7 +197,6 @@ static int msm_config_reg(struct msm_pinctrl *pctrl, *mask = 1; break; default: - dev_err(pctrl->dev, "Invalid config param %04x\n", param); return -ENOTSUPP; } @@ -262,9 +261,7 @@ static int msm_config_group_get(struct pinctrl_dev *pctldev, arg = !!(val & BIT(g->in_bit)); break; default: - dev_err(pctrl->dev, "Unsupported config parameter: %x\n", - param); - return -EINVAL; + return -ENOTSUPP; } *config = pinconf_to_config_packed(param, arg); @@ -357,6 +354,7 @@ static int msm_config_group_set(struct pinctrl_dev *pctldev, } static const struct pinconf_ops msm_pinconf_ops = { + .is_generic = true, .pin_config_group_get = msm_config_group_get, .pin_config_group_set = msm_config_group_set, };