From patchwork Sat Sep 23 13:14:31 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Matti_Lehtim=C3=A4ki?= X-Patchwork-Id: 13396744 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 822ACCE7A93 for ; Sat, 23 Sep 2023 13:14:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231769AbjIWNOv (ORCPT ); Sat, 23 Sep 2023 09:14:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50006 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231622AbjIWNOu (ORCPT ); Sat, 23 Sep 2023 09:14:50 -0400 Received: from mail-lf1-x12d.google.com (mail-lf1-x12d.google.com [IPv6:2a00:1450:4864:20::12d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9906C11D; Sat, 23 Sep 2023 06:14:40 -0700 (PDT) Received: by mail-lf1-x12d.google.com with SMTP id 2adb3069b0e04-503397ee920so5768392e87.1; Sat, 23 Sep 2023 06:14:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1695474879; x=1696079679; darn=vger.kernel.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=Pi1nMZ5Qx+Hd3+Zg0OLpMqTtfkM7eJhwwI+OqM4wPA8=; b=PDVAAicv89X0Sxn9lP1z2Z8m67+DE8PIcGoHFSrn+k0QzSOj3BwJ4gmYWO58U8VA57 SXztz49ZesKOShzDHEsvThLzUmZ5J68cj4py3jYgx+Uk5G4PximjchhowP+3GDlT9ec2 WX2fcU0U5axYY7FLiMDAE/kPbm/f6rUgf/iKJjCPGBtDQnWAbCQ/Ha5OTvVldK9u5iuN stL5+GV4NaaAjoZ3SU9ZVTMHBMwyN34eI+VzyhxxPGedrR+w9B1Bg89faAkzGCbyOG42 X7+YG3uj/Y+9VRZKRFNHVzCjtGe3nhLFSIGhTj83k3fZhKwMOGzIGkbSCXx2cdsKPp3U wvEw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695474879; x=1696079679; 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=Pi1nMZ5Qx+Hd3+Zg0OLpMqTtfkM7eJhwwI+OqM4wPA8=; b=bsy9EVqOuIihF1KQTtYO6Lgs8n6NZC9sn0AYKrEm4tR3Dxh4LcPnPtuwbT151SPFKA BDRItWwPSUn7fBGS4J3k9N24Odir6VHpNVzt2WHRcOaqZnv+VT6F09/3iMOn9flFu7cN 7Eg+XYQSdLOGw9JFHWJHMExx1/9sQpEbF8tJU6danUEQ0AQ3LJyw/5gzgIAmOmGiAyT2 UxZ/akBfeXag+6lQkmm8CDuiirskCpgNn4rePSnBXyrNptSK7C49s6EF+ldPSQjYFWud DGkklTa5vR8TR+MOOu1mkXMrfHEKSOtQvG4HimiV1cs7JLjOI88YrWrvc75uptewKquJ 8ung== X-Gm-Message-State: AOJu0YxecFzbJ84OI6kIbNG3CoQFsxkaHTRrlAJRY/9SwejyL9Cm8lfV 5n6HkLg9x462fVKwuCgE4IUn5kt0yTAScg== X-Google-Smtp-Source: AGHT+IHBKU41RrGfr51ITbEELFc5CKdYQ4Y4zrMrbdaGV8gRriIIepYoaaEubDywXIo447FPCVLDqg== X-Received: by 2002:ac2:5932:0:b0:503:1875:5ae5 with SMTP id v18-20020ac25932000000b0050318755ae5mr1872523lfi.38.1695474878630; Sat, 23 Sep 2023 06:14:38 -0700 (PDT) Received: from i-vetokaappi.home.lan (dsl-hkibng42-56733b-36.dhcp.inet.fi. [86.115.59.36]) by smtp.gmail.com with ESMTPSA id m1-20020ac24281000000b004ff96c09b47sm1080847lfh.260.2023.09.23.06.14.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 23 Sep 2023 06:14:38 -0700 (PDT) From: =?utf-8?q?Matti_Lehtim=C3=A4ki?= To: linux-arm-msm@vger.kernel.org Cc: ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, =?utf-8?q?Matti_Lehtim=C3=A4ki?= , Bjorn Andersson , Andy Gross , Konrad Dybcio , Linus Walleij , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 1/2] pinctrl: qcom: msm8226: Add MPM pin mappings Date: Sat, 23 Sep 2023 16:14:31 +0300 Message-Id: <20230923131432.21721-2-matti.lehtimaki@gmail.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230923131432.21721-1-matti.lehtimaki@gmail.com> References: <20230923131432.21721-1-matti.lehtimaki@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Add pin <-> wakeirq mappings to allow for waking up the AP from sleep through MPM-connected pins. Signed-off-by: Matti Lehtimäki Reviewed-by: Luca Weiss --- Changes in v2: - Add missing entry to mapping --- drivers/pinctrl/qcom/pinctrl-msm8226.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/pinctrl/qcom/pinctrl-msm8226.c b/drivers/pinctrl/qcom/pinctrl-msm8226.c index 994619840a70..4030baa3715f 100644 --- a/drivers/pinctrl/qcom/pinctrl-msm8226.c +++ b/drivers/pinctrl/qcom/pinctrl-msm8226.c @@ -612,6 +612,16 @@ static const struct msm_pingroup msm8226_groups[] = { #define NUM_GPIO_PINGROUPS 117 +static const struct msm_gpio_wakeirq_map msm8226_mpm_map[] = { + { 1, 3 }, { 4, 4 }, { 5, 5 }, { 9, 6 }, { 13, 7 }, { 17, 8 }, + { 21, 9 }, { 27, 10 }, { 29, 11 }, { 31, 12 }, { 33, 13 }, { 35, 14 }, + { 37, 15 }, { 38, 16 }, { 39, 17 }, { 41, 18 }, { 46, 19 }, { 48, 20 }, + { 49, 21 }, { 50, 22 }, { 51, 23 }, { 52, 24 }, { 54, 25 }, { 62, 26 }, + { 63, 27 }, { 64, 28 }, { 65, 29 }, { 66, 30 }, { 67, 31 }, { 68, 32 }, + { 69, 33 }, { 71, 34 }, { 72, 35 }, { 106, 36 }, { 107, 37 }, { 108, 38 }, + { 109, 39 }, { 110, 40 }, { 111, 54 }, { 113, 55 }, { 115, 41 }, +}; + static const struct msm_pinctrl_soc_data msm8226_pinctrl = { .pins = msm8226_pins, .npins = ARRAY_SIZE(msm8226_pins), @@ -620,6 +630,8 @@ static const struct msm_pinctrl_soc_data msm8226_pinctrl = { .groups = msm8226_groups, .ngroups = ARRAY_SIZE(msm8226_groups), .ngpios = NUM_GPIO_PINGROUPS, + .wakeirq_map = msm8226_mpm_map, + .nwakeirq_map = ARRAY_SIZE(msm8226_mpm_map), }; static int msm8226_pinctrl_probe(struct platform_device *pdev) From patchwork Sat Sep 23 13:14:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Matti_Lehtim=C3=A4ki?= X-Patchwork-Id: 13396743 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 1E396CE7A8F for ; Sat, 23 Sep 2023 13:14:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231756AbjIWNOv (ORCPT ); Sat, 23 Sep 2023 09:14:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50004 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231616AbjIWNOu (ORCPT ); Sat, 23 Sep 2023 09:14:50 -0400 Received: from mail-lf1-x12e.google.com (mail-lf1-x12e.google.com [IPv6:2a00:1450:4864:20::12e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 672C119E; Sat, 23 Sep 2023 06:14:42 -0700 (PDT) Received: by mail-lf1-x12e.google.com with SMTP id 2adb3069b0e04-5031426b626so5623390e87.3; Sat, 23 Sep 2023 06:14:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1695474880; x=1696079680; darn=vger.kernel.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=Zyl55hSrpI/NQRmZG4XXfiof657r7srtbLcJb/TnH6E=; b=hbdztxRtPDg2txL4tU8i0StJt1iKDKl/kc80SlTNd83vZhFRYQhDEVNMuqUYsYMY4C gN23ublyGCoVfbdMkaMfRUR6CicLkIFj5nLvuoYRGDYt2GZo9wZ2/7orF9ikGjQjeIkx YjDjJtxRr5L1pdqk6VRHq4THOV4tIj4E1mLjrsPF2/5qrL1gsDX+JQvD+nbjt15Q0LYi Jgoxs7jg1kJqoqQMeeyHVVH3Gd8iLzyJzdk0Eva2xqkh84nYOhhoFMRn8bD6Cx/OMxbZ Js6ca8yEaZu77n6R+R3IvlsO7Z3khgxhI2BqZufRJ5J1btCuPTA0+ye9eCWYl8LbzAVp u8+A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695474880; x=1696079680; 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=Zyl55hSrpI/NQRmZG4XXfiof657r7srtbLcJb/TnH6E=; b=HyFhbO9njBcFi+CGBwA2zahGApQuFYuRYIfMNq/95HpVAr8ph1zYWb6Kp/N1VIKHrc ZMkqq3HbUDC3dbqR0EGszpm4HWhcYZf5p8GVZBJ4LsUWufT8ZHrvFnHEg7KHZi7Zguuo qDrt73G9538AL3UH4GhPK7sghthgSuE/WgD/2oE+Ox5CpGPxKZ0PNy6xREoM90Ev2c6o txUW9LL6ahAND+89wNsiEWP25cR1Un3hnHMwTelT6/5cuEg9LAy5zBE1RplO7On34WCr cAdbG2Cd6hsrN+6stsyzRPMgnSQlbq76bKWxVgOyjqdG6taYp8ttV6b4Ys4f5q3+HX2W RFzg== X-Gm-Message-State: AOJu0YxQVBOzO9RQLQfZ2iEKD+PDhQXPsBZfAd7Bk65lS6N2YAq4mfz/ kTZeZr7AjChZ6BMTRJqoWE//qNaWGPEMZg== X-Google-Smtp-Source: AGHT+IE8fCQ6pTHZZKuMgFbVuTjTce+bjedi3Ta8ahQThqNd5RNcuOTSR0Wx3PAau+eUGwrZdX+2og== X-Received: by 2002:a05:6512:2246:b0:4fe:db6:cb41 with SMTP id i6-20020a056512224600b004fe0db6cb41mr2494966lfu.39.1695474880457; Sat, 23 Sep 2023 06:14:40 -0700 (PDT) Received: from i-vetokaappi.home.lan (dsl-hkibng42-56733b-36.dhcp.inet.fi. [86.115.59.36]) by smtp.gmail.com with ESMTPSA id m1-20020ac24281000000b004ff96c09b47sm1080847lfh.260.2023.09.23.06.14.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 23 Sep 2023 06:14:40 -0700 (PDT) From: =?utf-8?q?Matti_Lehtim=C3=A4ki?= To: linux-arm-msm@vger.kernel.org Cc: ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, =?utf-8?q?Matti_Lehtim=C3=A4ki?= , Luca Weiss , Bjorn Andersson , Andy Gross , Konrad Dybcio , Linus Walleij , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 2/2] pinctrl: qcom: msm8974: Add MPM pin mappings Date: Sat, 23 Sep 2023 16:14:32 +0300 Message-Id: <20230923131432.21721-3-matti.lehtimaki@gmail.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230923131432.21721-1-matti.lehtimaki@gmail.com> References: <20230923131432.21721-1-matti.lehtimaki@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Add pin <-> wakeirq mappings to allow for waking up the AP from sleep through MPM-connected pins. Signed-off-by: Matti Lehtimäki Reviewed-by: Luca Weiss --- Changes in v2: - Add Reviewed-by tag --- drivers/pinctrl/qcom/pinctrl-msm8x74.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/pinctrl/qcom/pinctrl-msm8x74.c b/drivers/pinctrl/qcom/pinctrl-msm8x74.c index d5fe62992849..238c83f6ec4f 100644 --- a/drivers/pinctrl/qcom/pinctrl-msm8x74.c +++ b/drivers/pinctrl/qcom/pinctrl-msm8x74.c @@ -1045,6 +1045,16 @@ static const struct msm_pingroup msm8x74_groups[] = { #define NUM_GPIO_PINGROUPS 146 +static const struct msm_gpio_wakeirq_map msm8x74_mpm_map[] = { + { 1, 4 }, { 5, 5 }, { 9, 6 }, { 18, 7 }, { 20, 8 }, { 24, 9 }, + { 27, 10 }, { 28, 11 }, { 34, 12 }, { 35, 13 }, { 37, 14 }, { 42, 15 }, + { 44, 16 }, { 46, 17 }, { 50, 18 }, { 54, 19 }, { 59, 20 }, { 61, 21 }, + { 62, 22 }, { 64, 23 }, { 65, 24 }, { 66, 25 }, { 67, 26 }, { 68, 27 }, + { 71, 28 }, { 72, 29 }, { 73, 30 }, { 74, 31 }, { 75, 32 }, { 77, 33 }, + { 79, 34 }, { 80, 35 }, { 82, 36 }, { 86, 37 }, { 92, 38 }, { 93, 39 }, + { 95, 40 }, { 102, 3 }, { 144, 41 }, +}; + static const struct msm_pinctrl_soc_data msm8x74_pinctrl = { .pins = msm8x74_pins, .npins = ARRAY_SIZE(msm8x74_pins), @@ -1053,6 +1063,8 @@ static const struct msm_pinctrl_soc_data msm8x74_pinctrl = { .groups = msm8x74_groups, .ngroups = ARRAY_SIZE(msm8x74_groups), .ngpios = NUM_GPIO_PINGROUPS, + .wakeirq_map = msm8x74_mpm_map, + .nwakeirq_map = ARRAY_SIZE(msm8x74_mpm_map), }; static int msm8x74_pinctrl_probe(struct platform_device *pdev)