From patchwork Wed Aug 9 19:38:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 712071 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8D23EC04FDF for ; Wed, 9 Aug 2023 19:39:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233912AbjHITjM (ORCPT ); Wed, 9 Aug 2023 15:39:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49748 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233907AbjHITjM (ORCPT ); Wed, 9 Aug 2023 15:39:12 -0400 Received: from mail-lj1-x22b.google.com (mail-lj1-x22b.google.com [IPv6:2a00:1450:4864:20::22b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7882910DC for ; Wed, 9 Aug 2023 12:39:11 -0700 (PDT) Received: by mail-lj1-x22b.google.com with SMTP id 38308e7fff4ca-2b9c66e2e36so1694781fa.1 for ; Wed, 09 Aug 2023 12:39:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691609950; x=1692214750; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=L/ZCzffNd4VjgfPfI3FvCPGEBawQZB9kqBgHWNy6ki8=; b=W6DC5u2ztKlZ6rKzWGCpk0KZHaZCvGOVzHvJ1QLxXNCV6FoYgB38PohUvaDpxZgGHw kSSjj31ZJMVDUDZVclLt8MunljCGYsTU0bAWBuX4HGRWOJQ3cPKSHuazQYwbfpMeY7Zo 0yECewWD7YzNj2bgr+c8vxEb3JT6/rKVoWgGZEYDz7XXz86hUS4s4Fg7JBJyZRh2gOXb v/9zNjd7W9ooqZsgyq13tQVFnAcMKE5BKHC/2KTLtZNM41KRCTkZyJoEQmAvCkUQBeaJ awazdnn7pETP44FxuFdzdgnihm8p9I1yLR4M/AZVHW2PkYbK5DWD9fYGCApuFi/nZHKS p09g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691609950; x=1692214750; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=L/ZCzffNd4VjgfPfI3FvCPGEBawQZB9kqBgHWNy6ki8=; b=QD99Us4JWauxJ+zY7KMV2kUAbvLeilsjOO8hZ/6MnATu3IjZqk+m62s4ymWCv394+Q WCJaK83EBSegzFFitcSBOpyP+Lw0YE5um0wAsd4XthQjJK2myvjsBISf2iLhgfTcYp1A g/L1ZWEXBlEP4D1CunWrAc0TpT1TTRg/X9HxcKq3ME/Jc+tZnFRJMmOU1LHacGW8DTmn 0PBm+isQDibODHxsF5GynLvwA3emRM812m8IQ7v0SrdV4Tq+QQ4frxQMpf33KaZeZGDd eiyvOKxSBsqubm1rZQjEjz+ThN3btfQymV/HCsd/6QnQsre3ffC33wrV1/Cu16YwnlgV uCKA== X-Gm-Message-State: AOJu0Yyc6T4JIws+hu+/ej3yUDcmJfhFqYQ3RLu3PDosZYap1dnC/u4S PpjO/eLelGYsQCtGAEcRQtuTBw== X-Google-Smtp-Source: AGHT+IEpcxHLCLy+tp5VWY2y1CLPV67l3/9e/fwvfXS7Opiz0Ua1sxmTXXkqpLnXMGnImLfGLjG9Hg== X-Received: by 2002:a05:651c:c91:b0:2b9:e705:6303 with SMTP id bz17-20020a05651c0c9100b002b9e7056303mr215972ljb.4.1691609949650; Wed, 09 Aug 2023 12:39:09 -0700 (PDT) Received: from [192.168.1.101] (abxi185.neoplus.adsl.tpnet.pl. [83.9.2.185]) by smtp.gmail.com with ESMTPSA id x6-20020a2e9c86000000b002b9fe77d00dsm2885287lji.93.2023.08.09.12.39.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Aug 2023 12:39:09 -0700 (PDT) From: Konrad Dybcio Date: Wed, 09 Aug 2023 21:38:54 +0200 Subject: [PATCH 1/5] pinctrl: qcom: msm8998: Fix MPM mappings MIME-Version: 1.0 Message-Id: <20230809-topic-mpm_mappings-v1-1-5e17dd76b3c8@linaro.org> References: <20230809-topic-mpm_mappings-v1-0-5e17dd76b3c8@linaro.org> In-Reply-To: <20230809-topic-mpm_mappings-v1-0-5e17dd76b3c8@linaro.org> To: Andy Gross , Bjorn Andersson , Linus Walleij Cc: Marijn Suijten , linux-arm-msm@vger.kernel.org, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1691609947; l=2512; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=hCfkcXPkFWRhbSb1h+V6CJXQhWHaCdAB8TPVfPD9pXM=; b=S8jiSSCI5NcJ3Fq5TU/y5Yf0Pu1Z4aSwXDxAv9ccPX9HiW/hlU9rRM/sHWbZ50t6iK10+z8r/ 4sRvLNwCrsIBOzGkAtxxfKzboXAWnNb0p8oMCEuAzwfO3d5PyEz8Ske X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org Commit 29f6e7e379fd ("pinctrl: qcom: msm8998: Add MPM pin mappings") added a map of pins <-> wakeirqs. The values in each tuple were swapped and the last one was missing. Fix that. Fixes: 29f6e7e379fd ("pinctrl: qcom: msm8998: Add MPM pin mappings") Signed-off-by: Konrad Dybcio --- drivers/pinctrl/qcom/pinctrl-msm8998.c | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/drivers/pinctrl/qcom/pinctrl-msm8998.c b/drivers/pinctrl/qcom/pinctrl-msm8998.c index b7cbf32b3125..08d6e555652a 100644 --- a/drivers/pinctrl/qcom/pinctrl-msm8998.c +++ b/drivers/pinctrl/qcom/pinctrl-msm8998.c @@ -1496,15 +1496,16 @@ static const struct msm_pingroup msm8998_groups[] = { }; static const struct msm_gpio_wakeirq_map msm8998_mpm_map[] = { - { 1, 3 }, { 5, 4 }, { 9, 5 }, { 11, 6 }, { 22, 8 }, { 24, 9 }, { 26, 10 }, - { 34, 11 }, { 36, 12 }, { 37, 13 }, { 38, 14 }, { 40, 15 }, { 42, 16 }, { 46, 17 }, - { 50, 18 }, { 53, 19 }, { 54, 20 }, { 56, 21 }, { 57, 22 }, { 58, 23 }, { 59, 24 }, - { 60, 25 }, { 61, 26 }, { 62, 27 }, { 63, 28 }, { 64, 29 }, { 66, 7 }, { 71, 30 }, - { 73, 31 }, { 77, 32 }, { 78, 33 }, { 79, 34 }, { 80, 35 }, { 82, 36 }, { 86, 37 }, - { 91, 38 }, { 92, 39 }, { 95, 40 }, { 97, 41 }, { 101, 42 }, { 104, 43 }, { 106, 44 }, - { 108, 45 }, { 110, 48 }, { 112, 46 }, { 113, 47 }, { 115, 51 }, { 116, 54 }, { 117, 55 }, - { 118, 56 }, { 119, 57 }, { 120, 58 }, { 121, 59 }, { 122, 60 }, { 123, 61 }, { 124, 62 }, - { 125, 63 }, { 126, 64 }, { 127, 50 }, { 129, 65 }, { 131, 66 }, { 132, 67 }, { 133, 68 }, + { 3, 1 }, { 4, 5 }, { 5, 9 }, { 6, 11 }, { 8, 22 }, { 9, 24 }, { 10, 26 }, + { 11, 34 }, { 12, 36 }, { 13, 37 }, { 14, 38 }, { 15, 40 }, { 16, 42 }, { 17, 46 }, + { 18, 50 }, { 19, 53 }, { 20, 54 }, { 21, 56 }, { 22, 57 }, { 23, 58 }, { 24, 59 }, + { 25, 60 }, { 26, 61 }, { 27, 62 }, { 28, 63 }, { 29, 64 }, { 7, 66 }, { 30, 71 }, + { 31, 73 }, { 32, 77 }, { 33, 78 }, { 34, 79 }, { 35, 80 }, { 36, 82 }, { 37, 86 }, + { 38, 91 }, { 39, 92 }, { 40, 95 }, { 41, 97 }, { 42, 101 }, { 43, 104 }, { 44, 106 }, + { 45, 108 }, { 48, 110 }, { 46, 112 }, { 47, 113 }, { 51, 115 }, { 54, 116 }, { 55, 117 }, + { 56, 118 }, { 57, 119 }, { 58, 120 }, { 59, 121 }, { 60, 122 }, { 61, 123 }, { 62, 124 }, + { 63, 125 }, { 64, 126 }, { 50, 127 }, { 65, 129 }, { 66, 131 }, { 67, 132 }, { 68, 133 }, + { 69, 145 }, }; static const struct msm_pinctrl_soc_data msm8998_pinctrl = { From patchwork Wed Aug 9 19:38:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 712070 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 63F14C04FDF for ; Wed, 9 Aug 2023 19:39:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233918AbjHITjU (ORCPT ); Wed, 9 Aug 2023 15:39:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49838 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233955AbjHITjS (ORCPT ); Wed, 9 Aug 2023 15:39:18 -0400 Received: from mail-lj1-x235.google.com (mail-lj1-x235.google.com [IPv6:2a00:1450:4864:20::235]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id ED51D1BD9 for ; Wed, 9 Aug 2023 12:39:14 -0700 (PDT) Received: by mail-lj1-x235.google.com with SMTP id 38308e7fff4ca-2b9a828c920so2861871fa.1 for ; Wed, 09 Aug 2023 12:39:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691609953; x=1692214753; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=scHhpJUMzh48LPTYd+vtq/rRvZwD6bIb5v4LTSQLFkQ=; b=tsbL6KN45SrtH2mGdzr+Zt/Heo9gCqN1luo5IfDxltewLZb4je6A3xZBiF70XwEWIB 5/kkAQ3lD++wgVYBMjIsjkbWiau3wnCaukyNgyI93YoEb5OJkX3muVyzabPqJMIBl+nl ub3zt+OuDoqZ75qMLvyiwmK0QAvoEDJfzh0Q1xPNlk7/W0ZbGTguua5IJPqu9oLDZbOM DUXP7LwxjxFmrq3foWNENFYd9XlOsQ8hA6Y6Y+WXWW+bWmwY9H4WGpf9oIU+7/FVdwX6 peVLhBGmy9MnaWV00tMbD2qIUg8hYLJUElPakv161O1YWsKLikJIydpNOCTq4BRS3Iu6 id8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691609953; x=1692214753; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=scHhpJUMzh48LPTYd+vtq/rRvZwD6bIb5v4LTSQLFkQ=; b=befZYI2xRap15Y2K5B0AulT8N7GwNKi197F/pWNDGnBgT6dkfK+9kQJY1xz81BgUUq GWCnQAUHEfrCbumX6KK93B0SDRkfvpPapTt4XgGsdtx0ZV78e7xKR9Mjnzavn0QroNPe fbSP6FgH2HIbWgB/cK8jhKwTmoeP7YB5ThsgdGiV4VzQiAGNJmq7b1WSaMFNCKhmW/4e X3EgIdcIQgcpdIn16icKpuYCGlbf5p/Ub+phxua+hQERFK04jpK2l9a6G3WP5TIzxRSG aM5QZpsg/OCgZ0uPyK9zlAjBXMFN2Ni7Ytw9OGqQXvjIUKk66MI6CszBwt208g66cjrV Xl8w== X-Gm-Message-State: AOJu0YzQcyu1kpj+4wny65ZvVLgX7yI6r06inekAJFPPyLGJZujZFnf7 fHT2BrdexwC2UAlZU5gra4HccA== X-Google-Smtp-Source: AGHT+IHurHBiaH7/Vjd3iZA3MCs1rWy2hTZdWA/koce8qrDiOUiwcxFFlbt1TB4xVuc1GAKw6FUt0Q== X-Received: by 2002:a2e:3109:0:b0:2b6:ef2b:da5e with SMTP id x9-20020a2e3109000000b002b6ef2bda5emr110152ljx.49.1691609953018; Wed, 09 Aug 2023 12:39:13 -0700 (PDT) Received: from [192.168.1.101] (abxi185.neoplus.adsl.tpnet.pl. [83.9.2.185]) by smtp.gmail.com with ESMTPSA id x6-20020a2e9c86000000b002b9fe77d00dsm2885287lji.93.2023.08.09.12.39.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Aug 2023 12:39:12 -0700 (PDT) From: Konrad Dybcio Date: Wed, 09 Aug 2023 21:38:57 +0200 Subject: [PATCH 4/5] pinctrl: qcom: sm6125: Add MPM pin mappings MIME-Version: 1.0 Message-Id: <20230809-topic-mpm_mappings-v1-4-5e17dd76b3c8@linaro.org> References: <20230809-topic-mpm_mappings-v1-0-5e17dd76b3c8@linaro.org> In-Reply-To: <20230809-topic-mpm_mappings-v1-0-5e17dd76b3c8@linaro.org> To: Andy Gross , Bjorn Andersson , Linus Walleij Cc: Marijn Suijten , linux-arm-msm@vger.kernel.org, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1691609947; l=1945; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=mi6tyaaFaIGRYVB8wfaRQeWL03aQpxrSwoKIZ8Ywe4k=; b=mQplNLrfdABOmb0kAk8NkBnDyjp6NS61Zp5QhFo49xa/giZvIaw/v49QXdunxFribHHeXcUiL 6MILr9GgvUHD8e6Q/vpIbFqr/HUEb4NTEVHBJdUgfkrlV3gVEXNd2E3 X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org Add pin <-> wakeirq mappings to allow for waking up the AP from sleep through MPM-connected pins. Signed-off-by: Konrad Dybcio --- drivers/pinctrl/qcom/pinctrl-sm6125.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/drivers/pinctrl/qcom/pinctrl-sm6125.c b/drivers/pinctrl/qcom/pinctrl-sm6125.c index d5e2b896954c..ea377f025d60 100644 --- a/drivers/pinctrl/qcom/pinctrl-sm6125.c +++ b/drivers/pinctrl/qcom/pinctrl-sm6125.c @@ -1221,6 +1221,18 @@ static const struct msm_pingroup sm6125_groups[] = { [140] = SDC_QDSD_PINGROUP(sdc2_data, SOUTH, 0x58b000, 9, 0), }; +static const struct msm_gpio_wakeirq_map sm6125_mpm_map[] = { + { 5, 43 }, { 6, 45 }, { 7, 59 }, { 8, 72 }, { 9, 83 }, { 13, 124 }, { 14, 1 }, { 15, 3 }, + { 16, 4 }, { 17, 9 }, { 18, 13 }, { 19, 15 }, { 20, 17 }, { 21, 19 }, { 22, 21 }, + { 23, 14 }, { 24, 25 }, { 25, 26 }, { 26, 27 }, { 27, 29 }, { 28, 33 }, { 29, 36 }, + { 30, 42 }, { 31, 44 }, { 32, 47 }, { 33, 50 }, { 34, 70 }, { 35, 75 }, { 36, 79 }, + { 37, 80 }, { 38, 81 }, { 39, 82 }, { 40, 85 }, { 41, 86 }, { 42, 88 }, { 43, 89 }, + { 44, 91 }, { 45, 92 }, { 46, 93 }, { 47, 94 }, { 48, 95 }, { 49, 96 }, { 50, 98 }, + { 51, 99 }, { 52, 101 }, { 53, 102 }, { 54, 105 }, { 55, 107 }, { 56, 110 }, { 57, 111 }, + { 58, 112 }, { 59, 118 }, { 60, 122 }, { 61, 123 }, { 62, 126 }, { 63, 128 }, { 64, 100 }, + { 65, 130 }, { 66, 131 }, { 67, 132 }, { 70, 97 }, { 71, 120 }, { 84, 22 }, +}; + static const struct msm_pinctrl_soc_data sm6125_tlmm = { .pins = sm6125_pins, .npins = ARRAY_SIZE(sm6125_pins), @@ -1231,6 +1243,8 @@ static const struct msm_pinctrl_soc_data sm6125_tlmm = { .ngpios = 134, .tiles = sm6125_tiles, .ntiles = ARRAY_SIZE(sm6125_tiles), + .wakeirq_map = sm6125_mpm_map, + .nwakeirq_map = ARRAY_SIZE(sm6125_mpm_map), }; static int sm6125_tlmm_probe(struct platform_device *pdev) From patchwork Wed Aug 9 19:38:58 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 712069 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4FF7FC04FE0 for ; Wed, 9 Aug 2023 19:39:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233924AbjHITjU (ORCPT ); Wed, 9 Aug 2023 15:39:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49806 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233989AbjHITjS (ORCPT ); Wed, 9 Aug 2023 15:39:18 -0400 Received: from mail-lf1-x129.google.com (mail-lf1-x129.google.com [IPv6:2a00:1450:4864:20::129]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 97358210B for ; Wed, 9 Aug 2023 12:39:15 -0700 (PDT) Received: by mail-lf1-x129.google.com with SMTP id 2adb3069b0e04-4fe85fd3d27so183099e87.0 for ; Wed, 09 Aug 2023 12:39:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691609954; x=1692214754; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=FaJD50ZdNlLd8aAV2rJ5UObu1uOPthET0/BzYuBazXo=; b=IWEFDVYUNwwuG8brMaU6ojkleuncxUL14b8nv5klpLv0aLDUrWPtlSnVIYDSJgiUyP Y7MkRNePGKQwpxzdknXNDCYic6inj9kTR0jjd198/VYCl1Da9nuNIoB6ikRC3FiFGSCP mwfLMKBENi2vCXVKIaVlgAWsV58rcHm0cLGXC6mOOas9Pi+ZUYK9/GuSepaF0QrW1hpu joTNjdCUUc51wBiAR8MGiW6Xu3gBSkMo5syZRqQ8JRZ76mh7eIAutbAjpCGZbDN/ckXe mSAbuCkUoynSIi8BObS2duNI97T+Iz2r/QPQq138839rsynRl/OC6Hja5Gos9v89xbUQ yGQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691609954; x=1692214754; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=FaJD50ZdNlLd8aAV2rJ5UObu1uOPthET0/BzYuBazXo=; b=cMFzEcwzktmWqkwHXJmwaaPyYHU6wdZFnASIK+lbvpmwZRqAUm3Hj5j3qsy67vVw/6 UR211v846WIeNz5YrhMBIN8/VzKJ7GepSJUvOXtU26UUFSHzjcXfWocSzL6g0Nz+Zdny KPf1ooNXu13lTItqlNdNzY6Q/GGQp5az7MrF6T8N5EF+piVDhD/VKfb0e9xBqCuhtc40 VQlojN17fniQdCcH3SKp0wMle3zHPpgB4W2diF8PAJjsNf4oo47tk+xjIrGc3+WU+nAC WXbM18HuE/0PMIgVn8FfqJgiBSgnMd/U8t2PCoGxm4VqL/FBbrA24pPcVzNIdEee+2W+ hlwQ== X-Gm-Message-State: AOJu0Yxm+Moaz1HP9Q928BjQ7DWAIZiy+WPzzdLsbOplYocFMTjYDnIf kXYfigGFgZxV9qU8Lhf2JKQBGQ== X-Google-Smtp-Source: AGHT+IH7AYhh/E2c+MwwbcvZIt5F8XEM6PaMiAiu8eHXkX1uA8IjiH3IUk6l8jMoCslLrqk7cDsLcQ== X-Received: by 2002:a2e:9997:0:b0:2b6:e283:32cb with SMTP id w23-20020a2e9997000000b002b6e28332cbmr151913lji.23.1691609953946; Wed, 09 Aug 2023 12:39:13 -0700 (PDT) Received: from [192.168.1.101] (abxi185.neoplus.adsl.tpnet.pl. [83.9.2.185]) by smtp.gmail.com with ESMTPSA id x6-20020a2e9c86000000b002b9fe77d00dsm2885287lji.93.2023.08.09.12.39.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Aug 2023 12:39:13 -0700 (PDT) From: Konrad Dybcio Date: Wed, 09 Aug 2023 21:38:58 +0200 Subject: [PATCH 5/5] pinctrl: qcom: sdm660: Add MPM pin mappings MIME-Version: 1.0 Message-Id: <20230809-topic-mpm_mappings-v1-5-5e17dd76b3c8@linaro.org> References: <20230809-topic-mpm_mappings-v1-0-5e17dd76b3c8@linaro.org> In-Reply-To: <20230809-topic-mpm_mappings-v1-0-5e17dd76b3c8@linaro.org> To: Andy Gross , Bjorn Andersson , Linus Walleij Cc: Marijn Suijten , linux-arm-msm@vger.kernel.org, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1691609947; l=1937; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=0NrXmn7119mRGGGI3miqjrwIUUJ2pi2cRUPmNiZdlUk=; b=0m63GWmp2DcB0guuYRK14UZ6i2eeIvWiqemEA5UR5ObDtsNrUDFXirayo4EwRo+nZXWzFrlUV D1HumSCL5CgDapRA5NHEpxTgXllT7b+Y+e3TOCZzJHWWB4gM8csFhWA X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org Add pin <-> wakeirq mappings to allow for waking up the AP from sleep through MPM-connected pins. Signed-off-by: Konrad Dybcio --- drivers/pinctrl/qcom/pinctrl-sdm660.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/drivers/pinctrl/qcom/pinctrl-sdm660.c b/drivers/pinctrl/qcom/pinctrl-sdm660.c index c2e0d5c034ac..5deabe8ca581 100644 --- a/drivers/pinctrl/qcom/pinctrl-sdm660.c +++ b/drivers/pinctrl/qcom/pinctrl-sdm660.c @@ -1399,6 +1399,18 @@ static const struct msm_pingroup sdm660_groups[] = { SDC_QDSD_PINGROUP(sdc1_rclk, 0x9a000, 15, 0), }; +static const struct msm_gpio_wakeirq_map sdm660_mpm_map[] = { + { 3, 1 }, { 4, 5 }, { 5, 9 }, { 6, 10 }, { 7, 66 }, { 8, 22 }, { 9, 25 }, { 10, 28 }, + { 11, 58 }, { 13, 41 }, { 14, 43 }, { 15, 40 }, { 16, 42 }, { 17, 46 }, { 18, 50 }, + { 19, 44 }, { 21, 56 }, { 22, 45 }, { 23, 68 }, { 24, 69 }, { 25, 70 }, { 26, 71 }, + { 27, 72 }, { 28, 73 }, { 29, 64 }, { 30, 2 }, { 31, 13 }, { 32, 111 }, { 33, 74 }, + { 34, 75 }, { 35, 76 }, { 36, 82 }, { 37, 17 }, { 38, 77 }, { 39, 47 }, { 40, 54 }, + { 41, 48 }, { 42, 101 }, { 43, 49 }, { 44, 51 }, { 45, 86 }, { 46, 90 }, { 47, 91 }, + { 48, 52 }, { 50, 55 }, { 51, 6 }, { 53, 65 }, { 55, 67 }, { 56, 83 }, { 57, 84 }, + { 58, 85 }, { 59, 87 }, { 63, 21 }, { 64, 78 }, { 65, 113 }, { 66, 60 }, { 67, 98 }, + { 68, 30 }, { 70, 31 }, { 71, 29 }, { 76, 107 }, { 83, 109 }, { 84, 103 }, { 85, 105 }, +}; + static const struct msm_pinctrl_soc_data sdm660_pinctrl = { .pins = sdm660_pins, .npins = ARRAY_SIZE(sdm660_pins), @@ -1409,6 +1421,8 @@ static const struct msm_pinctrl_soc_data sdm660_pinctrl = { .ngpios = 114, .tiles = sdm660_tiles, .ntiles = ARRAY_SIZE(sdm660_tiles), + .wakeirq_map = sdm660_mpm_map, + .nwakeirq_map = ARRAY_SIZE(sdm660_mpm_map), }; static int sdm660_pinctrl_probe(struct platform_device *pdev)