From nobody Sun Nov 24 12:07:06 2024 Received: from AS8PR04CU009.outbound.protection.outlook.com (mail-westeuropeazon11011022.outbound.protection.outlook.com [52.101.70.22]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3B2EA1AA785; Tue, 5 Nov 2024 13:09:25 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=52.101.70.22 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812168; cv=fail; b=bldJDWz7cklEUv2T3rM2H/CAvepCbhEKx7Sb81ExoBCOKwebCFXAYS/TpugJRleGvZ203a+KG9qZV1aU1d+q047POm7k/x63LXS1tYCfL/tDVDcA37hRWvIuFjsYScpFglfm6dsDNacHRl8sEIOCSJI3FoPw1QjO/t4q+P2NXew= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812168; c=relaxed/simple; bh=mxjAbWOV464PMVwuF6eGOPI6nsHK3o08Njk75jLKYJg=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=aU8Z5R/FTpDJdVWcqHJAJgOL765+BReei3RjtM3Z+EgynvFvKi2JzzBHeD/8RRfFIeHXIEKr8VJKB4XuhoQ2YssMbqc0sudaExF5RyBc173ZUkHhXSFK3oR07bvYGh5dd/E3ovXr0LfmEVYFag9PAh//gPlTPP+DFAJyzWAvw/4= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com; spf=pass smtp.mailfrom=mt.com; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b=EPvSRdIt; arc=fail smtp.client-ip=52.101.70.22 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mt.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b="EPvSRdIt" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=lJNf53pV+RKzzTtuuFpDJiaaBlfZHqFHhmCKjMpGbGvB/7PPCsEph/MwOhFdpZTA5LzL/ZAgVdDom9V1ApSOiLYbFDu53Djex7BjZ7fNqvn8Ew5s9D1Wio5eXD8HiJBZ6GNT6k0zOkJn2DU+9ofnuDAXJF81HQvWEL7rC2uykeXxHFoNl8/Ce/AR0GTUpdhdU3RoCft87rjGEyHCKkNNJwVRoXlVmO+1c8UqHu0MSpfUKk7bR7tIGeuWj2LRF5GKKRkp9TT4ue3M4OidNfm0ONPZDOqvZlouQj57EFGJYePAWK6c8C+c62htu8MnGvSfWfYgre0tC5hks9DNx4izqw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=pSODWt0opjE9i0NHr7kGA6OkXCCnvHRAdLpOTN3muO0=; b=DdhaXoKDqSlF0AsTz2TfdttCOw8btm93NDIptIpJAESdFeh8OKOTEpbk9UfnviDVXIfyRr/MkSf0JHYGHCA3dZRsVJSm0OvmL+tWryetkI5ZJlNeI1MENOhgeNHEpdjprmklBkN5vh+5h1uyxolM2jRNfevg1zf2RzXJ2mg5O2gCXU3BPxOSB/s4quOQLF/playm/ZGZcbIvRBPGCcaWFoJo/JsKRAfPsc+6Pq5aAFDWMsYE9d4ppI6uhGAkclXH4l5qru2BepWZgqvYLQVQ9wHL9pdpZlmPTwI1ny6etTJfDil/tTOtJSUUq4ZE54ug5WnEPPcq83LsYjbeeG3ySg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=mt.com; dmarc=pass action=none header.from=mt.com; dkim=pass header.d=mt.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mt.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=pSODWt0opjE9i0NHr7kGA6OkXCCnvHRAdLpOTN3muO0=; b=EPvSRdItUERXILhH7AXN9jG+DikQ0OYY4veYeHlru4o6ERAU8J4Ws7EG69x091djK9X7MGiCN0Xl3rpwjVkfKGe38lLOqP/4uqEE3B3neBIn+FehWrhCjbjfO7iXbgjqspiYAJAp/td7sUv3zPt1FYGoobqbAEtoLjCaax+yMlqU1sqLsbkVsv7oSNxXAsIvgom1O067yd52f5JpsCN+B2cNdK81FVqfGvQIPXy2EE12Q4cOMFx+VuPOMV22uHkpsQHRsa1n63RKMKKJhrGG3na8ZIit/zY8itH4zeivuqVIgQerATeeUP+2Jbh3po+U4VYdrf8NovNKxRVroTevjQ== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=mt.com; Received: from DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) by GV2PR03MB9377.eurprd03.prod.outlook.com (2603:10a6:150:e0::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8114.30; Tue, 5 Nov 2024 13:09:22 +0000 Received: from DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a]) by DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a%4]) with mapi id 15.20.8114.028; Tue, 5 Nov 2024 13:09:22 +0000 From: Markus Burri To: linux-kernel@vger.kernel.org Cc: Markus Burri , Dmitry Torokhov , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Marek Vasut , linux-input@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v2 1/7] Input: matrix_keypad - use fsleep for variable delay duration Date: Tue, 5 Nov 2024 14:03:16 +0100 Message-Id: <20241105130322.213623-2-markus.burri@mt.com> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241105130322.213623-1-markus.burri@mt.com> References: <20241031063004.69956-1-markus.burri@mt.com> <20241105130322.213623-1-markus.burri@mt.com> Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: ZRAP278CA0002.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:10::12) To DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DBBPR03MB5399:EE_|GV2PR03MB9377:EE_ X-MS-Office365-Filtering-Correlation-Id: 513e86e7-9bf9-405b-2b58-08dcfd9b1105 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|52116014|376014|366016|1800799024|38350700014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?lj7bE3ywiYpfnp9c9jgWnbk+n95G4AYZPz5GN9wIj1z/IJ7M9CwaacNiSKoz?= =?us-ascii?Q?TRY4jiNVUpvcH1swi5hSUc6Di4qWhDmQYLmoBJCSwg1/qvWMB8LSW5uGPJfI?= =?us-ascii?Q?Vost2lkO10eEzSfJ2rqK6XXpKIuJ0MFrYSmWQWD5Jvzyt1Y8vhB13artWvLE?= =?us-ascii?Q?h+BWJw4ogoVP+OzXfYXDQwaSZr/IN6Z/hXzjzCK89wQomKjMd8C69zRQAG+E?= =?us-ascii?Q?tf7OlPIc/9mxzKNoOlP0LhI8iElPtHh4Dkmk1y9wYGn9a4o7TBpM8tAKUgP/?= =?us-ascii?Q?aYb31aK+Bp6HqaRTEJZOPVAeSAvxpkaxnXQ88MrP/p4IBLrE/F5FEWdUQEj1?= =?us-ascii?Q?/a19hqUAE8lEMk9Yk/mkjHLElHVCUFnicaOgu54VsvF9OLa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3YZqmDaG9QAFVCqVQuEjz4it+sSPiCCaI?= =?us-ascii?Q?LOefaF2Tl+EkeoInIiNnPHkhppE06F0iwCjXnTVzFYVBbiIvyvLqvuy0qtHY?= =?us-ascii?Q?z/uc4kVSJX6RfXlxNvUcRfEeSdkG?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DBBPR03MB5399.eurprd03.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(52116014)(376014)(366016)(1800799024)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?OSR6aQrbDUsOotBX+ZXyqP+ORvAvQR9p+umx72VMSkkd81IpsecUM7jj2/8x?= =?us-ascii?Q?pECLmiW4LTud5VCi9G7Flv8JDJm2eTjDtk4rYaQsax//MlV6NuhxQHtsyk5m?= =?us-ascii?Q?9FkM+qGn9edDBl7E1siWL3tqOiEnxhDGBqeZqGOC8Ff+K8f5kT7xK1nplLDr?= =?us-ascii?Q?cgBZ/WMpzJJFzSrx2HBVsCs+4KeJAk6af3O1Uv9lSoZRMB1vIsmRwyrdiKIc?= =?us-ascii?Q?c8XDNlfp0f+qGk2RtAG5OX5NK5gg02jBW1VL+clR90fhJtMci25/BGlaJbud?= =?us-ascii?Q?junWJnTyPL1pzp4TqFPe1HzVBlWug5Wy0qfmvNB/8gyUtbi2Cb/vIJIFRrRG?= =?us-ascii?Q?chS4ATsnuxgPeoTFNdMvSJ5KRGtuUU2/ph5pEEy5vKwyZokfn5FR+0EcxXLO?= =?us-ascii?Q?TB1xEMIg+qLrgPDy+L+WxuL6EDna1yY+Ff5p2HME0bY1uXrRfZ0rGpW9hrTv?= =?us-ascii?Q?ULBhMKvBhvo5KUf7RvEZ8sOyTpnzLgdggLeDYnUURx19WSYJni3PhAd9dk4l?= =?us-ascii?Q?zKvabsL6X2+cqXIs7EJ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E?= =?us-ascii?Q?IGttcIfQ6On7/Lvkx2Ykw71vM2t/oXBLqkXFcWihlmGOasGt7aqU8zwKJxXk?= =?us-ascii?Q?6Ide18Qz6gTe+sqlRVHMb/wZJ24fMl1UxOsseOW+vSYZP0hZ1izCAoij8NJw?= =?us-ascii?Q?4H5s4aL7Ua74qqkNb2FeT2T1xAJFAeRK4t8S3P5j?= X-OriginatorOrg: mt.com X-MS-Exchange-CrossTenant-Network-Message-Id: 513e86e7-9bf9-405b-2b58-08dcfd9b1105 X-MS-Exchange-CrossTenant-AuthSource: DBBPR03MB5399.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Nov 2024 13:09:22.7760 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: fb4c0aee-6cd2-482f-a1a5-717e7c02496b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: xZfefxVp74OaI9Hq8HVUDEzJKQ5FC4ZKxga2i9/jKjwhkAtWi/BqWopZXmmPXjexMTpSU8ssTq7JAd9TdAvwZQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: GV2PR03MB9377 Content-Type: text/plain; charset="utf-8" The delay is retrieved from a device-tree property, so the duration is variable. fsleep guesses the best delay function based on duration. Link: https://www.kernel.org/doc/html/latest/timers/timers-howto.html Signed-off-by: Markus Burri --- drivers/input/keyboard/matrix_keypad.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/input/keyboard/matrix_keypad.c b/drivers/input/keyboar= d/matrix_keypad.c index 3c38bae..9eb6808 100644 --- a/drivers/input/keyboard/matrix_keypad.c +++ b/drivers/input/keyboard/matrix_keypad.c @@ -69,7 +69,7 @@ static void activate_col(struct matrix_keypad *keypad, in= t col, bool on) __activate_col(keypad, col, on); =20 if (on && keypad->col_scan_delay_us) - udelay(keypad->col_scan_delay_us); + fsleep(keypad->col_scan_delay_us); } =20 static void activate_all_cols(struct matrix_keypad *keypad, bool on) --=20 2.39.5 From nobody Sun Nov 24 12:07:06 2024 Received: from DU2PR03CU002.outbound.protection.outlook.com (mail-northeuropeazon11012006.outbound.protection.outlook.com [52.101.66.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4287F1D79B7; Tue, 5 Nov 2024 13:09:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=52.101.66.6 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812175; cv=fail; b=sW+BdSBxe6rOrO+BMULxCEr6bZooJ8/c65YchIrA8BH8IP5EVfEvE5Dg4U2wiowxi2v8DGcLamfXNnuaDSKBLwxespJqRx/btKvL+1YU5RneyF93st3s1xYj7M1sqDLZ+OHEZ/EEtQCbinui6N+1fMWJmYp886XdMMoXOJh6fBw= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812175; c=relaxed/simple; bh=ICb1ZJa6LdnXLJpcObLc7GnKhpTlymZSzdD9dyFNT2Q=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=Zkkhkaawfw/gH4OsPsXp+LhJm12VaGvb2SUYqklTtTZgKti9uD6oejaoObWAyCPmaWPJVsndBKXFraKjj3mrYLFvwEBWH7W5Oqh9Si0xtkEpnDrBtHAVF4JBACIKUziyI+lFX7FweCySdj821rDtRpk+9fLXf1VZKv0Wxg+DbHw= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com; spf=pass smtp.mailfrom=mt.com; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b=SjAA99lm; arc=fail smtp.client-ip=52.101.66.6 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mt.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b="SjAA99lm" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=qW1oZfMyzPP6OIm6UC/CEwXj7u06FVQrzA/FlYfDQNiiY+66SuKiR7eiJUOsgHnQ0+q4ieopujG7DfHDZL+7GEYCPENeOhtDc+cQPX6zfZMxPYILoIUkbglOxYOFBV3/A4+5OQarwHFt00X8kaBa3JKWUyDdwmZ6TBpQOwAMl9U3aRE6nCdECMFg68XclK1qtB79YUsCsTKs7cc1gaLK12aphNWZYXXbsxeeWLA8WoUzi/x3BV/VXss1jTHed7DeStjHbPPVXRMjyGISsjNnZJESigUwUvGTzTXwKX0DVawJ/HCL6kz7JTrYUE71Sl/qTz7QPkwV1KfSCDojbzfmHQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=etH6092wcqik7oYjT3OW7PC/JboEFgrsdlXTFY9BDoE=; b=LaqEuzvbM1dSD7eg3VVZXfwDLAyJy6NezupPVcKEvow2llosVVevlUtL16YiBToX1w/suyssU7AJjHl/IpBnTXvzTgz81l8Gh/nvJODW1PhHR02NRK4naC3jmRmQ46arKguGpzKbX3JDzP2bza4zTqc8yO+OhsPwr/Fuu9HhcHgUd7jDhRuNGL9DjEh96rASd/YdXoIprw0KQP3HWXfYmkZbx32ZrOvZG575bUsb/eoYLiTpZXMtTyGtBJ/BN8wOjkZZW2eLgerU6Q0PoZAAPV0xBfO3iZTxhOOJ8W7RU33UV3vrhU26INRMDlHbhlAILPMh1/nkEG48SGrIY5nJdg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=mt.com; dmarc=pass action=none header.from=mt.com; dkim=pass header.d=mt.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mt.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=etH6092wcqik7oYjT3OW7PC/JboEFgrsdlXTFY9BDoE=; b=SjAA99lmrYftZIaIu7u07C/Fg0ARDdlO06GRD0MtZhVc9i9Wsta829X9ph3mCi9WrNqbK6FX6z/NqEnd8qJGnTCD0I2J3QICNH9/yB490wBBE69HbZZzcLSZlKTJJhdS8yuXs0zSwSuh/aDRoQvNRZtqxKmtK25pdorPOD/oUl+NFoNq8cNVjp/qrnYNNUyv+IFMxzIrjSr1eeFPSX2bjbDxFSPuP4qQG5GUhU6eUl/NC/ZWfb7f2bP7QGVkwdXG1fuJoPoJFQLvvhnf0C0X3eyDxzUOzjfiBckzLYeQ9uRa2nkNPawrPplNTZ9ckXAMnZqUT7i6UbM9ONcIdkWjkQ== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=mt.com; Received: from DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) by GV2PR03MB9377.eurprd03.prod.outlook.com (2603:10a6:150:e0::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8114.30; Tue, 5 Nov 2024 13:09:30 +0000 Received: from DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a]) by DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a%4]) with mapi id 15.20.8114.028; Tue, 5 Nov 2024 13:09:30 +0000 From: Markus Burri To: linux-kernel@vger.kernel.org Cc: Markus Burri , Dmitry Torokhov , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Marek Vasut , linux-input@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v2 2/7] Input: matrix_keypad - add function for reading row state Date: Tue, 5 Nov 2024 14:03:17 +0100 Message-Id: <20241105130322.213623-3-markus.burri@mt.com> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241105130322.213623-1-markus.burri@mt.com> References: <20241031063004.69956-1-markus.burri@mt.com> <20241105130322.213623-1-markus.burri@mt.com> Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: ZR2P278CA0025.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:46::15) To DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DBBPR03MB5399:EE_|GV2PR03MB9377:EE_ X-MS-Office365-Filtering-Correlation-Id: 6dbf1fd2-040f-48ce-06fc-08dcfd9b15a4 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|52116014|376014|366016|1800799024|38350700014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?GO0Y55qAjdjVwwK6LmYuoVdgbAMCYUfUEOAU4gqc8Vb8Qpy0FVddwWtkJrOd?= =?us-ascii?Q?ZL1b5O8I6SVmD8BOAKu8ucHchm3UH6vfn6r10SUaD+3aC3sBChz8O9R5b/cp?= =?us-ascii?Q?LeKiQIkFJCMuqomU+RkYnHsFr20hiNoGKs5FMCgN9DWEOFxG14WCaSvBlPNU?= =?us-ascii?Q?5/1RHnRjgkFZaK9pWE+og3++YwS+s1/7PDLSCBzkRfZg57ci8vQxh4ydyyRC?= =?us-ascii?Q?GancXzJ0adZWg92cKT3kOtzvJJh7iSnMQF2iMRNr9OcrbkPRahidfdq3OAXE?= =?us-ascii?Q?AewegKYuBtigRipJCTVkRBZS67Tye0EiV9UgJ1g6dCHKV2cTzg7RqcCQnVyk?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cF3qRZZ1p0SxK86x/U5Un9YfZLaNn2ku9Zvc9?= =?us-ascii?Q?SJ9Ac7P57KsQ/xZLAR5wKmVbmozjfUshQKdgE8rKsU32QB8n9MfZxUThw4gK?= =?us-ascii?Q?gmMZ29GGlBHQKUdfS7g/Ya84nJUKXURnX7c51q26dj3CMw4GYngAyz/pKl+C?= =?us-ascii?Q?Kc48VFc=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DBBPR03MB5399.eurprd03.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(52116014)(376014)(366016)(1800799024)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?/kgKYsL6l2c5HUZXSRmtF+HpiVBEp9h3ly3SDJQONQhbqeqmdnGIhJUMdWCd?= =?us-ascii?Q?dVpIUWyjoR0+rn6oK9e8uSzflorArr/WZeS3uxAD+Q3rZ7C1poCNnehwRteo?= =?us-ascii?Q?gwtc9L/rq/jTFmjP3kK1dz+Z7i1047vRUbypj/g89jAngt9Uzm4WfCygcQOf?= =?us-ascii?Q?DlTf4CZruiuUq4ebmENGOByqPSLLdJd2worGm5tBJR5r07EaNmcYGDqXuCIM?= =?us-ascii?Q?LKVI8TADUpEh1y/EvxmoagnWY87m0BTFD+26uuobRt0sENitI3yZYJ2ncPpU?= =?us-ascii?Q?Bcjoiv0FSMb0jkrIVX9Y1Rk3wV3rwiGBVFPvJPeTnvhhjLsOxicJvAShQrND?= =?us-ascii?Q?AG6zxBUtacIujw2pYITyI/Smd7ZiVhvjGbVH584VycuJ0ChdsMmaM4qjhtx5?= =?us-ascii?Q?0VQ7FHMfEP4MkGHpwhtwEivVS6fmfCSbp8ufuZuGcHIsNwhNLvUnzVOZD/t1?= =?us-ascii?Q?RmNiG2+3Oa9diHiinR0P1IGqEUjzvxT3gckdtCkU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SPvNplRr5TIhdM67zxeSUBr+v+3VusFDM9dmg2ucAdRj?= =?us-ascii?Q?3AaUXOD4sJRM2QKIFTcrrnp+z39jrlgp1UFpyOHNq/ux+F5cNggRpsoYGQMk?= =?us-ascii?Q?avePOBQEURmfD/oMl57GuPE4ssG2MvViKyhDAbgxSAKx0ubN8o5rciFOE1F/?= =?us-ascii?Q?5pCdHvgj19wcOaZdWB1STLvjwSfcQtOI1Ea022wk?= X-OriginatorOrg: mt.com X-MS-Exchange-CrossTenant-Network-Message-Id: 6dbf1fd2-040f-48ce-06fc-08dcfd9b15a4 X-MS-Exchange-CrossTenant-AuthSource: DBBPR03MB5399.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Nov 2024 13:09:30.5316 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: fb4c0aee-6cd2-482f-a1a5-717e7c02496b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: fJa6gOjvWGSlnAj8WNcFy0uyN0TS4gB3TLW99KdlYvtSDgMvMl8JaUHDpLhqmJw3LHSTaFo2Y3CGRQGt04eTiw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: GV2PR03MB9377 Content-Type: text/plain; charset="utf-8" Move the evaluation of a row state into separate function. It will be also used by a change later in this series. Signed-off-by: Markus Burri --- drivers/input/keyboard/matrix_keypad.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/drivers/input/keyboard/matrix_keypad.c b/drivers/input/keyboar= d/matrix_keypad.c index 9eb6808..2818915 100644 --- a/drivers/input/keyboard/matrix_keypad.c +++ b/drivers/input/keyboard/matrix_keypad.c @@ -101,6 +101,16 @@ static void disable_row_irqs(struct matrix_keypad *key= pad) disable_irq_nosync(keypad->row_irqs[i]); } =20 +static uint32_t read_row_state(struct matrix_keypad *keypad) +{ + int row; + u32 row_state =3D 0; + + for (row =3D 0; row < keypad->num_row_gpios; row++) + row_state |=3D row_asserted(keypad, row) ? BIT(row) : 0; + return row_state; +} + /* * This gets the keys from keyboard and reports it to input subsystem */ @@ -126,9 +136,7 @@ static void matrix_keypad_scan(struct work_struct *work) =20 activate_col(keypad, col, true); =20 - for (row =3D 0; row < keypad->num_row_gpios; row++) - new_state[col] |=3D - row_asserted(keypad, row) ? BIT(row) : 0; + new_state[col] =3D read_row_state(keypad); =20 activate_col(keypad, col, false); } --=20 2.39.5 From nobody Sun Nov 24 12:07:06 2024 Received: from EUR05-VI1-obe.outbound.protection.outlook.com (mail-vi1eur05on2063.outbound.protection.outlook.com [40.107.21.63]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0638F1D5AD8; Tue, 5 Nov 2024 13:09:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.21.63 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812188; cv=fail; b=r2CCT7gNyR4QacSWC6jmHiewE2PpDLVA9slfn6NXUXVW+dS3ZpzEL59dWCAnQRHmQqF/G6P9yDTgB0ckdV9iSJ5hy0w2AtDDXqisHvV9VvM6+FOtgDkpAv5gJdLCA/zfVh6o1knNMqu8o5gWfktbOMcO9CPpN1LX/AUPvdWPmjY= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812188; c=relaxed/simple; bh=D4Ak6jcKklaQNd9P5WXiyg8rFu4ecgUqmYcpaVN0Huk=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=Xdma1ZEJ4mZh4OnmDDXBPc0RRTlmMdDk+gU0HyQXEaw0CmvPAJlMleg2F9MlVdwx3rJDFXGB/MgqF5/COxUZ6b0l8K0Df1ZrVX0GR9vuvBzcKq3Z0yQChFNcbjT+b7R/yPADSkULYlZcAXHoAm+7DYGqY2LhHUnzDwkfKma3F08= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com; spf=pass smtp.mailfrom=mt.com; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b=ekINm43W; arc=fail smtp.client-ip=40.107.21.63 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mt.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b="ekINm43W" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=ZetmmI0mMhShX8uuJRoOs/o2hPrpoRcCNwlCMCqeWtoHk4S7ecw1a06FML05h8fSUbzZlf2XqadpMxt8suB0lWc6u/Resw6JvQqczwHkEL748Am2ZIb2l5nJG2QUFiNLGw24ufCSMXj4gQYlA69oqMZOxBgIXsfyRhc3pDrTgkBZ5Q2UV2trWYOTHjWSmwiqmzYUJgevFcs7bwEFx2rZ11qHGDSPyg/SsAindhgBGen8Z/+hV/qm637dvIqwhKO3OXsa+WpQeS4UiMx6AAfgCWKJMw2ilJ0oEV2NfNvkRu6F88+pr1hb/kpPyV+qjg9xhU8CIWMrClnlK5jMiBFO1g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=iCaMny5/duH60dVwnVNbsO12yqHuLzmpEI39bRaipvU=; b=L5yo/un2sqeiQyB58iS0NFCfFY10kyzqFQcOijQGyUar0TG8jj0xk9516NSmracgoAO4cSqKolVFpDkLIsbEd/qXzKyC5pIJJKewGHU374VghIXY6dTcJC4rvvhq3PoKvkZQRRH0fRNd36kw6a2sRJB3fqrS9rD3YhBD348j3ZOUm4lYS552VfzLYYzp3FGRxdueXLE2XGFceWH/jE85Omqz1qWuyqv1yMwQpe8/pfVF4o0z+CWcfc92vgPhkxZcpRxU/7ggIflA8OCP1RTSBJtlCsEgnJcomZ27LG6YWtltG0v2Hq18IlnSa7E8e9gE0q5gt9t1i8POqueSXi33mw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=mt.com; dmarc=pass action=none header.from=mt.com; dkim=pass header.d=mt.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mt.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=iCaMny5/duH60dVwnVNbsO12yqHuLzmpEI39bRaipvU=; b=ekINm43WBa1RwJuOTWyr0qDyAqdmB+qe+qhOIUkoj029n3zFRIFfgCaS2WdyUCc2qmceygsaEk3TtRknSm14dIXiBVoqY0X/hD/0a21Bfo1xRiDC4qa3apKDsTnwBwP4hN/2Fvs35ivp/PKnhajzMtyxptL7DzdO0EbLlD3OaXSq1xKSOvMjD/+HrKJ+MvYlWKVJbPQbeA5Kx6MvUf7ur/JaWYniWTc7nJXT6Ppa+zDj4lgknOivacL0GlwWqAqKE9Vt/d5nxwBSHPjlMfsEJE9CorPrWED2kqlNa/sucoIGifPJwjaSts8byvZqbaAvnGuvd6mE+pShqqJ9ag5QiA== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=mt.com; Received: from DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) by PAVPR03MB9211.eurprd03.prod.outlook.com (2603:10a6:102:325::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8069.18; Tue, 5 Nov 2024 13:09:38 +0000 Received: from DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a]) by DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a%4]) with mapi id 15.20.8114.028; Tue, 5 Nov 2024 13:09:38 +0000 From: Markus Burri To: linux-kernel@vger.kernel.org Cc: Markus Burri , Dmitry Torokhov , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Marek Vasut , linux-input@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v2 3/7] dt-bindings: input: matrix_keypad - convert to YAML Date: Tue, 5 Nov 2024 14:03:18 +0100 Message-Id: <20241105130322.213623-4-markus.burri@mt.com> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241105130322.213623-1-markus.burri@mt.com> References: <20241031063004.69956-1-markus.burri@mt.com> <20241105130322.213623-1-markus.burri@mt.com> Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: ZR0P278CA0128.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:40::7) To DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DBBPR03MB5399:EE_|PAVPR03MB9211:EE_ X-MS-Office365-Filtering-Correlation-Id: 0bf6abc9-24d5-441c-1951-08dcfd9b1a2a X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|366016|52116014|376014|38350700014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?hZ1AEuPr6Hu8icpMhRxk04KbfbU8gs6eb0VoBEwzCQ4N2rEWekfEY1mRR7L4?= =?us-ascii?Q?eYBvlbb3Gpbp0fHTfOLn1qsqcsO4nzeeWdeKFTF8GLyZGRPxKsekDjPXe7xX?= =?us-ascii?Q?GDwmjB6thynZzLvqs1qwatvByacPHLact1kMXQ0+TgkiiYFACf9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LzaSLQtVXlDfd8GkMH3pIHpdn4BSNgmPgtxkS5xDkuDnB?= =?us-ascii?Q?GwDiPtZ7EsCWX/n/U27WsSGMuIYn8FixvDSxKhYGDliMnyoWaFcVtNFhPo9Z?= =?us-ascii?Q?qK+z7A87UqAqUC+f1bo0TaFFg26tPZXnMpffB4nP0LZIBvlXUXdateL0gqnd?= =?us-ascii?Q?Q5dGjHbuDN/jf8QrzaJNjzBor01AmKkcNMDZBcGgCgvUnxV7tvN4luVw9S35?= =?us-ascii?Q?Lm7IwYWglt5jPECZ/zHdtAdW0owStJR2S4wvP1HjhcGylwGzLljutT9Hvf7f?= =?us-ascii?Q?DAJ+8jUdR3B1MHfQmESDd2R2?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DBBPR03MB5399.eurprd03.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(1800799024)(366016)(52116014)(376014)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?iNEK+NVxJg0iAxIXB/9/XFLMnyLEHUdpei8lcfIjj9rVeXahDzIjmUaF6/MQ?= =?us-ascii?Q?gd/rL3syJI0ekk7qKGoXZRPdQMbtmS4MEuUcYHzKY4Qr0l3Jl2N+QTV6lReu?= =?us-ascii?Q?wWIyhQIhsSp+10Mm06Jof0lx0MWJRNhGI+T6KOu8ImimjJgDrHPxJQ7xhqzZ?= =?us-ascii?Q?ik7DnYEDCWPRs3mmEppivRPOYjaZY0Zr/lgzRWirXPMtZY70of1PXDKK11V3?= =?us-ascii?Q?+o1uc68PUp/vhbHC2xiE4LASFDmlbn60aR/VZX5UM2tjSszB0twZBirpHdaI?= =?us-ascii?Q?2XdSN3lJjn2mb/ZxoxkUX7wqDYa6l2AGVlp5jdGcnx+9GJAMEkblt/Vx+7DM?= =?us-ascii?Q?1g/2mv59J+3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Ok0IPnjDaDtM?= =?us-ascii?Q?/E1pUC4Mwjo0tAKBkq3jCWr2pJkDzUfJKwZwu2qaRivmwMVWn1kFExgL1I0r?= =?us-ascii?Q?7vhJuubYAL7POdZqLwyiFCuV0CoXAmFVr+QwuQZrRDsd3csYNgnWSGKzT7Sx?= =?us-ascii?Q?WgqCOEpocdmBpu6Yd1FpO7Vb3fR+6EqlFTGx3M7R85umaJOaOQ2wPDfXbkvr?= =?us-ascii?Q?fteKkaTlK4hoee9s4R5unGfKagpv1ujM8Kt9F8mjOykl412fphAyZefaQdeX?= =?us-ascii?Q?agUjR8g2cKQoJTl9WVda3p101Eej9RhuQfBWSRB3gC8Tb5ySFpQ8z6gOjFZe?= =?us-ascii?Q?DkWEHRnFsKA5VptUpv4UMFhmlbxW4Ek+pqHr+b9u?= X-OriginatorOrg: mt.com X-MS-Exchange-CrossTenant-Network-Message-Id: 0bf6abc9-24d5-441c-1951-08dcfd9b1a2a X-MS-Exchange-CrossTenant-AuthSource: DBBPR03MB5399.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Nov 2024 13:09:38.1248 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: fb4c0aee-6cd2-482f-a1a5-717e7c02496b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: WFpkvq1GkEH9pq9XoR38j3leLnDI1qGE0M7/PoLXo6q0rTjK/foNsni4yDBq82iMXuDUzX84vYgxM1gJRK2lgQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAVPR03MB9211 Content-Type: text/plain; charset="utf-8" Convert the gpio-matrix-keypad bindings from text to DT schema. Signed-off-by: Markus Burri --- .../bindings/input/gpio-matrix-keypad.txt | 49 --------- .../bindings/input/gpio-matrix-keypad.yaml | 99 +++++++++++++++++++ 2 files changed, 99 insertions(+), 49 deletions(-) delete mode 100644 Documentation/devicetree/bindings/input/gpio-matrix-key= pad.txt create mode 100644 Documentation/devicetree/bindings/input/gpio-matrix-key= pad.yaml diff --git a/Documentation/devicetree/bindings/input/gpio-matrix-keypad.txt= b/Documentation/devicetree/bindings/input/gpio-matrix-keypad.txt deleted file mode 100644 index 570dc10..0000000 --- a/Documentation/devicetree/bindings/input/gpio-matrix-keypad.txt +++ /dev/null @@ -1,49 +0,0 @@ -* GPIO driven matrix keypad device tree bindings - -GPIO driven matrix keypad is used to interface a SoC with a matrix keypad. -The matrix keypad supports multiple row and column lines, a key can be -placed at each intersection of a unique row and a unique column. The matrix -keypad can sense a key-press and key-release by means of GPIO lines and -report the event using GPIO interrupts to the cpu. - -Required Properties: -- compatible: Should be "gpio-matrix-keypad" -- row-gpios: List of gpios used as row lines. The gpio specifier - for this property depends on the gpio controller to - which these row lines are connected. -- col-gpios: List of gpios used as column lines. The gpio specifier - for this property depends on the gpio controller to - which these column lines are connected. -- linux,keymap: The definition can be found at - bindings/input/matrix-keymap.txt - -Optional Properties: -- linux,no-autorepeat: do no enable autorepeat feature. -- wakeup-source: use any event on keypad as wakeup event. - (Legacy property supported: "linux,wakeup") -- debounce-delay-ms: debounce interval in milliseconds -- col-scan-delay-us: delay, measured in microseconds, that is needed - before we can scan keypad after activating column gpio -- drive-inactive-cols: drive inactive columns during scan, - default is to turn inactive columns into inputs. - -Example: - matrix-keypad { - compatible =3D "gpio-matrix-keypad"; - debounce-delay-ms =3D <5>; - col-scan-delay-us =3D <2>; - - row-gpios =3D <&gpio2 25 0 - &gpio2 26 0 - &gpio2 27 0>; - - col-gpios =3D <&gpio2 21 0 - &gpio2 22 0>; - - linux,keymap =3D <0x0000008B - 0x0100009E - 0x02000069 - 0x0001006A - 0x0101001C - 0x0201006C>; - }; diff --git a/Documentation/devicetree/bindings/input/gpio-matrix-keypad.yam= l b/Documentation/devicetree/bindings/input/gpio-matrix-keypad.yaml new file mode 100644 index 0000000..745652b --- /dev/null +++ b/Documentation/devicetree/bindings/input/gpio-matrix-keypad.yaml @@ -0,0 +1,99 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- + +$id: http://devicetree.org/schemas/input/gpio-matrix-keypad.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: GPIO matrix keypad + +description: | + GPIO driven matrix keypad is used to interface a SoC with a matrix keypa= d. + The matrix keypad supports multiple row and column lines, a key can be + placed at each intersection of a unique row and a unique column. The mat= rix + keypad can sense a key-press and key-release by means of GPIO lines and + report the event using GPIO interrupts to the cpu. + +maintainers: + - Marek Vasut + +properties: + compatible: + const: gpio-matrix-keypad + + row-gpios: + description: | + List of GPIOs used as row lines. The gpio specifier + for this property depends on the gpio controller to + which these row lines are connected. + + col-gpios: + description: | + List of GPIOs used as column lines. The gpio specifier + for this property depends on the gpio controller to + which these column lines are connected. + + linux,keymap: + $ref: /schemas/types.yaml#/definitions/uint32-array + description: | + An array of packed 1-cell entries containing the equivalent of row, + column and linux key-code. The 32-bit big endian cell is packed as: + row << 24 | column << 16 | key-code + + linux,no-autorepeat: + type: boolean + description: Do not enable autorepeat feature. + default: false + + wakeup-source: + description: | + Use any event on keypad as wakeup event. + (Legacy property supported: "linux,wakeup") + default: false + + debounce-delay-ms: + description: Debounce interval in milliseconds. + default: 0 + + col-scan-delay-us: + description: | + Delay, measured in microseconds, that is needed + before we can scan keypad after activating column gpio. + default: 0 + + drive-inactive-cols: + type: boolean + description: | + Drive inactive columns during scan, + default is to turn inactive columns into inputs. + default: false + +required: + - compatible + - row-gpios + - col-gpios + - linux,keymap + +additionalProperties: false + +examples: + - | + matrix-keypad { + compatible =3D "gpio-matrix-keypad"; + debounce-delay-ms =3D <5>; + col-scan-delay-us =3D <2>; + + row-gpios =3D <&gpio2 25 0 + &gpio2 26 0 + &gpio2 27 0>; + + col-gpios =3D <&gpio2 21 0 + &gpio2 22 0>; + + linux,keymap =3D <0x0000008B + 0x0100009E + 0x02000069 + 0x0001006A + 0x0101001C + 0x0201006C>; + }; --=20 2.39.5 From nobody Sun Nov 24 12:07:06 2024 Received: from EUR03-AM7-obe.outbound.protection.outlook.com (mail-am7eur03on2065.outbound.protection.outlook.com [40.107.105.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 16BB31D6DA4; Tue, 5 Nov 2024 13:09:50 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.105.65 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812192; cv=fail; b=t6yRbMOrybo8MtRDGyjSg98wzbEGBjOpxhgOBs+xA6Cjp8qIguKeLQBn6HEKr/gBHFFXPn2NbtEr5gOOoF/UqR8ubqRrahjaKxY4r8VTIZ/9DTQjT3KopyDBVoJ7q4cijIFuuUnTY672XKcZar2aif85yKmYc27q5/kc3fuUXuo= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812192; c=relaxed/simple; bh=ixd9vx7fGX6WhyKoIZR+/6JvIOeTDfPrEj60bDbhlBk=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=sd37ZBuUiUSHAlQ10g0g2M6hwH+RwJg4xrCesolbO9J7WppDxD1Z9NZSdmMrYQVSR0FLWvkCn0i8XD9EHPyVxdXU3XlkdFvCTraKUhop3d96ZpLsy0+k52um7DgQNZh02urCO33mwwhr/Im+M9s2c2pHuz1VrFGskEHcgPkUNUg= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com; spf=pass smtp.mailfrom=mt.com; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b=hnfHMGQ4; arc=fail smtp.client-ip=40.107.105.65 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mt.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b="hnfHMGQ4" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=S9hf0tqBE4AH8zigWWc7WdFjPMkzwCfvyjbNv+VPesGAObuOHXfZ5Pvwyl0mrej2xh9yYIgyknn/gBFs6XB1AE/t1Q98qN4TulUCJSe+AOzgDZHcF0xx5vBlJASD1Zrq/i2GZ31/UJU5+nRBWThwoQS3JOxQQykA1CGxILfNun9EbDu2PEsEYLtK73hBTs12koqmu65hueQPXeCO/BDRUOgVIqwEcojS+9JDhvcvO1uO2tFJZ36MU5zDfHwU2zqOfc2omk1BjTGu/8KCxFDYTvSOaCFtRVLgmPe5GQRxIOaFqLPL+BQEV4gvBt6IYdr3eVObPb45AMORctUT6Y5OGQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=YPpqvU/x1lLLzvA1jSXQ2tcMAGSm2VDvD1469TGC/pk=; b=Iv2eN3YBM+PL2itGkhasNKIdOWO81qWhKdd4qadJqQDq1m6p4WPuADY3C0fkuASX9sn486ITXglMGOuxB3vUG2YimRz/xAq3artWs4JkZTpo2mIMGaCFyTzgOlcBQ0qhgIvE4H3z9G29HuhDrPH4wt+sdUtoiJO7Za4/Xc/QAG4O1seZZOFcT9MCwvEvkwbhuSYT2NBBupLJrJ9rSezyJUmY8hJfud6kK6wkwvYi3tl3YH1xev0hGocYXZwqDuh4XUStPhtNTPYAftt5kbYBbAftB5lIn8Cz3KZY/JrqhMqHd/1hmjln9kLIhdBn2IppM7nLmoqzkirI72nhot9KqA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=mt.com; dmarc=pass action=none header.from=mt.com; dkim=pass header.d=mt.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mt.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=YPpqvU/x1lLLzvA1jSXQ2tcMAGSm2VDvD1469TGC/pk=; b=hnfHMGQ4CExth4GxjNhXET24rY5FqBWbVV6qFrj014eG+IQTqH/OJsAsMk3DgjwXNFWd30b5g8fMQL2oEzWktIDLa4WFSfqUIQLNxgePsfjRFIivZ1wwcPyrJWCCeywEGs3iCgRl31TW5Tp/W8WhhKWU8Ig/iPEUVqjjXhN1KkCzD+0iURiMX2eInC2vlwRT3gkCXXKeFarpuCF/XoZAi16e50I1IcLNvLXKDTrkM4iV34Bbi8DXIXShkj9cvS00wp74+XEZJG4XMlu+73zHXJxh8arABpikfkNXwFp+4XaXyjJal63d6oF4adwAo2XMPtgUTEjR4TOWjrumMrR6Cg== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=mt.com; Received: from DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) by AS8PR03MB8468.eurprd03.prod.outlook.com (2603:10a6:20b:52e::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8114.30; Tue, 5 Nov 2024 13:09:47 +0000 Received: from DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a]) by DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a%4]) with mapi id 15.20.8114.028; Tue, 5 Nov 2024 13:09:47 +0000 From: Markus Burri To: linux-kernel@vger.kernel.org Cc: Markus Burri , Dmitry Torokhov , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Marek Vasut , linux-input@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v2 4/7] dt-bindings: input: matrix_keypad - add missing property Date: Tue, 5 Nov 2024 14:03:19 +0100 Message-Id: <20241105130322.213623-5-markus.burri@mt.com> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241105130322.213623-1-markus.burri@mt.com> References: <20241031063004.69956-1-markus.burri@mt.com> <20241105130322.213623-1-markus.burri@mt.com> Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: ZR2P278CA0024.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:46::13) To DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DBBPR03MB5399:EE_|AS8PR03MB8468:EE_ X-MS-Office365-Filtering-Correlation-Id: 29257e80-f1e1-43df-b624-08dcfd9b1fa1 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|52116014|376014|366016|1800799024|38350700014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?vuhXbb9FcUhQE9Z1sAxC/HuzWULXfk+BkYkOsyXH4q52zZKM20mbOu7TtqT+?= =?us-ascii?Q?EMPrISy3c0yge4uC1CPH7yqySS6u7I7xZ8ZLRyUkKeYLek+X1dyjLZUlu2lN?= =?us-ascii?Q?AJ97PnXGFEn8pOu3s5fAVw2vD7lPv5iPRwfUh5l16+KrdUiu/UkmIkU1GoUy?= =?us-ascii?Q?E2j7HvvFnG+CwD0s6aErX4P/Hvq+4eurADd00Aj5Vn8MrhB6oGIoCZNd+I1l?= =?us-ascii?Q?1eT9KG1Mw5CbokBMubtRzPELWVKdhp/Y4wQYwG4VoqgUKMAA/olyIT9orlv2?= =?us-ascii?Q?X74MDVoUQwnvLAAqVG3Vdasm0EYC9dkWeyzrFJD7pkVNBenYuQq3rYGz6dAD?= =?us-ascii?Q?3mVMGj2QisWi8w+3DRr+poN252K0/bf6XIBOHpKEqDHkls6H/Ka1L6solatl?= =?us-ascii?Q?jXsGzGkFJXorc+Aer+rbkH09YpaBw6QKHjK0HNVaLPbIX0PWE4N6cUcxyOoP?= =?us-ascii?Q?m3eelwni36h7a2g/OK9cJmhVqoIzbHb2z92W5XA89LlhBvPflfucIp5+Bem/?= =?us-ascii?Q?EeckSCPADobxbPm2BWpIlRGg3ZA8qqcssthBkKKz4wVk4+VC4Xtw0LPbphdJ?= =?us-ascii?Q?3bNzK3UfjGJsJaUe94Pz3I72dmda+vMrAgOBV3+kCK3Ir7NXWYWM4Z5B7cmW?= =?us-ascii?Q?KktVKuqydYyu8ofCI8JG00Bin6GUJ6DVQ3/XW5tInXO07iCMCeOYQk7Q1yvy?= =?us-ascii?Q?yA7ss1XO9VXJMIhzv35tbMnhBe38g8hvsCCG4RNRkK6cvaAA0bRht12aIU8n?= =?us-ascii?Q?hYgtNzcBJF+twNEKf4aJPmJhAneazYul4/I0T/ee2bEr7yHb2sKB/lKEG1My?= =?us-ascii?Q?JKpsV1SfCGeIQRQCIcwTo9gP9HSmGuSK5Z1YgDFEID82p3FuFRU81V72hfLY?= =?us-ascii?Q?fxijtxgmAki4H9WNmoQefESibVJ3D/nC6DWdXJf//TPiKlqmM253mmO6BHMF?= =?us-ascii?Q?/atxBVj3JRi30/GReZJAbVUdwgjujgPsAzr695xML6BTo7GPetZYHACRm6LC?= =?us-ascii?Q?bf6QHqmjswgnskPnXljwJDXOO8TTd1HwBx5IvvCw1ghJpaowgJpVeWx6LId3?= =?us-ascii?Q?jplJdsojMN3WvpJwU9hPZyVgBErq9V+S6O+5fqaW9asWxqJ7A3QH/YDoX4ii?= =?us-ascii?Q?0qM29z/g16FiRGmtGDVkTLwDMQDdnrGWm0EFRX36/bEa/D5mfFtm1gsxQwTn?= =?us-ascii?Q?JcBu4DdxLap/r0P+j4+f+FNj37ozioFXnspcd+HESfPS+JwrAV4txlnFKFGu?= =?us-ascii?Q?nWkQcN8ULNVB5VAmU7zwW2ZEDthlPshegt3g/CwV+var5920wxOV11R9Mqco?= =?us-ascii?Q?orltyV+bcpZIbyHxIXsuo3aM6SFUOgWmc+BqQq5poD2Ovzp8DRGkC3qlDYqE?= =?us-ascii?Q?AYLM7dU=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DBBPR03MB5399.eurprd03.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(52116014)(376014)(366016)(1800799024)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?E7OmlWhD5NBrdnwifp1b/Iirn0IHrXlwxnqoqWxRae0cJQon5YeEUTHAaZvk?= =?us-ascii?Q?aIRTl9P8Wz0NF4kl1UAIMH3tAcdNqMHJpgpOc75C/PnOVlZo50XFegNS7+B7?= =?us-ascii?Q?vpAbKDG+4F/vtyeYFOgJrbTR0Nk1SojZRSEXKCfSGJoJcWXV/TxzLyRxCztL?= =?us-ascii?Q?cK7ls1f/jiOOi0CC11NP/lOz9RISfZAt6CxtQc7abRTT2pGuPQY+a7OJMdsn?= =?us-ascii?Q?xSNxY4bw3UL1dpNa4JFAWum9yhtF5o1vBmLPtSPiLCevSrhPTVc3v0Qi9qN3?= =?us-ascii?Q?/Wh5VHzO0Sc7uS+YQs9t8uMXp323U9DF5u4wEjB1B+YXGr8vlXCQ+bUP7xje?= =?us-ascii?Q?gQhCuNaVw8+guE73dob8ByWn5BQqmNVehP8e29k+uyoOFow/Mkw6NO6XVKJr?= =?us-ascii?Q?BVeB5ynsY5FI56FewHzNipozsu0/T/9YxdGZzL6tng34H+6+kOuwUqAcjo22?= =?us-ascii?Q?xWW7wU0bdVn2fZiLihkIMg+og5+A07y6hv4qDB/9OCt2bNNFb30wWZ1h6C47?= =?us-ascii?Q?fKTa0qQ+dbMDqAUJDZ/MwV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?us-ascii?Q?YsRBYSwQ/slPzyeTWPFBx4pbWtyIhsg4qbgojCPNdDNy+WApDZQwpGkVW5wq?= =?us-ascii?Q?3sAtGgyQjhCr8CjKzyut9yEaUHhmxiWNbU+KcRQ8pYo5nUe0XZAhEuer0us+?= =?us-ascii?Q?BcWEq6QNrD+AqA4w8l/rhWph8HEuMYZHVtAkPo2e?= X-OriginatorOrg: mt.com X-MS-Exchange-CrossTenant-Network-Message-Id: 29257e80-f1e1-43df-b624-08dcfd9b1fa1 X-MS-Exchange-CrossTenant-AuthSource: DBBPR03MB5399.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Nov 2024 13:09:47.2917 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: fb4c0aee-6cd2-482f-a1a5-717e7c02496b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: cS5L4H3bCjXKcxn2b/i17KTgvL1Xf8H8lDfLBVGSCnsXkyaLq1MDymNHgxr7d9binsy/0YhxuZJSW/7M9hw4GQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR03MB8468 Content-Type: text/plain; charset="utf-8" Add missing property 'gpio-activelow' to DT schema. Signed-off-by: Markus Burri --- .../devicetree/bindings/input/gpio-matrix-keypad.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Documentation/devicetree/bindings/input/gpio-matrix-keypad.yam= l b/Documentation/devicetree/bindings/input/gpio-matrix-keypad.yaml index 745652b..9ea66b3 100644 --- a/Documentation/devicetree/bindings/input/gpio-matrix-keypad.yaml +++ b/Documentation/devicetree/bindings/input/gpio-matrix-keypad.yaml @@ -51,6 +51,11 @@ properties: (Legacy property supported: "linux,wakeup") default: false =20 + gpio-activelow: + type: boolean + description: The GPIOs are low active. + default: false + debounce-delay-ms: description: Debounce interval in milliseconds. default: 0 --=20 2.39.5 From nobody Sun Nov 24 12:07:06 2024 Received: from EUR03-VI1-obe.outbound.protection.outlook.com (mail-vi1eur03on2065.outbound.protection.outlook.com [40.107.103.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5523E1D6DBB; Tue, 5 Nov 2024 13:09:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.103.65 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812200; cv=fail; b=j7je/Zoe8Y8THOJuUctJEAqYNvXvNiC1cUlzHKtaIa+U5Ai14/pRyK+4U/yOUkA1w1nsW1z78r/xQskwg/xlpL6je04syPJJQwjEZXHwakF52qj02iiKgiQihr1HswUYSIb6jDuXjR5ADdbAtaHXSTlmIAKAxoWNFglKCg0DPwk= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812200; c=relaxed/simple; bh=hsFSlzAzK+Y37KCdiE2V4fS/I8LptbZxhm8jRpUkzwc=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=hrME/Y0iV/hR4QH+QQjYsyjHbsofSTUw6skjxpaEJm95tWprAIlYVeC56Uu+D/qNnKGChzn1vaDSVly22sssI2nM/3KUccoKMk8E5hsMlyGX3i/lNHAO8Erm8YxCD6WwWwfpuAtGCzE9ruakZuiQcrHeiWxsn2kMuoXFM+B69vc= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com; spf=pass smtp.mailfrom=mt.com; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b=naHcsTpe; arc=fail smtp.client-ip=40.107.103.65 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mt.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b="naHcsTpe" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=JE7MGMI2qGz4OzZkwU8RQqmetnBz2HMBaumudkwMsJJQm9557zfAPppYcz+J9VLjGIbmMjhWssYhVTJfezpnTDUw6hujhm5HSHc85AXrho90zdzb069TOLlKtFwhbwG7NKmHqFKEnrgODoAtjaR3cA7FXVnh74J5yDK3wYr7kB+4nEI1EJPuCaTVCfw8nA8m92cggvnOpZFvQICh1DvJLaaaUQGe3vt2/vv5671yDyFHoey2nkSdUe4FgFkf847o1nZTXg5pCSj2KVCzvX0H3OO2wGcqS41+/4FwUn/0TNRaAXr4uqQdAifVhfbOBVzkS4nFrOJoet2s37BmkRULXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Dm8kwbF8ujtQJ3hks0GazQ+RZH0hifiVhqY1o/rXA5A=; b=QNUsLf/WQwrrR8OQA9M14ZW1WGSdPoGOopQ6tQCv6h6zx7KW+7E23747DSIwtODE1zFfs9LnfT0J9PI5O5/nCE5g6CuM9uVNkXeSlmipXKyN47AOeiU1Qgj64cnAyg0UQ7V/tJKlXuetZ93w4vTl9L0tcDDit4Bu+1SFrWowbGio9+iR9Av/Gnqb0Nrw26X/qpLkPbR7xGIGCwTBx+dJMlMSaezUF7hPq9Md2mSh49RnoQ4+gde9SLc+cyWR5xcGTeK+QoyOvbYCVvgmraUYDNW8ohF9ZaXLgTWIrgsBb5jfHLC2Fnixz2oXtIqBm7VZwW78qdANPeyFX1V2K2/T2Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=mt.com; dmarc=pass action=none header.from=mt.com; dkim=pass header.d=mt.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mt.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Dm8kwbF8ujtQJ3hks0GazQ+RZH0hifiVhqY1o/rXA5A=; b=naHcsTpesVl9udWq9u4nmGIk3d4vYyke4u7zEiVx/qmsy7AqGwXqvvfWuWiMVWbLrlf0wEafe6fCtX6J0F9k/xUUZDd6Gx/W+O4vOxaYsYBPTHpeBABuL8Ykxkv3sthdXV35ahoJSLHhsweVKCYD1/IUA2GUcpkM6slk3y+jxkTRFv0vV9C+/UnoxR+ITNUbEUbZQ5UgFDnDwzyxq2CNmkEBRErQQKQNHWVhexEKGzJfXh5zx71bGtL+f0wlv2Vu5LzD3coGv0XeU2umep4/HDtQztK2uCQ9d2Mm37+FkOuFxoZDBKfvH7Ud/MiIh7LYNHvBJDkI3ep9F1TRQ3h8+A== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=mt.com; Received: from DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) by AS8PR03MB8468.eurprd03.prod.outlook.com (2603:10a6:20b:52e::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8114.30; Tue, 5 Nov 2024 13:09:55 +0000 Received: from DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a]) by DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a%4]) with mapi id 15.20.8114.028; Tue, 5 Nov 2024 13:09:55 +0000 From: Markus Burri To: linux-kernel@vger.kernel.org Cc: Markus Burri , Dmitry Torokhov , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Marek Vasut , linux-input@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v2 5/7] dt-bindings: input: matrix_keypad - add settle time after enable all columns Date: Tue, 5 Nov 2024 14:03:20 +0100 Message-Id: <20241105130322.213623-6-markus.burri@mt.com> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241105130322.213623-1-markus.burri@mt.com> References: <20241031063004.69956-1-markus.burri@mt.com> <20241105130322.213623-1-markus.burri@mt.com> Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: ZR2P278CA0026.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:46::9) To DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DBBPR03MB5399:EE_|AS8PR03MB8468:EE_ X-MS-Office365-Filtering-Correlation-Id: 9e3436e5-e6b6-4a87-d3fc-08dcfd9b243a X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|52116014|376014|366016|1800799024|38350700014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?O7/9GSXv7S8EgawARv5K/31nigflX/j+ni7QIP8jNUMbltu2/Wkxra0A5Fqw?= =?us-ascii?Q?YNYeVGPlFD9MmBAIRDVmhkhI2oSUeGLOevvpMPzwT7tlP1viO/Hf4dhPsNOd?= =?us-ascii?Q?etJ6+XTuHsGEIzQ5DBWVMYzyIQp2f5ESgXSWLKAc001VV3iFcDnUQHqdf+qi?= =?us-ascii?Q?DUt/m7v7DUTVaCGfjQWBEgTXllhtJu6Xlk9hk17CEpccTkihaoOC/d12BBYH?= =?us-ascii?Q?VygILKo30ep5kRiOrfKYnbqIMdo2p5Fpd9apEJICG20RBz+9NRVVcrvU3Hvg?= =?us-ascii?Q?yJ/LtxXaQEApeeFYGUAhkjICaabJEPLs2AQhzUVR+GRu31wvc85OZ0Eb+5ex?= =?us-ascii?Q?yMixE3UxUhQKxkNdEqoWK2ebSP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VdZ?= =?us-ascii?Q?7+dARzbPheS4OliriC2CjYtvSPdspyTyg44jp5ODaef4I+njU4QdsayzBuVc?= =?us-ascii?Q?qu3mt5ZPsoK/04G+kLdlWx/+xKiKLT5aM5UhLh4TIynrPQJZoQueygxdK0i3?= =?us-ascii?Q?OO/4GIQ=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DBBPR03MB5399.eurprd03.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(52116014)(376014)(366016)(1800799024)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?9XUeBsYL+3d/NNs/TcP75HYTVbfKQD/Cb7Ef0d5zNWlP9q2by7owQXpni+e5?= =?us-ascii?Q?ryeA5FDmpkgsc6Eh5JNPiW5UN3DK+BKcKxwjbEuZKiZy2PoKMyklf19ZzPhD?= =?us-ascii?Q?tryQJQxK0a0edFDbJQze5IffjOz8YxpPly5OGR5Q0Fa+JKAyJzWH5T56ne/1?= =?us-ascii?Q?UXlAFz6IW1ljeugKDUROKYFYrcIdX4iwihPLnDrYUYEL0ci+ywbF6Jgauywi?= =?us-ascii?Q?KD8oX9ll4SSFnO0ygVQelZtI/4lZHGJiXNoTNuiaZAOEYsdwDNTiH4R/JmZL?= =?us-ascii?Q?aGEmMQJHma4dGZwXJIzDNo+0VNFteR708sGvnyyZoL/Awgp6yogIjxmNLOG1?= =?us-ascii?Q?VmTTx5P4bSE9C9tPGaH/a4B6je4RdvNQjNH6eT1o3h8O3b1wsI2GjD8H9Yu8?= =?us-ascii?Q?6oeTPYNjRGQjD/by/5Iljonge4v+VZjy7d04NCZs1AMuhHSp75KHwJ7RV1Sv?= =?us-ascii?Q?5esJ+XkLk21MZEKPZZTrViZOg9nhLS0GEgRS8085F3hezyrJASVgsxWLICSU?= =?us-ascii?Q?fYKct/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/GEPTfnjyGzb?= =?us-ascii?Q?ZFI4P9gflDRIs5TeQ/UVprX6ilTmGZ3zQ4w5ddNKUwYy5l5TbNAyUlrfsksH?= =?us-ascii?Q?p653MdE/S7oVP/viqrp0qUzr4QFCYrb+WFOmqQ3Aqy2Te3kM07yI1SWMOMBg?= =?us-ascii?Q?6JgNxtdo8rEJs/CR9GeVf6U7ZbHxUx6IJ6WKbc5s?= X-OriginatorOrg: mt.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9e3436e5-e6b6-4a87-d3fc-08dcfd9b243a X-MS-Exchange-CrossTenant-AuthSource: DBBPR03MB5399.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Nov 2024 13:09:55.0102 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: fb4c0aee-6cd2-482f-a1a5-717e7c02496b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 8jb3KIH/IxdRUIq/TNWiBdONbdWXMhKqgMHbkJoqY+jgJpVDtuCW+UOE5X3Jl0FHp4olIrT84rH17I2UuZUT/g== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR03MB8468 Content-Type: text/plain; charset="utf-8" matrix_keypad with high capacity need a longer settle time after enable all columns. Add optional property to specify the settle time Signed-off-by: Markus Burri --- .../devicetree/bindings/input/gpio-matrix-keypad.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Documentation/devicetree/bindings/input/gpio-matrix-keypad.yam= l b/Documentation/devicetree/bindings/input/gpio-matrix-keypad.yaml index 9ea66b3..0ce89a6 100644 --- a/Documentation/devicetree/bindings/input/gpio-matrix-keypad.yaml +++ b/Documentation/devicetree/bindings/input/gpio-matrix-keypad.yaml @@ -66,6 +66,12 @@ properties: before we can scan keypad after activating column gpio. default: 0 =20 + all-cols-on-delay-us: + description: | + Delay, measured in microseconds, that is needed + after activating all column gpios. + default: 0 + drive-inactive-cols: type: boolean description: | --=20 2.39.5 From nobody Sun Nov 24 12:07:06 2024 Received: from EUR03-VI1-obe.outbound.protection.outlook.com (mail-vi1eur03on2072.outbound.protection.outlook.com [40.107.103.72]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 135461D79B0; Tue, 5 Nov 2024 13:10:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.103.72 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812207; cv=fail; b=mjSGcwlhqIO6FQzgssKAPjVmvaxywOlgKfmnMu1KpE0pPDrDnojuD33DIQ2xjau4iZWGfEypFk+0rvmw+NL5hkPn3UlLYTkHbM+U9ycmupypf/5Ii80aCsHe0FdtVV9QbLyf87Bssm7kpqgcGBhvvtSRctNSNhrJVsn6pCbjXAI= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812207; c=relaxed/simple; bh=HlA+B+bMsb9X0pL9Dak2Dxl2qB3bCXfHS/XszhS7Ci0=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=udJXnk1r7l9sdbXxD8qnUjHV+14nVvAJ/EHwBxnf6cIaHHr02YqplCf5iDD/zUYIiwygazgE5KSzPHdHDsZ1CySTXgI2RVJ/al+XOCUCnXg68AhYhCnAz/PvvjrhbFiVV4fiZhXBII3cAzbiMKUmusbpldqzMLoFHOQYCfRUR00= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com; spf=pass smtp.mailfrom=mt.com; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b=kj45WaKO; arc=fail smtp.client-ip=40.107.103.72 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mt.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b="kj45WaKO" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=gKh5fpaS8Vd6DuSkIsGPNu/E8sK+YfUXdYrl6xUL82PLM786eUfLxB67gAPs79SzX8rfDLtbTU11kLtrJvBvh8qvvYyssKT1+3q8+1h15bm+Y7mEqqo6mAqU+926/1LBnaR6xOERsdJHAVZ/dV9y7eYcmQAg8apFJ6IA6HbH+uPrHlzcpr4IaCHs1a0CskwB1F5LLgR4iS/QYHsrZV0zhREeaolxT6+8hMvZQjXCnu55L2vYQEQxMRMX47hHcxZKBJ7lLyHXLOjoG2fxa+cC3T5+rqVaxj+PUSmIGOOsPXcdgd1j17OTbaTo8v2zgUca5vAzM/tM9H1yy3B1jm4GZg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=pjVRoRtT0K+lfU7ftwM2WRCcaz5bD9GFkcczj9oJ8Rc=; b=MyVS22HBnaB0V/xzbpGBajWD6BBGkqIsf6z8vSzs8s8dk0CDMzHjeEUKJpgCkbb9uoN0QQ6QJ133OdBFB8KuVIcOgSfKGnu39V2jkqVkJNuCYQXAxPz+OLnC+a2sAAS3OsC4yzfSZyesZltyfgJjuMbvRRpvaRnkM+J4v+VDolRMPDT5X4tfwHJ6xqHgGT2iZAvmJ/YQZsrEx4zr5Lf3XzCymVQl4z9+bHWfV/Fm34o2EaU8YRJfrzIMbmtugkn4ZZA3wh7PPI1gkQV0tRGJHS1Eepqg3L9a8P4yR/YOyAdUaF2l6pU1HT9IqikAav6IEn9eG/ZrRAMKXLo3NGYLBA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=mt.com; dmarc=pass action=none header.from=mt.com; dkim=pass header.d=mt.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mt.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=pjVRoRtT0K+lfU7ftwM2WRCcaz5bD9GFkcczj9oJ8Rc=; b=kj45WaKOsaiN737thigcQNeAT1bV8gBTQRKcQrqxk7RQkcy55vKxZgiPdlnHTNzkpf0cLdkBsNvGje1LyUHOPT/Twn/wq1KfFxnQaZDWYUwovXnAfqUiEv0scnxOCBdGkLH7ucVBEmpwJOeZVhan494TdbeQvdyYPVWv0De51ZpmmkGpz2D3m3u4XuCEMwKiFEMVJ986F8BcdHBi9ExExDNzC+1vha6s9Wkk4GZjufmqAdGvUZmp5AOoqvBTNuoZfaHDi7GgUTV0xbQEutGRzR8HOY0M3thakngyfQ6F8a9+ISKdtgtZW3qm0rA239/9ZgaEIylSe4PeSKtKQFAwRQ== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=mt.com; Received: from DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) by AS8PR03MB8468.eurprd03.prod.outlook.com (2603:10a6:20b:52e::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8114.30; Tue, 5 Nov 2024 13:10:02 +0000 Received: from DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a]) by DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a%4]) with mapi id 15.20.8114.028; Tue, 5 Nov 2024 13:10:02 +0000 From: Markus Burri To: linux-kernel@vger.kernel.org Cc: Markus Burri , Dmitry Torokhov , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Marek Vasut , linux-input@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v2 6/7] Input: matrix_keypad - add settle time after enable all columns Date: Tue, 5 Nov 2024 14:03:21 +0100 Message-Id: <20241105130322.213623-7-markus.burri@mt.com> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241105130322.213623-1-markus.burri@mt.com> References: <20241031063004.69956-1-markus.burri@mt.com> <20241105130322.213623-1-markus.burri@mt.com> Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: ZR0P278CA0080.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:22::13) To DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DBBPR03MB5399:EE_|AS8PR03MB8468:EE_ X-MS-Office365-Filtering-Correlation-Id: 29950423-6a00-47ef-81d2-08dcfd9b28dc X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|52116014|376014|366016|1800799024|38350700014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?PKrdB1iU6bYgq0rUjXR0uZQ6LZd16onv6+JC5zZCCJMglIqtol9aT4LIcWN9?= =?us-ascii?Q?P5aiBny9ABx0MQjFsx4KD16L+B1Vk58eDcCPcAChM0R4DP6/sij67/tMw2tf?= =?us-ascii?Q?TsYThr3nq3iqiiSZzaLv4fg7JJCEaDmthYT5LowOCk67mtUrYAnNl70karm7?= =?us-ascii?Q?p2CwLGgyLCssDQaoGvPrhsvkIYMw8VacjFOthl7t9dmRvQRHC+npsKWADeP4?= =?us-ascii?Q?8YLMiUv+66hWitXzrOcF4xPZiYr35vDhdjBe7nbaokxhcVr0bE81R7zlVlEf?= =?us-ascii?Q?qzoJSlEtLqBoJtnMsYkN8CTUqhxc6/9w8QS8CDp1TXSjuYhXBpfo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qnjj9fL5CFijjgD7D0EN7IgdC?= =?us-ascii?Q?2nK8rnna9rspwroukd9ubFC+jLqscoBYM2UhiWpfaGTpzN1fOP/a4smV0RTK?= =?us-ascii?Q?YPZ330P4teITc7bfD8CAfmgSssnpiQN92JW/QjOeMxKQiHqiJrSZPv/iICTH?= =?us-ascii?Q?CJhHxag=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DBBPR03MB5399.eurprd03.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(52116014)(376014)(366016)(1800799024)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?pfhU8neAxY65EyQktgnD4m0Vy71WCnt3t/oU6aaa3txHwiau1NZcosHp2Nen?= =?us-ascii?Q?1diuaMB2bjcc4ADVEFRLu+kPV++Wey+S8EO2DZr1pjcKA14miy7XnmulIqa5?= =?us-ascii?Q?CfiOg4wCPexLA7Bt5hjC6zWtXvBHp+f3eFwnCjNWYEutXCF1XnPF8IOedHAj?= =?us-ascii?Q?ZjS5qLOOyBkVyI3pL9++ObbzDpySE1wL51UJ7lqUkBkx6ggxbw58rEcBG0D0?= =?us-ascii?Q?eer1YmYmCbit6VcCERnsaBUt7aMcvVPqNTbbs4KGNYXpwRczBn2RON6hPaHV?= =?us-ascii?Q?z7k4Cz4lT0Z8nbcgcWYJcCQL8+OtSDDZx92cM7ESgPOTmiqg4YGsOi/GI9ah?= =?us-ascii?Q?Em4nuLx6JEyNt+gOQmRak7KaoQiaC1eqKXKhxrzgs8zUGawZPls89TiViYZ3?= =?us-ascii?Q?tqG0VgwMDtbcyxQmwkb8x7y9uMyTBOh+KNPNKk3SL1pPhsZ3JYD4KnUK4qxL?= =?us-ascii?Q?ZgU8sQQlnHLoiXHDgxL0JVjZp02QRxqiuS36PYfYw5J9z+Vue49VDhUwbq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4CY079JY9s8K0wnx0pb1+95cqbmtFta1ZREqQ/3sHqtGQo4?= =?us-ascii?Q?eJ3tEtu8xhqG+ZKIiMcEZTtvqk62fQQYa2qoWKlvdHyCIPq8XYMX6ZpE/PUE?= =?us-ascii?Q?WSIQhyVRhZo4Usx+0MBLGalKOMXhMDRzB/yVbknWa+ZOqrxam6XfQf99Yl76?= =?us-ascii?Q?y7JnnKMDR77CWntBtO7n4rDgY4bLQskNlrF8scFT?= X-OriginatorOrg: mt.com X-MS-Exchange-CrossTenant-Network-Message-Id: 29950423-6a00-47ef-81d2-08dcfd9b28dc X-MS-Exchange-CrossTenant-AuthSource: DBBPR03MB5399.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Nov 2024 13:10:02.7876 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: fb4c0aee-6cd2-482f-a1a5-717e7c02496b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: xHoQzObrLOJFGrLUP9NQBFhsOLx0SB8P/aLqgvwDjZ7DHBPNXvJribDQRXJ/qolezGUPklh7ju9tQVOSE+07sg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR03MB8468 Content-Type: text/plain; charset="utf-8" Matrix_keypad with high capacity need a longer settle time after enable all columns and re-enabling interrupts. This to give time stable the system and not generate interrupts. Add a new optional device-tree property to configure the time before enabling interrupts after disable all columns. The default is no delay. Signed-off-by: Markus Burri --- drivers/input/keyboard/matrix_keypad.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/input/keyboard/matrix_keypad.c b/drivers/input/keyboar= d/matrix_keypad.c index 2818915..46873b8 100644 --- a/drivers/input/keyboard/matrix_keypad.c +++ b/drivers/input/keyboard/matrix_keypad.c @@ -27,6 +27,7 @@ struct matrix_keypad { unsigned int row_shift; =20 unsigned int col_scan_delay_us; + unsigned int all_cols_on_delay_us; /* key debounce interval in milli-second */ unsigned int debounce_ms; bool drive_inactive_cols; @@ -78,6 +79,9 @@ static void activate_all_cols(struct matrix_keypad *keypa= d, bool on) =20 for (col =3D 0; col < keypad->num_col_gpios; col++) __activate_col(keypad, col, on); + + if (on && keypad->all_cols_on_delay_us) + fsleep(keypad->all_cols_on_delay_us); } =20 static bool row_asserted(struct matrix_keypad *keypad, int row) @@ -403,6 +407,8 @@ static int matrix_keypad_probe(struct platform_device *= pdev) &keypad->debounce_ms); device_property_read_u32(&pdev->dev, "col-scan-delay-us", &keypad->col_scan_delay_us); + device_property_read_u32(&pdev->dev, "all-cols-on-delay-us", + &keypad->all_cols_on_delay_us); =20 err =3D matrix_keypad_init_gpio(pdev, keypad); if (err) --=20 2.39.5 From nobody Sun Nov 24 12:07:06 2024 Received: from EUR03-VI1-obe.outbound.protection.outlook.com (mail-vi1eur03on2050.outbound.protection.outlook.com [40.107.103.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 880B81D63E8; Tue, 5 Nov 2024 13:10:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.103.50 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812218; cv=fail; b=jc+S4Pz9ITe7zyOFnviLBWHY8KoAOWJBg5kJLAkyO2wcZLrsCYpXWhNTcvEBq9e3RRMQBQCz1Khca98zrGmyT/Wlz6xTUb8d2EI2KXlw0W150TRpd+90k9o0ExbhrfnfGwm0UuM7xyP4SA/JualR0QnJ+Uw5rszY1rAePKu9yDA= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730812218; c=relaxed/simple; bh=dS0EPvrlKmpyuZD95c7kn0I5Qj6u/+zLwSdT5HG9YeQ=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: Content-Type:MIME-Version; b=CrFX//01NrERX2bWhM2mM3doawcuWblWfgdO8I7ZCq7jzioifXoiAhvwPGDS0SU9CYAUbGrf/V59jyZcJOJqnFOQKQOE2B/hGkuGDF6pY2GOcR7qDLVyR3/+lBAHtUecdCs0PkjYCCeCYR7aBV6GdX5sT3+W9BjSznqRndADhgQ= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com; spf=pass smtp.mailfrom=mt.com; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b=lDKFoiNv; arc=fail smtp.client-ip=40.107.103.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=mt.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mt.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=mt.com header.i=@mt.com header.b="lDKFoiNv" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=jgGDEym0MEHaplfMVRhs3kQjEJIsqC5jdEhyXAxv3iSCzHErUcm3aeDGTyYxW65cpGCvazmqCaawrlyT2CjhBnvJOuZ+f7T3s6BRAnebgKZsmIzb8z4k/jQlKk6n3LlH+PM8x1dMXvXMyWpCnl0s1Y4fOhMEE47YLejE0DSgGPZE9LrELbqKK3coHgdGLYSO612hgwhJiLMQJBeJzDirj2LNoU3UT5okGlLct+PGjhNkOAzLNO40syUFqMUY03iqXx59hNt60zS4G/X7GM4Rf5YhbbUulJKwSk4O/q9yS3U+RA8RvGZfY2wdpe37mB9u1djpxD4Sii6zlxu9A7s00w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=3cQ0GlwCUa1Pyu+/7QMAItAu+fgfDkTFS0ht19uK+x8=; b=yuwLboJ9/r5AgNvIH85z6NGMeoduEzI9Er//1GUm3qNdPoj2dCO8j0akcPZtXDFEo23ecy7Tv8kGk7vPOuIzI+3bYkV5qYmVZ7poxEYJ2w77JYS2iWCqpKNXKCmFtU8QZa4aaYU8fM1y9pEkFIYZgyLN4pund4xeCNPY9h4ZpDkd/Onx8Y8Bd4eXxLEzMTCFhrNAdKOcJcHu7BoyE1IelwGo6yRVasboIKLrV6pU3f67D6GUfbOVcP9RRkhmlng/IuU0WBamD/WecI9zBHFDdAoErPtFirYyO7Iz60M+PFtaXV8ep4u2MkfeWazeMwC3W+LyfZOstguHEvLWEkMj5w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=mt.com; dmarc=pass action=none header.from=mt.com; dkim=pass header.d=mt.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mt.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=3cQ0GlwCUa1Pyu+/7QMAItAu+fgfDkTFS0ht19uK+x8=; b=lDKFoiNv0NA6R+UuI3BiwUR+mawvnsglrlp67vxd7jJYzCFgD7ZJllUl4Dnsn9kD7QluGGEMHwlYLEFD7MTAcyBXbcDU3MJDQir9lISoRe0gZ6YORRs2GyYsHCYYZxa5iuGQuI5MMCZMYUsSn4eOwS9Ebb04rXlSYEBAHEvcoEo+2gCspM+nrxsdCD7MRsc4lxUWcTi9dZL0RmU0hSjutGX/xZffe28uhJ/ueGGYXvtExSsAkxvqpS05Y3RwtdmmKAWAjC3VE48EZYaGhHTTPIInmpwK+xQhbo6BtyCWEW9sm5u4GTpuxSsgbsGIwX4Z/TCEKL/6uwtcX4qyrtrmCQ== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=mt.com; Received: from DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) by AS8PR03MB8468.eurprd03.prod.outlook.com (2603:10a6:20b:52e::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8114.30; Tue, 5 Nov 2024 13:10:13 +0000 Received: from DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a]) by DBBPR03MB5399.eurprd03.prod.outlook.com ([fe80::2fec:64f5:1893:f53a%4]) with mapi id 15.20.8114.028; Tue, 5 Nov 2024 13:10:13 +0000 From: Markus Burri To: linux-kernel@vger.kernel.org Cc: Markus Burri , Dmitry Torokhov , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Marek Vasut , linux-input@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH v2 7/7] Input: matrix_keypad - detect change during scan Date: Tue, 5 Nov 2024 14:03:22 +0100 Message-Id: <20241105130322.213623-8-markus.burri@mt.com> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241105130322.213623-1-markus.burri@mt.com> References: <20241031063004.69956-1-markus.burri@mt.com> <20241105130322.213623-1-markus.burri@mt.com> Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: ZR0P278CA0022.CHEP278.PROD.OUTLOOK.COM (2603:10a6:910:1c::9) To DBBPR03MB5399.eurprd03.prod.outlook.com (2603:10a6:10:f5::22) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DBBPR03MB5399:EE_|AS8PR03MB8468:EE_ X-MS-Office365-Filtering-Correlation-Id: 23c0c6e7-0da2-4827-810a-08dcfd9b2f24 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|52116014|376014|366016|1800799024|38350700014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?ICH0sQE0BQikQxcLfG8p2KOAlbwGHwlukeWbfXR4K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ObuQPFCdiwUHtbV7+8CuXpUgfJVNIP144yqW6nCqAp2jRz5KCqZcTY2F?= =?us-ascii?Q?z9GGA9S0TGQj3QmvXq4tvKJQtQmJRN4s2g1/V0qVr+ZY5R/nbvPcS5SK4LjC?= =?us-ascii?Q?Oi8ispofGLpEIqHaFeKy+SPGqVQwhYHhBPGaRBkJnoeMZQzxWh0y3OGX3fY6?= =?us-ascii?Q?SejuYdK2J7RqRpbNbN1/nz2sNPPpPg8UwjmMNzmLp+Jri0ebbZxAt6VkxaCg?= =?us-ascii?Q?xG6T7RPkBFd5Xb9XsJ/yHv8g+rGmRNJixIpRTqbGydp3KkVg/V1nXDbeOiqa?= =?us-ascii?Q?p2ndi88HLow1jg1E9RDJsIe045ozHHZT28Jf599JgNW3Y7rAncu2Z2lM5OiA?= =?us-ascii?Q?6Z/TlKdJg7OMLfVOfLHFC5U20X9R0o+tO8hprzpYbd2hKekX3GrkN3hVzb/p?= =?us-ascii?Q?MdJkT+oDtJ2v+BCxc3ii1WshewIMZpSliEqH+dsoBAANsDD/i9Y/Naw2w5Os?= =?us-ascii?Q?w8zPN5w=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DBBPR03MB5399.eurprd03.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(52116014)(376014)(366016)(1800799024)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?IaQAChT+oA8TNfz1Hkka4TrIvRwb0G4Ni3ely7A6puEv0e6v3G3aPdWUlb+U?= =?us-ascii?Q?EropenZjXWUZ1DZGtj5xlxi8/ozTdj2+ZCYsmg8Isva/a1JNp85yPOSxScWF?= =?us-ascii?Q?JmE4jd2VXLZORJqkG3OGO9R/jEScn9wmjvolPD3Hijyb5+AdUD2MjZFTDDHD?= =?us-ascii?Q?9RrXFjLNoMZ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= =?us-ascii?Q?c7sV0kDC5Q8VQeiKbj1+5onzc5bNa3ygK/YLNlAAqhaJItR6/9DwZhkWpnki?= =?us-ascii?Q?6V1vVbL/R3qqFND2TOJ73ocb+dDTblew5yQbV2fXFKygcuCPQ4yyL4fC34Az?= =?us-ascii?Q?dbPxeThXBXnS12svVp+TKh7HdHWV9IhdH82+mVHDty+capFV/2wGNDGxF44s?= =?us-ascii?Q?58uaX67pmXd6+tSqlQXIYZ2pZ8cdsn/ESh9QrMXE5aaGj+Hg1PDn7ERTfQp+?= =?us-ascii?Q?p0CGbjMgxowCWnzbbdZJqSwKIa+OsJmJgJz3Z/9PkVYl/wDrB8QSIun6MWov?= =?us-ascii?Q?T/aS6Bti8/7lQTRkBvGJ1gkE9MYLuA9UYHVLYIXP+q0wXPrexpq4yDuovQek?= =?us-ascii?Q?zE/SwIl8gVJRqv7/YIjX7GNKpwTQ/tNsW7LiJxCN4oR/jAaYsDx449mo8zp8?= =?us-ascii?Q?5dhZyJrFb8Ah+OGRgkc+JRQ9QBq5UuPDKNo/NmogBRTXFd+73KZ9VMvNERPB?= =?us-ascii?Q?Ja8dmK/I0GVqtlNLgTwiBlkm/wttrOrp1st81Uo0?= X-OriginatorOrg: mt.com X-MS-Exchange-CrossTenant-Network-Message-Id: 23c0c6e7-0da2-4827-810a-08dcfd9b2f24 X-MS-Exchange-CrossTenant-AuthSource: DBBPR03MB5399.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Nov 2024 13:10:13.3134 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: fb4c0aee-6cd2-482f-a1a5-717e7c02496b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: cgpl7a5KV6jWg37qzmOxYGKWa9BuoPSqaUlBN+axYJ0YLkzTEI1ii6SA+crOH9dhQQHeZ7bPCb6eZUWyK+5cmg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR03MB8468 Content-Type: text/plain; charset="utf-8" For a setup where the matrix keypad is connected over a slow interface (e.g. a gpio-expansion over i2c), the scan can take a longer time to read. Interrupts need to be disabled during scan. And therefore changes in this period are not detected. To improve this situation, scan the matrix again if the row state changed during interrupts disabled. Signed-off-by: Markus Burri --- drivers/input/keyboard/matrix_keypad.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/drivers/input/keyboard/matrix_keypad.c b/drivers/input/keyboar= d/matrix_keypad.c index 46873b8..93c8404 100644 --- a/drivers/input/keyboard/matrix_keypad.c +++ b/drivers/input/keyboard/matrix_keypad.c @@ -126,6 +126,10 @@ static void matrix_keypad_scan(struct work_struct *wor= k) const unsigned short *keycodes =3D input_dev->keycode; uint32_t new_state[MATRIX_MAX_COLS]; int row, col, code; + u32 init_row_state, new_row_state; + + /* read initial row state to detect changes between scan */ + init_row_state =3D read_row_state(keypad); =20 /* de-activate all columns for scanning */ activate_all_cols(keypad, false); @@ -174,6 +178,19 @@ static void matrix_keypad_scan(struct work_struct *wor= k) keypad->scan_pending =3D false; enable_row_irqs(keypad); spin_unlock_irq(&keypad->lock); + + /* read new row state and detect if value has changed */ + new_row_state =3D read_row_state(keypad); + if (init_row_state !=3D new_row_state) { + spin_lock_irq(&keypad->lock); + if (likely(!keypad->scan_pending && !keypad->stopped)) { + disable_row_irqs(keypad); + keypad->scan_pending =3D true; + schedule_delayed_work(&keypad->work, + msecs_to_jiffies(keypad->debounce_ms)); + } + spin_unlock_irq(&keypad->lock); + } } =20 static irqreturn_t matrix_keypad_interrupt(int irq, void *id) --=20 2.39.5