From patchwork Mon Dec 28 09:04:25 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hsin-Yi Wang X-Patchwork-Id: 11990973 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.9 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 84715C433E0 for ; Mon, 28 Dec 2020 09:07:09 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 32E3220781 for ; Mon, 28 Dec 2020 09:07:09 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 32E3220781 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:To:From: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=eg67o6CHHDuzZaXHltNn0VqkXv2EH0Urte0O25SqXhM=; b=a2JsQn1W4o6wGgnwkUehcIzLnG VbXu6bkdsd7qMoWniZOyHSpDSvQLaFFTDLR/pyeZhV4O5bRGP0DClF/94GC6m8s42jBedezSEj5+7 rnrG0/FkAhox3hrjoY7i8YOODQYOz5ct611OFXlw5qMIih50IcOu895pneFAs4OrwesPP3xyhtrY/ tSimBvNNpgYDcdEVVSRxbPY2YwKopwA1o4SqEb7Jiek0iiWw6dXZJNMqKvnNbQTHbouq5SK9CIHf6 dZLRLXltUs2ubLbkeSncG8qNGJy5nilt4Bh88pYEBV7dwqofQbDmvvGkc/TlUMj6CN70Z3AhpBAKE U8vYEQcA==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1ktoSD-0005kR-5A; Mon, 28 Dec 2020 09:04:37 +0000 Received: from mail-pg1-x531.google.com ([2607:f8b0:4864:20::531]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1ktoSA-0005jY-L3 for linux-arm-kernel@lists.infradead.org; Mon, 28 Dec 2020 09:04:35 +0000 Received: by mail-pg1-x531.google.com with SMTP id n7so7011399pgg.2 for ; Mon, 28 Dec 2020 01:04:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=X4pAM+KZPcorEeEY52d8nlRr19UO6jcGAcFxkVXndac=; b=Q0q/Ga+Nxl+3FRZgGiLxoEgOGgwiSNoS3EbH3cbyl+E0gQ7GJLAkpv/ZNUp2DuRnZh c7JaTDTi6Jcrtdo5bby8PAXpJsATseq5v3CWrgtaVJNHH8vi4G/xtXPWxXhyjRWONizp 6rFkdMqbF9G8k+I0VvApIg/HinLERWVH9zkTs= 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=X4pAM+KZPcorEeEY52d8nlRr19UO6jcGAcFxkVXndac=; b=WBkaN5De3yPvcQowLy2ZWONAg+ZMHFO7fsLkmhdsBl/2UYcjKmeUIymHawmfMJQlJf 1bLq0dgHe6NhpgmSRoRWm1OXSlsaBJ8v5fbIX3MMvtVimiZsIVpwv1Y5GgUGD/+3eVkZ J5ApTLzsXUGWjNUBKmI+YWeHJNPdkr8n2dm9AOUKuOMlWEqMUqRxGy8xOrErMSk0pJXI pHGXlXhFZJmWdyN2BVJucmaLu42Be3uLGroMAxpzpv47N0e6XexwZJP2JrlHMuCZg4hA /m2mA9EjvIzxpHCQ6HvdvVvdYQOCDQq/Xfu2dYBivdCJEurmCj3hqZEDjPE1HsWzJ5bq RxXQ== X-Gm-Message-State: AOAM531g9/CFh5Lj03JpBZCfTROL6aDGku3dVJxasyu7ke9FqEUHwvpn mUnrHnzDMAvejcpBxm57WTWrTGY4CtIyIA== X-Google-Smtp-Source: ABdhPJxt6FqRzO1S7YUjyHUwrV8TLbMVa6hCRDhCOqzEtTJ899Q8c45+FCd78FI7imT744QJSdl6hQ== X-Received: by 2002:a63:e049:: with SMTP id n9mr42750637pgj.339.1609146270214; Mon, 28 Dec 2020 01:04:30 -0800 (PST) Received: from hsinyi-z840.tpe.corp.google.com ([2401:fa00:1:10:1a60:24ff:fe89:3e93]) by smtp.gmail.com with ESMTPSA id h10sm31496329pfn.213.2020.12.28.01.04.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 28 Dec 2020 01:04:29 -0800 (PST) From: Hsin-Yi Wang To: linux-arm-kernel@lists.infradead.org Subject: [PATCH] pinctrl: mediatek: Fix fallback call path Date: Mon, 28 Dec 2020 17:04:25 +0800 Message-Id: <20201228090425.2130569-1-hsinyi@chromium.org> X-Mailer: git-send-email 2.29.2.729.g45daf8777d-goog MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201228_040435_012656_BFB950B7 X-CRM114-Status: GOOD ( 12.41 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Enric Balletbo i Serra , Linus Walleij , Sean Wang , linux-kernel@vger.kernel.org, Light Hsieh , linux-gpio@vger.kernel.org, linux-mediatek@lists.infradead.org, Matthias Brugger Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Some SoCs, eg. mt8183, are using a pinconfig operation bias_set_combo. The fallback path in mtk_pinconf_adv_pull_set() should also try this operation. Fixes: cafe19db7751 ("pinctrl: mediatek: Backward compatible to previous Mediatek's bias-pull usage") Signed-off-by: Hsin-Yi Wang Acked-by: Sean Wang --- drivers/pinctrl/mediatek/pinctrl-mtk-common-v2.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/pinctrl/mediatek/pinctrl-mtk-common-v2.c b/drivers/pinctrl/mediatek/pinctrl-mtk-common-v2.c index 7aeb552d16ce9..72f17f26acd80 100644 --- a/drivers/pinctrl/mediatek/pinctrl-mtk-common-v2.c +++ b/drivers/pinctrl/mediatek/pinctrl-mtk-common-v2.c @@ -920,6 +920,10 @@ int mtk_pinconf_adv_pull_set(struct mtk_pinctrl *hw, err = hw->soc->bias_set(hw, desc, pullup); if (err) return err; + } else if (hw->soc->bias_set_combo) { + err = hw->soc->bias_set_combo(hw, desc, pullup, arg); + if (err) + return err; } else { return -ENOTSUPP; }