From patchwork Fri Jul 12 17:06:39 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frank Li X-Patchwork-Id: 13732037 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7A990C3DA45 for ; Fri, 12 Jul 2024 17:07:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=iEWNgN6jYQgtRA5i7pqykO6Km9ImwtgBsbEby5DOK+E=; b=cAYgho9w/LyaI0 is2DvKWQaQYJVfmdPZdhpPlIxFG529vqJHxfHrYga2xxH7D1AB/upM7oJc2tQ8GhP6UZir1u97q4v PKXRihrG/tCyHAOvpGiJ2lxnmUnDeZpulFihCfZZUH2U2iw52SvVdN4kjak0WXzqR4faNOXpm/ZUX 4mRr2t/pO7Q5+1CCxb6ECWIUB4grw4bXTqcggO9jzKGyItup1CTRot0dGzueYPeJdy77kQaQQN56k Ck+1BF+I5bZ99YYhz1SuE2Og2+k3Slt0N/diu93oN1jiFreTV9x0G4CX9U8t3IqczFcNW4hp9RtQT ytsJg78QJ4KpKRjEPhpA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sSJjf-00000000mmO-0glU; Fri, 12 Jul 2024 17:07:07 +0000 Received: from mail-northeuropeazlp170120003.outbound.protection.outlook.com ([2a01:111:f403:c200::3] helo=DU2PR03CU002.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sSJjb-00000000mkU-3q7Q for linux-i3c@lists.infradead.org; Fri, 12 Jul 2024 17:07:05 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=ggzjpdknmvSgMmVzSpuyeQE5gAHkleRcwefuHOWZe42OQER8qH+kL2WbAec4ky8hE66tD5GfHRc+/lajsBn8nJImvzOSqasWmE+njArzEWhO8XJKpjFPqF6yPunymkVsdn7sIWkrrv+C3jysztK4dbVn2v5j8kyc5Y+19oCTEN7Z+ULMGPFxDKDZQTivkPi9R9usPrywixPythJtU7GCoIwcTXEwZAWRNzuSYxS4ma7t0jXZaQzItfTpvCKQd2EQ9TGt5c96czbMoEIlWJjK2wBLx1PmUUZZiiiUgHjkJjIyxQdd0miwHyCqIuZY+SI19lpA7XFeRc/v8836Bx5a3A== 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=NjPUtpkxr34CmDx7g7lN7HugJ8CCI+KKQ4XXqJDkjQE=; b=s7kpWv1aW7s9Q+AsQyhGkO2DbdO6fpOLBKBbSwfN/F3CTrS2qOMdFFIpYnhcCBrb4ruRIciScGYjTSuy6L/CguoCucxN+Fnrkh7Td3GmFmgKceTC2hl/s/GSrfwOmedEVYzOZ5r1KhJrLfkwMx7G82qHhuiGeXkJscYWzfSi28rqrNYlWjfpbg201jnNpaMosibOof9RpUqYM2Li30AzAXNoNCo83FDOsE53bjhUqYTMHy0zB0I5/vLr2zoGqZMNQdn8Wc440kyzer8vxejI9zWrpl1tso8AzPoarFGVriTIXnc6MY8wlpmc0ne5qo24iDdoYPRwXd9+LNOVMhaHJQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=NjPUtpkxr34CmDx7g7lN7HugJ8CCI+KKQ4XXqJDkjQE=; b=iX1a6xm3GlGZfnw/0kIEAPgtPMWEJkmXv9rH9cGzboaMhKRy6ZvssH516Ud7rwSCBOoyEK4cgx9SZrve+gpIRfQUK/ni/1e2XNiqGvZnU0r+kHBuWgs6Jj7L0zb7+cv33/46RLoCaaqlCnIxR98uT01IKlgWkjgvoGohxvZJWAg= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from PAXPR04MB9642.eurprd04.prod.outlook.com (2603:10a6:102:240::14) by VI2PR04MB11075.eurprd04.prod.outlook.com (2603:10a6:800:27a::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7762.23; Fri, 12 Jul 2024 17:06:59 +0000 Received: from PAXPR04MB9642.eurprd04.prod.outlook.com ([fe80::9126:a61e:341d:4b06]) by PAXPR04MB9642.eurprd04.prod.outlook.com ([fe80::9126:a61e:341d:4b06%4]) with mapi id 15.20.7762.020; Fri, 12 Jul 2024 17:06:59 +0000 From: Frank Li To: Alexandre Belloni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Miquel Raynal , linux-i3c@lists.infradead.org (moderated list:I3C SUBSYSTEM), devicetree@vger.kernel.org (open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS), linux-kernel@vger.kernel.org (open list) Cc: imx@lists.linux.dev Subject: [PATCH 1/1] dt-bindings: i3c: add header for generic I3C flags Date: Fri, 12 Jul 2024 13:06:39 -0400 Message-Id: <20240712170640.3635096-1-Frank.Li@nxp.com> X-Mailer: git-send-email 2.34.1 X-ClientProxiedBy: SJ0PR13CA0045.namprd13.prod.outlook.com (2603:10b6:a03:2c2::20) To PAXPR04MB9642.eurprd04.prod.outlook.com (2603:10a6:102:240::14) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PAXPR04MB9642:EE_|VI2PR04MB11075:EE_ X-MS-Office365-Filtering-Correlation-Id: a8f6fc23-463e-4a29-079d-08dca2950af0 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|366016|376014|52116014|38350700014; X-Microsoft-Antispam-Message-Info: g+tb+1Png+sJ7S5oW3n7Yl4uVM2hmbNizoMSEAXyfn1g5wYtQf1lDp2N4Tw/pLMla0z1WRdkhuuBMzv26O4CGZ315l4Xqkk6EBesgjNKkZVnwkhz5cU7sGQYv+lbfLqhBTUFlf3zcZHcvv3WILcdQaM7JQD0gvRzoG6LSu3mC68PdG3ZCmPOnXlqqqMxrIK1aIjNQAPU+EPKxrhbm5YxSOUZY2thgHYNZPAb0IqLYdPVDXSnwEAXIP9PTFuUeJhg90eDX80+0tR/L0XJ0GZhohuhx9rgMpbNkM1+O7w8zbi4MaZEzvmrDVnRxsIZrYB6CxaxdZI7ozlSxIix6SGAL30TCZJ9BRBTwcsav4nuhxtCU7D1LbWa5Z6gUOPyhjzZo4l81biDgD9H1+gjtbnvwv72ols4hNg/UXvEXPwVFEnmuK6SNUKiIbBtv4MP95kZWU5YatYcQ5uk3EMhWQVqIsaT5INqSu6t80Wl2Mq6d/gBgCJyUZZECqoJ5fTO5NCJUtOUMeTlt+Fj82omazJ1d+FPBs7Z9W+6NG77W+APWUEwhxQT8wkwgUFxFSp9hBUy9vT2d4dCoDiKn0yYyreRz7CFVfXGNNksDJsaiIJ7oKJNt6+6KwcJ/BNdrut42vxEac0awgLT6YPahxZcKYGsm0nqur7qkq+3qUVHgC4Dkrfjg/VaP1+xJjXsuHNxwpvXB3h/AeEiEi4ZjU5nQfDA/tV4FdO5hYolDzWib+I0Dv5fKv8vdil3Ue2Ffnyk3L29MguTiijssXfDLqYTblyqprNtqUFmhwr9L4KAnYYriIwwlwySK26EHBzkSsh6TD3u+bDTTQ764Xy8PIwBkbUdG+6Lhzmsdjq72VFEtVfJl4isy8wl6vAMnBXnJBc207s3ijniNSkOF1OCrWHw12y9kq1l2Od1wD1bWyiNan9Ji5gXQXW3SU2WAoKvDdlXDEqoT++22kCY/ktGpHrzaWO0WyCzf/y/ueHUj50Bk2K4SYR7XEQv4/nqb/inM5+tRoB1LS7vlIPYSYKHbMuhApdChF8sk9auTTuTKbhrJQSRdpTeK4x1WHQtiarLWNZhq1EgCHBnI6/yjeHZVoBWZEKiJIK9xuAxu4CU9a54+A5HfR1OD5EH4Z9jEz4Aeo95wNLAIsSph2AJ/PkenUI9JAthZxi/kWo9xX1AbIp63BuKfbzU5lrTkkGRGZVzDI3+0vrIJQyZ2KmAtxC+yJQYOMwhQFqKmCj71fRTbZHM52wBr+uPEFvoqd4N+9rPyH2Wi1Fh2070mG+IKGR8T445pnPnHiFqns/HfD2ur7sEvoMMP3aoC7p0qCXOneXX+ToWLB2BczuSDDUB5734OGO4pDsANCb5VIK5NfHpsOQDaPo1pXRAqtvgmMJ8uA6dfKP/S/GojzJlDxhjIiVV3hQEa/kRmQ== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PAXPR04MB9642.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(1800799024)(366016)(376014)(52116014)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 0lrRtsIa+1QxBzydWfbx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udC10VPh6z5zS09KIF31pt5YC+pjW8FuVDROzHOKuTkVN+/3IdmrN+Axqs5bR2vTQB/5Ehbv63lS0KUcFrAOoa5QzOyxpU+w6RbeiArqAJjqod9hQHYPiAWzUPcR8/4CIMU8uPizgEcqnVvb8cdo9h2jxxvhyodJO8kx7IHfS88VGslYawdMXKirvPLFLXzE98stUNugydFba/s1VtqoIxHOups+GvuGrsqjfCqoc1GqWDYi7ey7d5c3pqxNi6Je5shm64JIWqiJWDif3gjab41BSgmZM2q/uauNaj0Ck0ACj6Lv9AIM0tHIuAh2xOwLEC9Jj9EdpQcCBISsJsP1cx27sB7+8GKDQLSVLmeCkhBP3A7cQbkVPE2Gq7l+aSrfGXtuyilVL9X1I36hYNScKd+UcpV17SXqA7F+0QdjEmy8c+mtuv1B5UkwHmC7oolJB8hyY8KnJ6meSI9Clbq6YKyCPu8KHobDh6yMXFL0saL X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: a8f6fc23-463e-4a29-079d-08dca2950af0 X-MS-Exchange-CrossTenant-AuthSource: PAXPR04MB9642.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 Jul 2024 17:06:59.8413 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: ld/IV6ZigF7GILgiIHJUdfLPQ2s87XALZCVpFPtnRcqRJuEMN/s0QAnpraKmmcGl8xDY1a1u0g9EBLJC/BvQSA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI2PR04MB11075 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240712_100703_983441_33FC82F7 X-CRM114-Status: GOOD ( 13.34 ) X-BeenThere: linux-i3c@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-i3c" Errors-To: linux-i3c-bounces+linux-i3c=archiver.kernel.org@lists.infradead.org From: Carlos Song Add header file for generic I3C flags to avoid hard code in dts file. Signed-off-by: Carlos Song Reviewed-by: Frank Li Acked-by: Jason Liu Signed-off-by: Frank Li --- Documentation/devicetree/bindings/i3c/i3c.yaml | 5 ++++- MAINTAINERS | 1 + include/dt-bindings/i3c/i3c.h | 16 ++++++++++++++++ 3 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 include/dt-bindings/i3c/i3c.h diff --git a/Documentation/devicetree/bindings/i3c/i3c.yaml b/Documentation/devicetree/bindings/i3c/i3c.yaml index 113957ebe9f1d..90f3610725185 100644 --- a/Documentation/devicetree/bindings/i3c/i3c.yaml +++ b/Documentation/devicetree/bindings/i3c/i3c.yaml @@ -91,6 +91,7 @@ patternProperties: - const: 0 - description: | Shall encode the I3C LVR (Legacy Virtual Register): + See dt-bindings/i3c/i3c.h bit[31:8]: unused/ignored bit[7:5]: I2C device index. Possible values: * 0: I2C device has a 50 ns spike filter @@ -153,6 +154,8 @@ additionalProperties: true examples: - | + #include + i3c@d040000 { compatible = "cdns,i3c-master"; clocks = <&coreclock>, <&i3csysclock>; @@ -166,7 +169,7 @@ examples: /* I2C device. */ eeprom@57 { compatible = "atmel,24c01"; - reg = <0x57 0x0 0x10>; + reg = <0x57 0x0 (I2C_FM | I2C_FILTER)>; pagesize = <0x8>; }; diff --git a/MAINTAINERS b/MAINTAINERS index 3c4fdf74a3f9d..f0ce22e04d467 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -10479,6 +10479,7 @@ F: Documentation/ABI/testing/sysfs-bus-i3c F: Documentation/devicetree/bindings/i3c/ F: Documentation/driver-api/i3c F: drivers/i3c/ +F: include/dt-bindings/i3c/ F: include/linux/i3c/ IBM Operation Panel Input Driver diff --git a/include/dt-bindings/i3c/i3c.h b/include/dt-bindings/i3c/i3c.h new file mode 100644 index 0000000000000..2513947e70cd2 --- /dev/null +++ b/include/dt-bindings/i3c/i3c.h @@ -0,0 +1,16 @@ +/* SPDX-License-Identifier: GPL-2.0-only OR MIT */ +/* + * Copyright 2024 NXP + */ + +#ifndef _DT_BINDINGS_I3C_I3C_H +#define _DT_BINDINGS_I3C_I3C_H + +#define I2C_FM (1 << 4) +#define I2C_FM_PLUS (0 << 4) + +#define I2C_FILTER (0 << 5) +#define I2C_NO_FILTER_HIGH_FREQUENCY (1 << 5) +#define I2C_NO_FILTER_LOW_FREQUENCY (2 << 5) + +#endif