From patchwork Wed Feb 1 06:47:14 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= X-Patchwork-Id: 51187 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:2388:b0:96:219d:e725 with SMTP id i8csp228825dyf; Tue, 31 Jan 2023 22:55:33 -0800 (PST) X-Google-Smtp-Source: AK7set9TiqG7stILhwcAsS86HyG6k2jBqUd8uN08wYoFv1sa6/27v4ZC+TMtjAx39xaFLbHFzXev X-Received: by 2002:a17:902:f28a:b0:196:6577:5a8e with SMTP id k10-20020a170902f28a00b0019665775a8emr1361492plc.39.1675234533614; Tue, 31 Jan 2023 22:55:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1675234533; cv=none; d=google.com; s=arc-20160816; b=MbsJHLwwvZ//A1yeyXxFbxK4aI/CJGvn09Lsy8wASWStbI66d3Lf+Zw0VNHWikni7P ukoCIsUZcHp2WYEAIxwWqnZZh1lwt7EHPo0241Qb2Z6/Seax3hax9cBSbw57FUj5doQ5 H8ah+6gcMZYIGgIScSggQHztmc+8L8djbX6qUDWNX1p1X8/A4uYcMJJmJh65PGs94KiK wXKRRSudrx53Dt6+48DYbkGaZTOk4oa2z9YHr8dDwII+6XtHvUo6IDoou1VRaC1jkt5X QtngYmWXyAJPgY5j6SisR5tyjpMOPn7FVoMvulOSlnrDztcIa2193bRn30C67Ff9GGfF 345w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=rkN86TIGDYJR+4nG2fHZ23r9O15jnUv5Y7OgjldbOWg=; b=KGaB98MXPvq3Uqn0JB4ChZrQ+qRQ+slPlf2lUr5nmqY4nSIK0PcShAnsCLB+TNd+06 jZu3i6930sU3di4kpYv1NdyT4vdqc4wHoHHvAj5btf4YpwU3L1SGZOWQS6C9MVqELdKV U5z7VNlItTEGsrN+D+EOV3/CudfPtcIicLK6G6FIM+8cLPlWFfsBeUd6qXP3pm6klA40 gWo2bD7nwnoXveh8s5mkWZe/SiMR8w80RPPbnquz64zSIgRuJ9RBQgC8vXGXihk70TwP TA82ksJPQxl1V+hJQ20A4obUsVKtIJ8qlvbcePrZN65ICCEeq/YJLkYQ2g/nqXFGObmf 0s7g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=XQIBijkI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x12-20020a1709028ecc00b00194dd9cb062si16738677plo.396.2023.01.31.22.55.21; Tue, 31 Jan 2023 22:55:33 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=XQIBijkI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231478AbjBAGwk (ORCPT + 99 others); Wed, 1 Feb 2023 01:52:40 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36470 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231292AbjBAGwc (ORCPT ); Wed, 1 Feb 2023 01:52:32 -0500 Received: from mail-ej1-x62c.google.com (mail-ej1-x62c.google.com [IPv6:2a00:1450:4864:20::62c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 56836A26A; Tue, 31 Jan 2023 22:52:30 -0800 (PST) Received: by mail-ej1-x62c.google.com with SMTP id qw12so32546003ejc.2; Tue, 31 Jan 2023 22:52:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; 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=rkN86TIGDYJR+4nG2fHZ23r9O15jnUv5Y7OgjldbOWg=; b=XQIBijkI8+OKqPlP1sL19SlqXbWw60maYM9giAx3GHyaI8sTJzjRmp2DolRMnASr0y KN+uzR6MaFeH/IuHZUnl3SEco9dEAigoohMzr0+VR8jnKTbFs1fCxFNC7IK019wWt8OY QlzYoAHwljH2DooyMDx5L6kYW21Py4D8vjJ6cfSynz3h51BrFBttejiOKfgd1GgTw0dZ nvzLHSsmvPeJHRhlskiqcv2KfYB/dmNUWPK4L88y9+WMg/F2dS1qJkXnsz7aGsFYHnUn JUswLiy7imzInpudmE6IkD6zZJt8FYlpLUtjMa3u4G3B8tWtvyaAACqDkuz6q4JX0ttc zRsQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=rkN86TIGDYJR+4nG2fHZ23r9O15jnUv5Y7OgjldbOWg=; b=zrJt6ujNMV6nijKiz28w1N+sKoNkFLrzL/eAi2g2RV4Gjr6vIhZUDyl4QeMAuctw9f e7WtHAq69n4e5fNxAakftobnjbrmig2GWhJlE5A7/FWmUS94WXSjqttLKMkDeRpWjqlm bKSQmI0ypfWeW5BVGioG3nawQ0ApYyiqQa+odlOvM7SNMcZQVljWENmQlUZcbyOi+Kb7 UJyGCMabPVzyXPhOnoyMsg/P8GVend3P+Or2pTJaORoowNG+GAW+3tlhZEr9XmOB2uhv LG/oA/HUMU0IFxkmYTapSfakQE10daiRxg830IuBq3+H2/ionVXcxSNChj1TDEVEI9zZ tQGQ== X-Gm-Message-State: AO0yUKVwMJt3CgyvZjdV7V59/2qG1IHBrr7tA/j/UcHHeca2761ubg2T Msy8xFGLtPIUNKQuZAIh68UMtB29dwY= X-Received: by 2002:a17:906:b7d7:b0:88d:fe1:1aca with SMTP id fy23-20020a170906b7d700b0088d0fe11acamr1102961ejb.34.1675234348849; Tue, 31 Jan 2023 22:52:28 -0800 (PST) Received: from localhost.lan (ip-194-187-74-233.konfederacka.maverick.com.pl. [194.187.74.233]) by smtp.gmail.com with ESMTPSA id 1-20020a170906218100b008720c458bd4sm9509608eju.3.2023.01.31.22.52.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 31 Jan 2023 22:52:28 -0800 (PST) From: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= To: Srinivas Kandagatla , Rob Herring , Krzysztof Kozlowski Cc: Matthias Brugger , Kunihiko Hayashi , Masami Hiramatsu , linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= Subject: [PATCH 1/4] dt-bindings: nvmem: mmio: new binding for MMIO accessible NVMEM devices Date: Wed, 1 Feb 2023 07:47:14 +0100 Message-Id: <20230201064717.18410-2-zajec5@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230201064717.18410-1-zajec5@gmail.com> References: <20230201064717.18410-1-zajec5@gmail.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1756610726582511302?= X-GMAIL-MSGID: =?utf-8?q?1756610726582511302?= From: Rafał Miłecki With the NVMEM layouts binding in place we should now use: 1. NVMEM device access bindings 2. NVMEM content description bindings This binding allows describing NVMEM devices that can be MMIO accessed. Signed-off-by: Rafał Miłecki --- .../devicetree/bindings/nvmem/mmio.yaml | 46 +++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 Documentation/devicetree/bindings/nvmem/mmio.yaml diff --git a/Documentation/devicetree/bindings/nvmem/mmio.yaml b/Documentation/devicetree/bindings/nvmem/mmio.yaml new file mode 100644 index 000000000000..27e3f6142769 --- /dev/null +++ b/Documentation/devicetree/bindings/nvmem/mmio.yaml @@ -0,0 +1,46 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/nvmem/mmio.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: MMIO access based NVMEM + +description: | + This binding describes simple NVMEM devices that can be accessed by using MMIO + (memory-mapped I/O access). + + It's a generic solution for providing NVMEM content access. The way of + handling actual content may be device specific and can be described using a + proper layout. + +maintainers: + - Rafał Miłecki + +allOf: + - $ref: nvmem.yaml# + +properties: + compatible: + const: mmio-nvmem + + reg: + maxItems: 1 + + reg-io-width: + description: | + The size (in bytes) of the IO accesses that should be performed + on the device. + enum: [1, 2, 4, 8] + +required: + - reg + +unevaluatedProperties: false + +examples: + - | + nvmem@10000 { + compatible = "mmio-nvmem"; + reg = <0x10000000 0x10000>; + };