From patchwork Thu Jul 22 03:39:29 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Leizhen \(ThunderTown\)" X-Patchwork-Id: 483860 Delivered-To: patch@linaro.org Received: by 2002:a02:c94a:0:0:0:0:0 with SMTP id u10csp6791124jao; Wed, 21 Jul 2021 20:40:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwjsHQR9XD48Y1BAKkdLxQECk7LFNXtM8qdfQx1WvoIuOLv1srNfdeww2DRWuS0rPHlXZpW X-Received: by 2002:a17:906:e97:: with SMTP id p23mr42458516ejf.287.1626925256385; Wed, 21 Jul 2021 20:40:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626925256; cv=none; d=google.com; s=arc-20160816; b=KphYz18muRhaWs80hZ1kkyYZC9fNss3maq/3tMfcgY+kp5Wgy8lc5ziuOKAGbFSbpV Ej0b7Xr/NdT9SZh87VWavhpYXO4cehnhXXOEbGDH0TIBMzvsLXdzoWn7Tns7BqlIkNxh WJiidEGQ4Hd0XV2wni2fgnuJVw05NW7yJhEz3CK4rCS9M6MN0YhBoWowjZwuesQJKuCk oj8FXHPpjzwDMI+GD5WzK2n3SNONh85mHZlPwTCHacULjyFVxtmpwSJuJU/KokncSiQ1 3Hn/QuU2fWCQCulQQPywLdpcLadigtdk1JGQKxeupWVqZUzFbqMpsyXa8t64dDS5Jwhx kv3A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=D4R/v1oszEt1Dg4ICCwOriVeHw7krz5ie1oIAoQ0zgo=; b=nJsRtEX1CdOP/SkV+SXYdihBWqxNdTV7XnYKAuKx9dBiTxqcrez3VD83EsVwYAW8iT FxJ8XE57oJiiBl5g9oh4S/jkGhIfGSitwgfe5jf7PjTHcy9Af6xtOht8bx1ykggXNoMs aae+DNnsqnE5OnvbWJWqogdWb7QQV5qrBmkmma6mQsrkzWsA+K4/ivuE6lxdPfnnxFr+ mU5vs3953jLNtx6QSqJbgNhIFCErtJUzF9yjBKdgHVJ6Sjn8BfA95f+4vyiwCk8o74WW bJDKNAhA31fgzHjBIUIoRko81ZXX2GKa3dHnQwtXfFKWNAo5SVbZLLPwkqQvI6fhfxkd NMAQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-gpio-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w12si30733328edu.48.2021.07.21.20.40.56; Wed, 21 Jul 2021 20:40:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-gpio-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-gpio-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229900AbhGVDAR (ORCPT + 3 others); Wed, 21 Jul 2021 23:00:17 -0400 Received: from szxga02-in.huawei.com ([45.249.212.188]:7411 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231150AbhGVDAJ (ORCPT ); Wed, 21 Jul 2021 23:00:09 -0400 Received: from dggemv704-chm.china.huawei.com (unknown [172.30.72.53]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4GVdRg4GvJz7xvF; Thu, 22 Jul 2021 11:37:03 +0800 (CST) Received: from dggpemm500006.china.huawei.com (7.185.36.236) by dggemv704-chm.china.huawei.com (10.3.19.47) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Thu, 22 Jul 2021 11:40:36 +0800 Received: from thunder-town.china.huawei.com (10.174.179.0) by dggpemm500006.china.huawei.com (7.185.36.236) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Thu, 22 Jul 2021 11:40:36 +0800 From: Zhen Lei To: Tony Lindgren , Haojian Zhuang , Linus Walleij , linux-arm-kernel , linux-omap , linux-gpio , linux-kernel CC: Zhen Lei Subject: [PATCH v2 1/2] pinctrl: single: Fix error return code in pcs_parse_bits_in_pinctrl_entry() Date: Thu, 22 Jul 2021 11:39:29 +0800 Message-ID: <20210722033930.4034-2-thunder.leizhen@huawei.com> X-Mailer: git-send-email 2.26.0.windows.1 In-Reply-To: <20210722033930.4034-1-thunder.leizhen@huawei.com> References: <20210722033930.4034-1-thunder.leizhen@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.174.179.0] X-ClientProxiedBy: dggems702-chm.china.huawei.com (10.3.19.179) To dggpemm500006.china.huawei.com (7.185.36.236) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org Fix to return -ENOTSUPP instead of 0 when PCS_HAS_PINCONF is true, which is the same as that returned in pcs_parse_pinconf(). Fixes: 4e7e8017a80e ("pinctrl: pinctrl-single: enhance to configure multiple pins of different modules") Reported-by: Hulk Robot Signed-off-by: Zhen Lei --- drivers/pinctrl/pinctrl-single.c | 1 + 1 file changed, 1 insertion(+) -- 2.25.1 diff --git a/drivers/pinctrl/pinctrl-single.c b/drivers/pinctrl/pinctrl-single.c index e3aa64798f7d..4fcae8458359 100644 --- a/drivers/pinctrl/pinctrl-single.c +++ b/drivers/pinctrl/pinctrl-single.c @@ -1224,6 +1224,7 @@ static int pcs_parse_bits_in_pinctrl_entry(struct pcs_device *pcs, if (PCS_HAS_PINCONF) { dev_err(pcs->dev, "pinconf not supported\n"); + res = -ENOTSUPP; goto free_pingroups; }