From patchwork Mon Oct 2 02:15:59 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AKASHI Takahiro X-Patchwork-Id: 13405501 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 51B1DE784A7 for ; Mon, 2 Oct 2023 02:17:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=SfLM1O4xqv1mTUTSOFseUcY2WPelxH3iN0JilwwbJg4=; b=p3p8nq7xRer2mf OxMreqzktxuzC/8chYQnJ1FCESuSEXGvEbzNtYbhi11bY3LZ+xpNIuOV+Ra0Rsu/e9HWrVFatLN0r x1VJtB8IMMzHPSqELQGBC0uK7sly7b5gY+4gsa52YPv23fbL0jpiyaDSiXri88dzye0pRMRlF9h0K kuVVkN6O2xGrAIAX2uZaWgFmUryRyr56nwWXFrFSzWwRjsH3vLDA0B7NkgkOQBIHOPYZXjQbkf9B1 I9ptqWAAJ6vCA92dtxqSuqbf2Y3E7EMOK8fGyPmBMAZWDoqNDQgyS3KSXDoAuc3hYCHvnKdvnWXdI Gdrsqk4Mmkc05FEg+E8g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qn8Uu-00BqLA-2G; Mon, 02 Oct 2023 02:17:24 +0000 Received: from mail-pj1-x1035.google.com ([2607:f8b0:4864:20::1035]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qn8Ur-00BqK8-1H for linux-arm-kernel@lists.infradead.org; Mon, 02 Oct 2023 02:17:22 +0000 Received: by mail-pj1-x1035.google.com with SMTP id 98e67ed59e1d1-2739c8862d2so3432170a91.1 for ; Sun, 01 Oct 2023 19:17:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1696213040; x=1696817840; darn=lists.infradead.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=OqXtc+pvir/IxuRnJD6IqOJ/WGP90gqy5QBVu45Fdzc=; b=R0353sGaZShYD+B3Vg4zhRvQQllQuDxKHl9dN6QC0tE+2PzXIqLTR6M29VqpZZuBtB zf5eS1ZGG64YEaFBKIx3wjw+eX8Q6Zwgaifz1snusx3i4cjRRxSoxs9gjP4LhgkikyhT 9LsAgxF6Np2uZQ+CqOlbyBd36QLPARC8CAU8JXD72N54DN7oYJ8rjBkxIUtPLjJLAGa+ Wy0q9H05SEcLDWCT0Dssb1AlsY9WvbJZHEdwSvovFVvelJsxEQ1GrkUCRENGnGwc+H71 PTODWRJEP4Sws3RtA/40oZ2p9gu69PTCmuFa4sz3zV0Mk0GXlOxVlPHPXO2MTPeruK5R UmBQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696213040; x=1696817840; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=OqXtc+pvir/IxuRnJD6IqOJ/WGP90gqy5QBVu45Fdzc=; b=XI6VDcTkfBb10LjCgRJJYHvx9okizjG4tAu1nB9cfJN2vPAyuy8LZuDcsBW9Dbv3Pt fhpkLyfKYQT9P08a/jiFR9beYUTDJB99WW3qN9amzD5tlQCeH1wphHLXPNe0oJKQvyAV FZvgknRGODGB1jlF8zrBuT7aV9Y1jGBfHHP+kXT0XT7V0xSHzM92X3edE5QASrFowZMQ oKbAVK+PYAjJRtI95zS5rj5idSXvjkX04/SwLoLJNjiKakD00NtIVuXQAtuTy7V0p1n/ 6lYpmIhFpwfVcoDR3ZGI5JKzlz6q3qKivB+H+PfniyUG+JELNKM7NFambGQNz85Rdyql Dzqw== X-Gm-Message-State: AOJu0YwrXOZKehmNEGB60M9pEnt8odi5/bvoNdx4eStfnJA22V+TyCKp 3dpgAAmh1VDizgRK0T3SkJVCrw== X-Google-Smtp-Source: AGHT+IEusTnW4378lO9AUwQdv9HFrR0OPNAAVojwLcl5rMvEgnFubpbvDWr1u456gCLJfr4DyaWHaA== X-Received: by 2002:a17:90a:1383:b0:274:60c7:e15a with SMTP id i3-20020a17090a138300b0027460c7e15amr9153621pja.4.1696213039746; Sun, 01 Oct 2023 19:17:19 -0700 (PDT) Received: from octopus.. ([2400:4050:c3e1:100:7ab1:199:d138:f054]) by smtp.gmail.com with ESMTPSA id mg11-20020a17090b370b00b002609cadc56esm5278319pjb.11.2023.10.01.19.17.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 01 Oct 2023 19:17:19 -0700 (PDT) From: AKASHI Takahiro To: sudeep.holla@arm.com, cristian.marussi@arm.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, linus.walleij@linaro.org Cc: Oleksii_Moisieiev@epam.com, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, AKASHI Takahiro Subject: [RFC 1/4] pinctrl: define PIN_CONFIG_INPUT Date: Mon, 2 Oct 2023 11:15:59 +0900 Message-Id: <20231002021602.260100-2-takahiro.akashi@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231002021602.260100-1-takahiro.akashi@linaro.org> References: <20231002021602.260100-1-takahiro.akashi@linaro.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231001_191721_434083_FB19F692 X-CRM114-Status: GOOD ( 11.31 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org This allows for enabling SCMI pinctrl based GPIO driver to obtain an input gpio pin. Signed-off-by: AKASHI Takahiro --- include/linux/pinctrl/pinconf-generic.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/linux/pinctrl/pinconf-generic.h b/include/linux/pinctrl/pinconf-generic.h index d74b7a4ea154..842b328ea504 100644 --- a/include/linux/pinctrl/pinconf-generic.h +++ b/include/linux/pinctrl/pinconf-generic.h @@ -67,6 +67,8 @@ struct pinctrl_map; * passed as argument. The argument is in mA. * @PIN_CONFIG_DRIVE_STRENGTH_UA: the pin will sink or source at most the current * passed as argument. The argument is in uA. + * @PIN_CONFIG_INPUT: This will obtain a value on an input pin. The returned + * argument indicates the value. * @PIN_CONFIG_INPUT_DEBOUNCE: this will configure the pin to debounce mode, * which means it will wait for signals to settle when reading inputs. The * argument gives the debounce time in usecs. Setting the @@ -128,6 +130,7 @@ enum pin_config_param { PIN_CONFIG_DRIVE_PUSH_PULL, PIN_CONFIG_DRIVE_STRENGTH, PIN_CONFIG_DRIVE_STRENGTH_UA, + PIN_CONFIG_INPUT, PIN_CONFIG_INPUT_DEBOUNCE, PIN_CONFIG_INPUT_ENABLE, PIN_CONFIG_INPUT_SCHMITT,