From patchwork Tue Oct 5 23:00:03 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Osipenko X-Patchwork-Id: 1536941 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=WQlJPb3i; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=23.128.96.18; helo=vger.kernel.org; envelope-from=devicetree-owner@vger.kernel.org; receiver=) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by bilbo.ozlabs.org (Postfix) with ESMTP id 4HPCkK14nJz9sPB for ; Wed, 6 Oct 2021 10:01:13 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236920AbhJEXDB (ORCPT ); Tue, 5 Oct 2021 19:03:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52300 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236909AbhJEXC7 (ORCPT ); Tue, 5 Oct 2021 19:02:59 -0400 Received: from mail-lf1-x134.google.com (mail-lf1-x134.google.com [IPv6:2a00:1450:4864:20::134]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7C2D4C061749; Tue, 5 Oct 2021 16:01:08 -0700 (PDT) Received: by mail-lf1-x134.google.com with SMTP id n8so2329320lfk.6; Tue, 05 Oct 2021 16:01:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=eJzkAxAf4pzgN3Z1+ho4aj8iG+zpgpgw5v1wwaur2Uk=; b=WQlJPb3i5Db2P1qAhx0S6/6tpo6d3hGy1p8UsLsKwGlx8QEEai/4IiHwa2KXGaGM2b 2/gWL7QNp1Rmu3iZgaAPwKlknqc8wPEOxFzGJSY2mNRpBS1BLvKLcySNWlkeKDnhg+SD 1qKjWbyM9NkhMeckEBnksv5KIjV0fncZYZ0gQzqyaZkYmZobSSptR4GPPUdzx9NgOJIH Ov7Q+qFNuenBdq+ZdFT1I/MJhijc4HJx/W141TCP+L0GSq6w3N7cU8xb5E7xLtOoldie AghSCmOyAPI8uUlGjZ4EV/iqMZ2RH4f7AG91NFZRHSODeTw88xCjYkEe/9OigVjD3IEM T3JQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=eJzkAxAf4pzgN3Z1+ho4aj8iG+zpgpgw5v1wwaur2Uk=; b=yzdToKE/PbPZLG5dehvqyJLB4F2dcrtqwDs1V44juLaND60+gnE0DaLobwD2eyQp4K nABmVto9lekWVnWeV+4oiob1xFWedM/4V92pCTtEsaFswJsiRxt/Sl0/tr6wOvkEkGMt k5bjuhbijBvli8nkxoIqWhr5V4Fk01Pd8rRn4vzgwD71HXSsjCTCtb41UlhMgKDxmfO3 cooeLnPQ4u4Ec2YkeHi+z2VmOBcSso2Gj7ILmOml46WEFed7RuqUhrmXc4O0DXKmhGwN J4tS20fzB7L6AQtgexZPhWOmF6BrPkYGJ9elB/yBKp/H6HW/9xpC14i5D7WdDpcW5zbK OVQA== X-Gm-Message-State: AOAM530hbhkoDntXFt+QCbylV/SEWEzRTDjlbOvHB5rOqX7a4q2ON0Ih rlDcZNjR7AevCjY77suX3vM= X-Google-Smtp-Source: ABdhPJz2C1hDKFyXRKW8nFmufCtfQTbfQroxulZYpGALT7mSInNfS1EM+YHgLWu7j8A3NPGNztmNww== X-Received: by 2002:a2e:a22a:: with SMTP id i10mr24093124ljm.464.1633474866858; Tue, 05 Oct 2021 16:01:06 -0700 (PDT) Received: from localhost.localdomain (79-139-163-57.dynamic.spd-mgts.ru. [79.139.163.57]) by smtp.gmail.com with ESMTPSA id j18sm2101125lfu.84.2021.10.05.16.01.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Oct 2021 16:01:06 -0700 (PDT) From: Dmitry Osipenko To: Thierry Reding , Jonathan Hunter , Krzysztof Kozlowski , Rob Herring Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-tegra@vger.kernel.org Subject: [PATCH v4 1/7] dt-bindings: Relocate DDR bindings Date: Wed, 6 Oct 2021 02:00:03 +0300 Message-Id: <20211005230009.3635-2-digetx@gmail.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20211005230009.3635-1-digetx@gmail.com> References: <20211005230009.3635-1-digetx@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Move DDR bindings to memory-controllers directory to make them more discoverable. Suggested-by: Krzysztof Kozlowski Signed-off-by: Dmitry Osipenko --- .../bindings/{ => memory-controllers}/ddr/lpddr2-timings.txt | 0 .../devicetree/bindings/{ => memory-controllers}/ddr/lpddr2.txt | 0 .../bindings/{ => memory-controllers}/ddr/lpddr3-timings.txt | 0 .../devicetree/bindings/{ => memory-controllers}/ddr/lpddr3.txt | 0 4 files changed, 0 insertions(+), 0 deletions(-) rename Documentation/devicetree/bindings/{ => memory-controllers}/ddr/lpddr2-timings.txt (100%) rename Documentation/devicetree/bindings/{ => memory-controllers}/ddr/lpddr2.txt (100%) rename Documentation/devicetree/bindings/{ => memory-controllers}/ddr/lpddr3-timings.txt (100%) rename Documentation/devicetree/bindings/{ => memory-controllers}/ddr/lpddr3.txt (100%) diff --git a/Documentation/devicetree/bindings/ddr/lpddr2-timings.txt b/Documentation/devicetree/bindings/memory-controllers/ddr/lpddr2-timings.txt similarity index 100% rename from Documentation/devicetree/bindings/ddr/lpddr2-timings.txt rename to Documentation/devicetree/bindings/memory-controllers/ddr/lpddr2-timings.txt diff --git a/Documentation/devicetree/bindings/ddr/lpddr2.txt b/Documentation/devicetree/bindings/memory-controllers/ddr/lpddr2.txt similarity index 100% rename from Documentation/devicetree/bindings/ddr/lpddr2.txt rename to Documentation/devicetree/bindings/memory-controllers/ddr/lpddr2.txt diff --git a/Documentation/devicetree/bindings/ddr/lpddr3-timings.txt b/Documentation/devicetree/bindings/memory-controllers/ddr/lpddr3-timings.txt similarity index 100% rename from Documentation/devicetree/bindings/ddr/lpddr3-timings.txt rename to Documentation/devicetree/bindings/memory-controllers/ddr/lpddr3-timings.txt diff --git a/Documentation/devicetree/bindings/ddr/lpddr3.txt b/Documentation/devicetree/bindings/memory-controllers/ddr/lpddr3.txt similarity index 100% rename from Documentation/devicetree/bindings/ddr/lpddr3.txt rename to Documentation/devicetree/bindings/memory-controllers/ddr/lpddr3.txt From patchwork Tue Oct 5 23:00:04 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Osipenko X-Patchwork-Id: 1536943 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=e4UBGWcH; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=23.128.96.18; helo=vger.kernel.org; envelope-from=devicetree-owner@vger.kernel.org; receiver=) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by bilbo.ozlabs.org (Postfix) with ESMTP id 4HPCkK5m7Bz9sPB for ; Wed, 6 Oct 2021 10:01:13 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236926AbhJEXDB (ORCPT ); Tue, 5 Oct 2021 19:03:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52304 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236919AbhJEXDA (ORCPT ); Tue, 5 Oct 2021 19:03:00 -0400 Received: from mail-lf1-x136.google.com (mail-lf1-x136.google.com [IPv6:2a00:1450:4864:20::136]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 376CEC06174E; Tue, 5 Oct 2021 16:01:09 -0700 (PDT) Received: by mail-lf1-x136.google.com with SMTP id m3so2432638lfu.2; Tue, 05 Oct 2021 16:01:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=PRDWLpe4DhczGRHXEXuLoaCX+QRbkktBsN5TwII6d2g=; b=e4UBGWcH4GImzOG560uBDYsRvnkHu8JY64vMv3SE6BpIPNpcgZG4qGPTfk7ZueSuaj pZR+U1fKS5VLZgPQEBffivfzh4QxMiY5TODky/2DmjljJmLuse3KUdKQTTf1GIk/2FRP 58HVYg16mqGXlCdwv+HMFPGZKbWSvwAd/s9wVlipVgIhMwqFuMq93ihF/ouYWHuj1jmF 2F1g6iN50vhXSn8KqHqrd04phf0tvyeahj2op+quNdZEl2rT8U1rZaZTmfl2BToJKxft A1i0LBaZHJzulTF+im/oVY3ueyhONxXfTna+e54yfzsyVcfJ46GzfKfcdxVNwseL99W4 rATA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=PRDWLpe4DhczGRHXEXuLoaCX+QRbkktBsN5TwII6d2g=; b=wkkC9Eq8x9kSHrdHyqM94Vxd0aQ+/ccHzvAl73scG1o0GWYImJgfgMKCETMdD/XyEe 6l3lF45kfAl7jBAvq9QMn6zDlvvQepyEud13910AQu6jd+sp43QVBuevYtEY4kx0TJTZ 1dgAjaKIKAEEZ6QaxMxlF4e85RIAfR9hQ1rp6NJVsBmJ0Q9O1v2Sun73jE2S3OJfTFHZ VbkR3b/HsFYnib+4UPCRElhNqdQN/RIPCabjJYSx6T/NZowS36I4xTOsroI1XddHMjp+ jzQYEf/yR0xXS0IUgKz5CklaBUiAOxZSbil3a3GAZWbtI57eWQT60kL+pkyyCRd5VAUl xZWQ== X-Gm-Message-State: AOAM531zGXI9q7QCZdsxXAKVmvhpFMPgOnFr2vvoK/gpxBVLGDrAm43L jZrOrwOtBW8SuwWWbpCDyqSfeFIPFcA= X-Google-Smtp-Source: ABdhPJzW0rYluGR7iKLdlLICzRd0S+hTHHPbhcG6Li37XnQxobD1xo8+tc1pshcNNZQQNiLaKlcdLQ== X-Received: by 2002:a2e:898f:: with SMTP id c15mr25080444lji.452.1633474867552; Tue, 05 Oct 2021 16:01:07 -0700 (PDT) Received: from localhost.localdomain (79-139-163-57.dynamic.spd-mgts.ru. [79.139.163.57]) by smtp.gmail.com with ESMTPSA id j18sm2101125lfu.84.2021.10.05.16.01.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Oct 2021 16:01:07 -0700 (PDT) From: Dmitry Osipenko To: Thierry Reding , Jonathan Hunter , Krzysztof Kozlowski , Rob Herring Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-tegra@vger.kernel.org Subject: [PATCH v4 2/7] dt-bindings: memory: lpddr2: Convert to schema Date: Wed, 6 Oct 2021 02:00:04 +0300 Message-Id: <20211005230009.3635-3-digetx@gmail.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20211005230009.3635-1-digetx@gmail.com> References: <20211005230009.3635-1-digetx@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Convert LPDDR2 binding to schema. I removed obsolete ti,jedec-lpddr2-* compatibles since they were never used by device-trees and by the code. Suggested-by: Krzysztof Kozlowski Signed-off-by: Dmitry Osipenko --- .../memory-controllers/ddr/jedec,lpddr2.yaml | 195 ++++++++++++++++++ .../memory-controllers/ddr/lpddr2.txt | 102 --------- 2 files changed, 195 insertions(+), 102 deletions(-) create mode 100644 Documentation/devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml delete mode 100644 Documentation/devicetree/bindings/memory-controllers/ddr/lpddr2.txt diff --git a/Documentation/devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml b/Documentation/devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml new file mode 100644 index 000000000000..d99ccad54938 --- /dev/null +++ b/Documentation/devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml @@ -0,0 +1,195 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/memory-controllers/ddr/jedec,lpddr2.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: LPDDR2 SDRAM compliant to JEDEC JESD209-2 + +maintainers: + - Krzysztof Kozlowski + +properties: + compatible: + oneOf: + - items: + - enum: + - Elpida,ECB240ABACN + - enum: + - jedec,lpddr2-s4 + - items: + - enum: + - jedec,lpddr2-s2 + - items: + - enum: + - jedec,lpddr2-nvm + + density: + description: | + Density in megabits of SDRAM chip. Obtained from device datasheet. + enum: + - 64 + - 128 + - 256 + - 512 + - 1024 + - 2048 + - 4096 + - 8192 + - 16384 + - 32768 + + io-width: + description: | + IO bus width in bits of SDRAM chip. Obtained from device datasheet. + enum: + - 32 + - 16 + - 8 + + tRRD-min-tck: + maximum: 16 + description: | + Active bank a to active bank b in terms of number of clock cycles. + Obtained from device datasheet. + + tWTR-min-tck: + maximum: 16 + description: | + Internal WRITE-to-READ command delay in terms of number of clock cycles. + Obtained from device datasheet. + + tXP-min-tck: + maximum: 16 + description: | + Exit power-down to next valid command delay in terms of number of clock + cycles. Obtained from device datasheet. + + tRTP-min-tck: + maximum: 16 + description: | + Internal READ to PRECHARGE command delay in terms of number of clock + cycles. Obtained from device datasheet. + + tCKE-min-tck: + maximum: 16 + description: | + CKE minimum pulse width (HIGH and LOW pulse width) in terms of number + of clock cycles. Obtained from device datasheet. + + tRPab-min-tck: + maximum: 16 + description: | + Row precharge time (all banks) in terms of number of clock cycles. + Obtained from device datasheet. + + tRCD-min-tck: + maximum: 16 + description: | + RAS-to-CAS delay in terms of number of clock cycles. Obtained from + device datasheet. + + tWR-min-tck: + maximum: 16 + description: | + WRITE recovery time in terms of number of clock cycles. Obtained from + device datasheet. + + tRASmin-min-tck: + maximum: 16 + description: | + Row active time in terms of number of clock cycles. Obtained from device + datasheet. + + tCKESR-min-tck: + maximum: 16 + description: | + CKE minimum pulse width during SELF REFRESH (low pulse width during + SELF REFRESH) in terms of number of clock cycles. Obtained from device + datasheet. + + tFAW-min-tck: + maximum: 16 + description: | + Four-bank activate window in terms of number of clock cycles. Obtained + from device datasheet. + +patternProperties: + "^lpddr2-timings": + type: object + description: | + The lpddr2 node may have one or more child nodes of type "lpddr2-timings". + "lpddr2-timings" provides AC timing parameters of the device for + a given speed-bin. The user may provide the timings for as many + speed-bins as is required. Please see Documentation/devicetree/ + bindings/memory-controllers/ddr/lpddr2-timings.txt for more information + on "lpddr2-timings". + +required: + - compatible + - density + - io-width + +additionalProperties: false + +examples: + - | + elpida_ECB240ABACN: lpddr2 { + compatible = "Elpida,ECB240ABACN", "jedec,lpddr2-s4"; + density = <2048>; + io-width = <32>; + + tRPab-min-tck = <3>; + tRCD-min-tck = <3>; + tWR-min-tck = <3>; + tRASmin-min-tck = <3>; + tRRD-min-tck = <2>; + tWTR-min-tck = <2>; + tXP-min-tck = <2>; + tRTP-min-tck = <2>; + tCKE-min-tck = <3>; + tCKESR-min-tck = <3>; + tFAW-min-tck = <8>; + + timings_elpida_ECB240ABACN_400mhz: lpddr2-timings0 { + compatible = "jedec,lpddr2-timings"; + min-freq = <10000000>; + max-freq = <400000000>; + tRPab = <21000>; + tRCD = <18000>; + tWR = <15000>; + tRAS-min = <42000>; + tRRD = <10000>; + tWTR = <7500>; + tXP = <7500>; + tRTP = <7500>; + tCKESR = <15000>; + tDQSCK-max = <5500>; + tFAW = <50000>; + tZQCS = <90000>; + tZQCL = <360000>; + tZQinit = <1000000>; + tRAS-max-ns = <70000>; + }; + + timings_elpida_ECB240ABACN_200mhz: lpddr2-timings1 { + compatible = "jedec,lpddr2-timings"; + min-freq = <10000000>; + max-freq = <200000000>; + tRPab = <21000>; + tRCD = <18000>; + tWR = <15000>; + tRAS-min = <42000>; + tRRD = <10000>; + tWTR = <10000>; + tXP = <7500>; + tRTP = <7500>; + tCKESR = <15000>; + tDQSCK-max = <5500>; + tFAW = <50000>; + tZQCS = <90000>; + tZQCL = <360000>; + tZQinit = <1000000>; + tRAS-max-ns = <70000>; + }; + }; diff --git a/Documentation/devicetree/bindings/memory-controllers/ddr/lpddr2.txt b/Documentation/devicetree/bindings/memory-controllers/ddr/lpddr2.txt deleted file mode 100644 index ddd40121e6f6..000000000000 --- a/Documentation/devicetree/bindings/memory-controllers/ddr/lpddr2.txt +++ /dev/null @@ -1,102 +0,0 @@ -* LPDDR2 SDRAM memories compliant to JEDEC JESD209-2 - -Required properties: -- compatible : Should be one of - "jedec,lpddr2-nvm", "jedec,lpddr2-s2", - "jedec,lpddr2-s4" - - "ti,jedec-lpddr2-s2" should be listed if the memory part is LPDDR2-S2 type - - "ti,jedec-lpddr2-s4" should be listed if the memory part is LPDDR2-S4 type - - "ti,jedec-lpddr2-nvm" should be listed if the memory part is LPDDR2-NVM type - -- density : representing density in Mb (Mega bits) - -- io-width : representing bus width. Possible values are 8, 16, and 32 - -Optional properties: - -The following optional properties represent the minimum value of some AC -timing parameters of the DDR device in terms of number of clock cycles. -These values shall be obtained from the device data-sheet. -- tRRD-min-tck -- tWTR-min-tck -- tXP-min-tck -- tRTP-min-tck -- tCKE-min-tck -- tRPab-min-tck -- tRCD-min-tck -- tWR-min-tck -- tRASmin-min-tck -- tCKESR-min-tck -- tFAW-min-tck - -Child nodes: -- The lpddr2 node may have one or more child nodes of type "lpddr2-timings". - "lpddr2-timings" provides AC timing parameters of the device for - a given speed-bin. The user may provide the timings for as many - speed-bins as is required. Please see Documentation/devicetree/ - bindings/ddr/lpddr2-timings.txt for more information on "lpddr2-timings" - -Example: - -elpida_ECB240ABACN : lpddr2 { - compatible = "Elpida,ECB240ABACN","jedec,lpddr2-s4"; - density = <2048>; - io-width = <32>; - - tRPab-min-tck = <3>; - tRCD-min-tck = <3>; - tWR-min-tck = <3>; - tRASmin-min-tck = <3>; - tRRD-min-tck = <2>; - tWTR-min-tck = <2>; - tXP-min-tck = <2>; - tRTP-min-tck = <2>; - tCKE-min-tck = <3>; - tCKESR-min-tck = <3>; - tFAW-min-tck = <8>; - - timings_elpida_ECB240ABACN_400mhz: lpddr2-timings@0 { - compatible = "jedec,lpddr2-timings"; - min-freq = <10000000>; - max-freq = <400000000>; - tRPab = <21000>; - tRCD = <18000>; - tWR = <15000>; - tRAS-min = <42000>; - tRRD = <10000>; - tWTR = <7500>; - tXP = <7500>; - tRTP = <7500>; - tCKESR = <15000>; - tDQSCK-max = <5500>; - tFAW = <50000>; - tZQCS = <90000>; - tZQCL = <360000>; - tZQinit = <1000000>; - tRAS-max-ns = <70000>; - }; - - timings_elpida_ECB240ABACN_200mhz: lpddr2-timings@1 { - compatible = "jedec,lpddr2-timings"; - min-freq = <10000000>; - max-freq = <200000000>; - tRPab = <21000>; - tRCD = <18000>; - tWR = <15000>; - tRAS-min = <42000>; - tRRD = <10000>; - tWTR = <10000>; - tXP = <7500>; - tRTP = <7500>; - tCKESR = <15000>; - tDQSCK-max = <5500>; - tFAW = <50000>; - tZQCS = <90000>; - tZQCL = <360000>; - tZQinit = <1000000>; - tRAS-max-ns = <70000>; - }; - -} From patchwork Tue Oct 5 23:00:05 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Osipenko X-Patchwork-Id: 1536945 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=Y83NcGan; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=23.128.96.18; helo=vger.kernel.org; envelope-from=devicetree-owner@vger.kernel.org; receiver=) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by bilbo.ozlabs.org (Postfix) with ESMTP id 4HPCkL5KHqz9sPB for ; Wed, 6 Oct 2021 10:01:14 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236949AbhJEXDD (ORCPT ); Tue, 5 Oct 2021 19:03:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52310 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236923AbhJEXDB (ORCPT ); Tue, 5 Oct 2021 19:03:01 -0400 Received: from mail-lf1-x12a.google.com (mail-lf1-x12a.google.com [IPv6:2a00:1450:4864:20::12a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C2D22C061749; Tue, 5 Oct 2021 16:01:09 -0700 (PDT) Received: by mail-lf1-x12a.google.com with SMTP id m3so2432747lfu.2; Tue, 05 Oct 2021 16:01:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=zJBbAysPZhEzfw+QShpgld2gMZtdI2/QGN8l/rJdoiM=; b=Y83NcGanEST0vssGF7O7AheANAOJW8E7BWD09gvmn7+CADyq8OYsb0WKftuXPB27E2 hKbBZYeCbNk1Vy+2f9RX5KsPY7n+0m7+tOcJiCGDLu9Qk5NWqPM3k7MaMiGJKPxaqlZO lGWJ4k42xWSdfD7khr9ZeS6VWDTN7VyxrvA/ExoVZvKKfBF0ipmj3j9uei9eR3KvySIB kWgoyIUqve1tWSNrZQwXXGtifxPeLD+xvVrNMn8uqHOBFieJ8jqwFBPHfQEf0jb6M7Ey 6uO7lyujAMUzqxjaU5/3l29OBYT9eZw9rebpG/1LWaqVsNzvdEFuFobZ/c/r06hdbAAE JHwA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=zJBbAysPZhEzfw+QShpgld2gMZtdI2/QGN8l/rJdoiM=; b=c96OwkdAhZRll6O+fhlXItkTG/SZZXXj6VAEezJvCapWAQdF4KCrzNSz6EvudCciki YMuhfExpV4zEvXG4uvNsXJC8ztnPlecxFl1BNpPxEffDXQZIAxAEw9x5x1WQkanuACUx gH+VRwfXKmVx4PXLQwlX+0LD3WLuEN0OPnFaHVd165QzL4f5VynYloux/a5/y7kH2OlR fr0AI07sFgq4UFK8i2jmLRf5YQnu0ydQOIn1C7EEZzpqfxW1yd/S8lUXbCfPsV5H+4oG GI1DDYCVBzFuVGUCvZbBcRPNLOV4UzBexOGEUGfuUUvYxKsNpCLIrKlrNxlDeYjNsdUj GpRQ== X-Gm-Message-State: AOAM531py8qtqjCaDBtw5LHwOXvjAU6WZwRGH3Q7OZcxUBv1SUEIHEsm h108FHOI6kArS+Iqst91Dj8= X-Google-Smtp-Source: ABdhPJzP21fe8YZWDw1AFXGexgxBxukSozQibJfweTM5IJjnJJR2YLYS6VpQSgmciOPBKtoBhtZl3g== X-Received: by 2002:a19:4802:: with SMTP id v2mr6128083lfa.49.1633474868209; Tue, 05 Oct 2021 16:01:08 -0700 (PDT) Received: from localhost.localdomain (79-139-163-57.dynamic.spd-mgts.ru. [79.139.163.57]) by smtp.gmail.com with ESMTPSA id j18sm2101125lfu.84.2021.10.05.16.01.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Oct 2021 16:01:07 -0700 (PDT) From: Dmitry Osipenko To: Thierry Reding , Jonathan Hunter , Krzysztof Kozlowski , Rob Herring Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-tegra@vger.kernel.org Subject: [PATCH v4 3/7] dt-bindings: memory: lpddr2: Add revision-id properties Date: Wed, 6 Oct 2021 02:00:05 +0300 Message-Id: <20211005230009.3635-4-digetx@gmail.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20211005230009.3635-1-digetx@gmail.com> References: <20211005230009.3635-1-digetx@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Add optional revision-id standard LPDDR2 properties which will help to identify memory chip. Signed-off-by: Dmitry Osipenko --- .../memory-controllers/ddr/jedec,lpddr2.yaml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/Documentation/devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml b/Documentation/devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml index d99ccad54938..01efb43c3425 100644 --- a/Documentation/devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml +++ b/Documentation/devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml @@ -24,6 +24,16 @@ properties: - enum: - jedec,lpddr2-nvm + revision-id1: + maximum: 255 + description: | + Revision 1 value of SDRAM chip. Obtained from device datasheet. + + revision-id2: + maximum: 255 + description: | + Revision 2 value of SDRAM chip. Obtained from device datasheet. + density: description: | Density in megabits of SDRAM chip. Obtained from device datasheet. @@ -138,6 +148,8 @@ examples: compatible = "Elpida,ECB240ABACN", "jedec,lpddr2-s4"; density = <2048>; io-width = <32>; + revision-id1 = <1>; + revision-id2 = <0>; tRPab-min-tck = <3>; tRCD-min-tck = <3>; From patchwork Tue Oct 5 23:00:06 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Osipenko X-Patchwork-Id: 1536946 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=Otx2vBOl; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=23.128.96.18; helo=vger.kernel.org; envelope-from=devicetree-owner@vger.kernel.org; receiver=) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by bilbo.ozlabs.org (Postfix) with ESMTP id 4HPCkN1flVz9sPB for ; Wed, 6 Oct 2021 10:01:16 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236975AbhJEXDF (ORCPT ); Tue, 5 Oct 2021 19:03:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52316 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236934AbhJEXDC (ORCPT ); Tue, 5 Oct 2021 19:03:02 -0400 Received: from mail-lf1-x130.google.com (mail-lf1-x130.google.com [IPv6:2a00:1450:4864:20::130]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 00BF2C061749; Tue, 5 Oct 2021 16:01:11 -0700 (PDT) Received: by mail-lf1-x130.google.com with SMTP id m3so2432950lfu.2; Tue, 05 Oct 2021 16:01:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=XW6l4UYrm0yyzmarTcv0AQ0+utEDkcMwT9ee84sdcjI=; b=Otx2vBOl5q73l6EoRrKRVi/KpuXf2oB9U4tLNO5lkdu4iWcKt6ZW34EBYxra+WdAh5 ibQgpVeIDLBIhIQOZu2+sWu8UGsaMKXKy8bVv0oh+8+WQnCI6Ywikg9Lu0k3E0oGoICD jJ+qV9MVCZD8pId1v5i+KCrueiqYS/v2kcaZZjQWnz8xvAw/PmiNHE71msSTxfHiawa6 tL9M0+ZPr5ZRo1IbH4xUVBtsg5fgCmiU9m3GnrNynmVGrXpSjvOclOcxd1bp2BFYnIUU ig5yowjjA88B23ojmPhnQkLQbAjAI1pJLwh7g2ORtKsFBCMfnF/BXT+9+WqAOvqkDTGU /aPg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=XW6l4UYrm0yyzmarTcv0AQ0+utEDkcMwT9ee84sdcjI=; b=VhrvRJXXF3/M9bM818hCBvHw//De61lMuYkT9xUBLcCuXV4u8C/yNtJf8koxP+tBh/ dnyA04K26Se3qlPuxaWLKc0kowH6wtxtlelPmt4OnE4nCteRaz9OWaIWnkKRHlIJ5Jiq ++1RUNcWFUjT0ZBIdHV9QyB4LkIkkAYrvAmwnvtdWiqs8dQS2DGi9YNT2z7vHfPV65gJ BIGr4l+gXQSWQ1DZ2pKbser4YqcyXcsQ8xeRnBfcSyklQNmrb8da57o0BkTOmiUrow8J BX0xbXPFvfmb22SF10de2mr9Nl936orevXEsffXcuiHDPrAUTPCCPtQUCI5uBrnc1zPW sw4Q== X-Gm-Message-State: AOAM531Wt406LXIBsvUr+iKfnB8OyMBK7bHLIdMP0XBHdgrxN8tmo/TG FBkHgqC3pIz+RRxkmP6rU1I= X-Google-Smtp-Source: ABdhPJxev2UTZ/2i1J9Go+S+CK34gRxt+EZbPIY3uJgLRlAX+mAi8Qgdi/xZcBCWbPDwJbzvZX+V5A== X-Received: by 2002:a05:6512:d2:: with SMTP id c18mr6353258lfp.484.1633474869428; Tue, 05 Oct 2021 16:01:09 -0700 (PDT) Received: from localhost.localdomain (79-139-163-57.dynamic.spd-mgts.ru. [79.139.163.57]) by smtp.gmail.com with ESMTPSA id j18sm2101125lfu.84.2021.10.05.16.01.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Oct 2021 16:01:08 -0700 (PDT) From: Dmitry Osipenko To: Thierry Reding , Jonathan Hunter , Krzysztof Kozlowski , Rob Herring Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-tegra@vger.kernel.org Subject: [PATCH v4 4/7] dt-bindings: memory: lpddr2: Document Elpida B8132B2PB-6D-F Date: Wed, 6 Oct 2021 02:00:06 +0300 Message-Id: <20211005230009.3635-5-digetx@gmail.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20211005230009.3635-1-digetx@gmail.com> References: <20211005230009.3635-1-digetx@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Elpida B8132B2PB-6D-F memory chip is used by ASUS Transformer TF101 tablet, add compatible for it. We need to specify this compatible it for a device-tree node containing corresponding memory timings in order to allow software to match the timings with the detected hardware. Signed-off-by: Dmitry Osipenko --- .../devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml b/Documentation/devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml index 01efb43c3425..464d8406be3c 100644 --- a/Documentation/devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml +++ b/Documentation/devicetree/bindings/memory-controllers/ddr/jedec,lpddr2.yaml @@ -15,6 +15,7 @@ properties: - items: - enum: - Elpida,ECB240ABACN + - elpida,B8132B2PB-6D-F - enum: - jedec,lpddr2-s4 - items: From patchwork Tue Oct 5 23:00:07 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Osipenko X-Patchwork-Id: 1536947 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=K93QjFCE; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=23.128.96.18; helo=vger.kernel.org; envelope-from=devicetree-owner@vger.kernel.org; receiver=) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by bilbo.ozlabs.org (Postfix) with ESMTP id 4HPCkN5wFxz9sR4 for ; Wed, 6 Oct 2021 10:01:16 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236950AbhJEXDG (ORCPT ); Tue, 5 Oct 2021 19:03:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52320 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236941AbhJEXDD (ORCPT ); Tue, 5 Oct 2021 19:03:03 -0400 Received: from mail-lf1-x131.google.com (mail-lf1-x131.google.com [IPv6:2a00:1450:4864:20::131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B980BC06174E; Tue, 5 Oct 2021 16:01:11 -0700 (PDT) Received: by mail-lf1-x131.google.com with SMTP id n8so2329737lfk.6; Tue, 05 Oct 2021 16:01:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=ZazjXyZEVxAOGCWfu+WjAJm1Kzn5mq9JVmnxHrZ+lKg=; b=K93QjFCEDw5vsDQbnfutSS22rGejQGc1BkSHFS240RvVmorZMzD0s188NiKgV4F9Zg jk4+dh+F7cd9jkR9w7CUgXwTI/EXDzhfgeFT+JgU93pwpz95Ueg+OzbzARrnII5zjFkD B25lz+BD4xjDPEpKf6Jr5pkZKXOCg4/lD3sfNelIuEpNilQAbskyDbwonktN8f++BIC+ mine29+yI36rV3Uztgjk860mFUUQL/0bNAgrq6Exsr67eOZOeAMM4KVoKeOUDLxaCgwK sdjeId/vntLusF0fxkLhbK7TqmJKbHOF0pTfwFl5JqyGq6/8H1jTMPG6ZhPDditw1Pdg TL8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=ZazjXyZEVxAOGCWfu+WjAJm1Kzn5mq9JVmnxHrZ+lKg=; b=bU2aUDRApQLR6bB8viL9CSHQ7qonGK2udhnSJOBmqB98DhXE/81A2gDR18hKeEe15a iGVRr1rE2qYXGxAAZ88gLS1n5S3xobM+5dwvcBqrpIcdBiqmsEbzujY24Fzw805F/rXt z9I3L/n0ibxocpvhbfylZF5XtvOl390Edvmelh1vTYqNrwJfq3DUVKYHPJVDltGfEZns RPJw/xLJQ3iVOD/qepaWWVzWuqR3YzZ4Ov5qOlHp71kdYS+Tim80aVgujd8eFOnuaJkJ iKDMvleNfjqS19ciAxur6tT+hpdRH9+s5akEmxpyM1/5b2PmYN59eAEf76/aAPk4oDIJ sQ+g== X-Gm-Message-State: AOAM532qj2mIZ8PdmG7QPVzfQ4MyMXt6X6sc8WA40plF+n5/q1Qe6KSf 96zLlvAgSgoQjHNsLGBfEt0= X-Google-Smtp-Source: ABdhPJzQt0fI/8QXYDuIuMYPmHlU8ABtaHpXR/iC7njP9IudxCEfMBPzpdaPDsWa74vK2CPNWpV4Tw== X-Received: by 2002:a2e:1645:: with SMTP id 5mr23738842ljw.123.1633474870085; Tue, 05 Oct 2021 16:01:10 -0700 (PDT) Received: from localhost.localdomain (79-139-163-57.dynamic.spd-mgts.ru. [79.139.163.57]) by smtp.gmail.com with ESMTPSA id j18sm2101125lfu.84.2021.10.05.16.01.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Oct 2021 16:01:09 -0700 (PDT) From: Dmitry Osipenko To: Thierry Reding , Jonathan Hunter , Krzysztof Kozlowski , Rob Herring Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-tegra@vger.kernel.org Subject: [PATCH v4 5/7] dt-bindings: memory: tegra20: emc: Document new LPDDR2 sub-node Date: Wed, 6 Oct 2021 02:00:07 +0300 Message-Id: <20211005230009.3635-6-digetx@gmail.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20211005230009.3635-1-digetx@gmail.com> References: <20211005230009.3635-1-digetx@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Some Tegra20 boards don't have RAM code stored in NVMEM, which is used for the memory chip identification and the identity information should be read out from LPDDR2 chip in this case. Document new sub-node containing generic LPDDR2 properties that will be used for the memory chip identification if RAM code isn't available. The identification is done by reading out memory configuration values from generic LPDDR2 mode registers of SDRAM chip and comparing them with the values of device-tree 'lpddr2' sub-node. Signed-off-by: Dmitry Osipenko --- .../nvidia,tegra20-emc.yaml | 23 +++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/bindings/memory-controllers/nvidia,tegra20-emc.yaml b/Documentation/devicetree/bindings/memory-controllers/nvidia,tegra20-emc.yaml index cac6842dc8f1..2fa44951cfde 100644 --- a/Documentation/devicetree/bindings/memory-controllers/nvidia,tegra20-emc.yaml +++ b/Documentation/devicetree/bindings/memory-controllers/nvidia,tegra20-emc.yaml @@ -164,12 +164,20 @@ patternProperties: "#size-cells": const: 0 + lpddr2: + $ref: "ddr/jedec,lpddr2.yaml#" + type: object + patternProperties: "^emc-table@[0-9]+$": $ref: "#/$defs/emc-table" - required: - - nvidia,ram-code + oneOf: + - required: + - nvidia,ram-code + + - required: + - lpddr2 additionalProperties: false @@ -227,4 +235,15 @@ examples: 0x00000000 0x00000000 0x00000000 0x00000000>; }; }; + + emc-tables@1 { + reg = <1>; + + lpddr2 { + compatible = "elpida,B8132B2PB-6D-F", "jedec,lpddr2-s4"; + revision-id1 = <1>; + density = <2048>; + io-width = <16>; + }; + }; };