Received: by 2002:ac0:aed5:0:0:0:0:0 with SMTP id t21csp3159111imb; Tue, 5 Mar 2019 02:22:08 -0800 (PST) X-Google-Smtp-Source: APXvYqy+yZqtFiUaEBsOXdUGDgesQy9z4tQmWo7ixa70AdhCyrexEsYf2wctHWGPs3xu4yOIbdE7 X-Received: by 2002:a63:d205:: with SMTP id a5mr776940pgg.142.1551781328896; Tue, 05 Mar 2019 02:22:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1551781328; cv=none; d=google.com; s=arc-20160816; b=dtDEXK/QT1VzUL0JhojmaLveFyNMJedGnb0sgK0nz96tWTWIt+0v7fWNjSAQsG7+Wm YH+iop0BQ7NcMpnwbsmaJymx6a1+O4Wew1/v7yMfP476eBj63mIehfyn0SrSJwVBvoAa F/kOlWpM6vc4x5wXJZi32weqBsnBv36HlXdpmOWh9oLhJLBXs2YdIXIwVGsUVFQNVrT6 E/JK62dP+olYIk5X7JORq83J2VJA/GvhGlB96ZdNPKejiQsvoDmYKrngxp/jTRxiPN/7 24tkN1SRSHbQzZhKvJ0dYgdF4PCBNkDXwAJkXR3VjTiquZ/R5zZkmDIESTgNlyrIJEOH 3NSg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:cms-type:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature:dkim-filter; bh=9yr4qRVQkXZOec8agyeSNlIohIYaDFOzDtfGULMZs7M=; b=REfQloRJ3VW7/NVkcSWDeegVkyFkIALtH/lYOWC7W+XeO/OaQFz5olDlxXfT1YcZeH r8rb9FALJ3uO/vkBKic48o+c0yHkWSbi1+czsWM4J3UkyYYqVtmJqUaPftCD5NyfVpHH Do2wKA4LldXChODFkI2oDwjau/LW+uH/z4zKLEf/qD0dSPec9LzOXfxHZ9LugdXWoGIQ myGv0bN3DFQ8JQfqHjELoteEVP5/bT7HewagIEIRuyEPaCTiNsQZspHJkeKEgLVAF89W T4uB44EZHvxIF2H5j6pczrO++GiWC01h6OK3jrnbjY11Jgt18mlobXlNsfgCp2ra6JdN SmBg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=Wae1Jtit; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l10si7676672pfb.283.2019.03.05.02.21.53; Tue, 05 Mar 2019 02:22:08 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=Wae1Jtit; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727755AbfCEKTv (ORCPT + 99 others); Tue, 5 Mar 2019 05:19:51 -0500 Received: from mailout1.w1.samsung.com ([210.118.77.11]:54973 "EHLO mailout1.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727669AbfCEKTa (ORCPT ); Tue, 5 Mar 2019 05:19:30 -0500 Received: from eucas1p1.samsung.com (unknown [182.198.249.206]) by mailout1.w1.samsung.com (KnoxPortal) with ESMTP id 20190305101928euoutp0189d4cbbf729244c41e088a3db0c73df9~JCMBVAilp0539305393euoutp01J for ; Tue, 5 Mar 2019 10:19:28 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout1.w1.samsung.com 20190305101928euoutp0189d4cbbf729244c41e088a3db0c73df9~JCMBVAilp0539305393euoutp01J DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1551781168; bh=9yr4qRVQkXZOec8agyeSNlIohIYaDFOzDtfGULMZs7M=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Wae1JtitxDVXZHOr1rA0BEh+dvNtrxlPUchD/MT3d4h7IfTnFV74bV2HViQFjVmoz 35ikMiqtddw70o/zwyErknYoRzOegBGIlTsRvh6wyYzekMPP5M2O+/qHn0MMgxTJTC FicEfDLpEAlp90B2DPbockCmzpD4ETDI9Dk2Hd5g= Received: from eusmges3new.samsung.com (unknown [203.254.199.245]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20190305101927eucas1p26b76197492fade845e770a84f258ddd7~JCMAIxnxF2250822508eucas1p2y; Tue, 5 Mar 2019 10:19:27 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges3new.samsung.com (EUCPMTA) with SMTP id ED.CB.04806.F2D4E7C5; Tue, 5 Mar 2019 10:19:27 +0000 (GMT) Received: from eusmtrp2.samsung.com (unknown [182.198.249.139]) by eucas1p2.samsung.com (KnoxPortal) with ESMTPA id 20190305101926eucas1p2eee36b9cb50cbcf511fab7bae59e24bb~JCL-fTo4x2211722117eucas1p2v; Tue, 5 Mar 2019 10:19:26 +0000 (GMT) Received: from eusmgms2.samsung.com (unknown [182.198.249.180]) by eusmtrp2.samsung.com (KnoxPortal) with ESMTP id 20190305101926eusmtrp21a3115d13b2f7e4fa5fc21940a153a12~JCL-QiSNu2083020830eusmtrp25; Tue, 5 Mar 2019 10:19:26 +0000 (GMT) X-AuditID: cbfec7f5-34dff700000012c6-85-5c7e4d2f24f2 Received: from eusmtip1.samsung.com ( [203.254.199.221]) by eusmgms2.samsung.com (EUCPMTA) with SMTP id A9.1F.04128.E2D4E7C5; Tue, 5 Mar 2019 10:19:26 +0000 (GMT) Received: from AMDC3778.DIGITAL.local (unknown [106.120.51.20]) by eusmtip1.samsung.com (KnoxPortal) with ESMTPA id 20190305101925eusmtip1a72151e354e308855fbfb7b1b10f3e74~JCL_saCs73045730457eusmtip1s; Tue, 5 Mar 2019 10:19:25 +0000 (GMT) From: Lukasz Luba To: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, linux-samsung-soc@vger.kernel.org Cc: b.zolnierkie@samsung.com, krzk@kernel.org, kgene@kernel.org, cw00.choi@samsung.com, kyungmin.park@samsung.com, m.szyprowski@samsung.com, s.nawrocki@samsung.com, myungjoo.ham@samsung.com, Lukasz Luba Subject: [PATCH v5 4/8] dt-bindings: devfreq: add Exynos5422 DMC device description Date: Tue, 5 Mar 2019 11:19:07 +0100 Message-Id: <1551781151-5562-5-git-send-email-l.luba@partner.samsung.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1551781151-5562-1-git-send-email-l.luba@partner.samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFprIKsWRmVeSWpSXmKPExsWy7djP87r6vnUxBkf38lpsnLGe1eL6l+es FvOPnGO16H/8mtni/PkN7BZnm96wW9xqkLG4vGsOm8Xn3iOMFjPO72OyWHvkLrvF7cYVbBaH 37SzOvB6bFrVyeZx8N0eJo++LasYPT5vkgtgieKySUnNySxLLdK3S+DKeLx5FlPBMb2K623C DYw/VboYOTkkBEwkVj+ZztLFyMUhJLCCUWLBwWlsEM4XRomTs7dBOZ8ZJTrvTWeGaXn0aR87 iC0ksJxRYtY2D7iO14teA83i4GAT0JPYsaoQpEZEoFrizvX9zCA1zAJvGSVm3vzCApIQFgiV uHL4ChOIzSKgKrHpRQdYnFfAU2Lu7CssEMvkJG6e6wRbzCngJbF/4XqwQRICk9kldre2MEIU uUhcfdnFCmELS7w6voUdwpaR+L9zPhOEXSxxtmMVG4RdI9F+cgdUjbXE4eMXWUGOZhbQlFi/ Sx8i7Cjx9cUhsLCEAJ/EjbeCIGFmIHPSNlA4gIR5JTrahCCqNSS29FyAWiQmsXzNNKjhHhJz JrRDQ3cuo0THjatM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fNLrlAYULz3rhPnbwSIf7vvu+o8vFX W89jcKr+qPGyYNYLjDoH2n6sCpsaeK9lZXwqx462LvewF6bHdQK2dApf52bTfPlvdxfH3e7L 0R+ztStEFwSflDSWqMtft4ONd6b6lrsbV8du8BU/rsRSnJFoqMVcVJwIADkDpHiGAgAA X-CMS-MailID: 20190305101926eucas1p2eee36b9cb50cbcf511fab7bae59e24bb X-Msg-Generator: CA Content-Type: text/plain; charset="utf-8" X-RootMTR: 20190305101926eucas1p2eee36b9cb50cbcf511fab7bae59e24bb X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20190305101926eucas1p2eee36b9cb50cbcf511fab7bae59e24bb References: <1551781151-5562-1-git-send-email-l.luba@partner.samsung.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The patch adds description for DT binding for a new Exynos5422 Dynamic Memory Controller device. Signed-off-by: Lukasz Luba --- .../devicetree/bindings/devfreq/exynos5422-dmc.txt | 177 +++++++++++++++++++++ 1 file changed, 177 insertions(+) create mode 100644 Documentation/devicetree/bindings/devfreq/exynos5422-dmc.txt diff --git a/Documentation/devicetree/bindings/devfreq/exynos5422-dmc.txt b/Documentation/devicetree/bindings/devfreq/exynos5422-dmc.txt new file mode 100644 index 0000000..0e73e98 --- /dev/null +++ b/Documentation/devicetree/bindings/devfreq/exynos5422-dmc.txt @@ -0,0 +1,177 @@ +* Exynos5422 frequency and voltage scaling for Dynamic Memory Controller device + +The Samsung Exynos5422 SoC has DMC (Dynamic Memory Controller) to which the DRAM +memory chips are connected. The driver is to monitor the controller in runtime +and switch frequency and voltage. To monitor the usage of the controller in +runtime, the driver uses the PPMU (Platform Performance Monitoring Unit), which +is able to measure the current load of the memory. +When 'userspace' governor is used for the driver, an application is able to +switch the DMC frequency. + +Required properties for DMC device for Exynos5422: +- compatible: Should be "samsung,exynos5422-bus". +- clock-names : the name of clock used by the bus, "bus". +- clocks : phandles for clock specified in "clock-names" property. +- devfreq-events : phandles for PPMU devices connected to this DMC. + +The example definition of a DMC and PPMU devices declared in DT is shown below: + + ppmu_dmc0_0: ppmu@10d00000 { + compatible = "samsung,exynos-ppmu"; + reg = <0x10d00000 0x2000>; + clocks = <&clock CLK_PCLK_PPMU_DREX0_0>; + clock-names = "ppmu"; + status = "okay"; + events { + ppmu_event_dmc0_0: ppmu-event3-dmc0_0 { + event-name = "ppmu-event3-dmc0_0"; + }; + }; + }; + + + ppmu_dmc0_1: ppmu@10d10000 { + compatible = "samsung,exynos-ppmu"; + reg = <0x10d10000 0x2000>; + clocks = <&clock CLK_PCLK_PPMU_DREX0_1>; + clock-names = "ppmu"; + status = "okay"; + events { + ppmu_event_dmc0_1: ppmu-event3-dmc0_1 { + event-name = "ppmu-event3-dmc0_1"; + }; + }; + }; + + ppmu_dmc1_0: ppmu@10d10000 { + compatible = "samsung,exynos-ppmu"; + reg = <0x10d60000 0x2000>; + clocks = <&clock CLK_PCLK_PPMU_DREX1_0>; + clock-names = "ppmu"; + status = "okay"; + events { + ppmu_event_dmc1_0: ppmu-event3-dmc1_0 { + event-name = "ppmu-event3-dmc1_0"; + }; + }; + }; + + ppmu_dmc1_1: ppmu@10d70000 { + compatible = "samsung,exynos-ppmu"; + reg = <0x10d70000 0x2000>; + clocks = <&clock CLK_PCLK_PPMU_DREX1_1>; + clock-names = "ppmu"; + status = "okay"; + events { + ppmu_event_dmc1_1: ppmu-event3-dmc1_1 { + event-name = "ppmu-event3-dmc1_1"; + }; + }; + }; + + dmc: memory-controller@10c20000 { + compatible = "samsung,exynos5422-dmc"; + reg = <0x10c20000 0x10000>, <0x10c30000 0x10000>, + <0x10000000 0x1000>; + clocks = <&clock CLK_FOUT_SPLL>, + <&clock CLK_MOUT_SCLK_SPLL>, + <&clock CLK_FF_DOUT_SPLL2>, + <&clock CLK_FOUT_BPLL>, + <&clock CLK_MOUT_BPLL>, + <&clock CLK_SCLK_BPLL>, + <&clock CLK_MOUT_MX_MSPLL_CCORE>, + <&clock CLK_MOUT_MX_MSPLL_CCORE_PHY>, + <&clock CLK_MOUT_MCLK_CDREX>, + <&clock CLK_DOUT_CLK2X_PHY0>, + <&clock CLK_CLKM_PHY0>, + <&clock CLK_CLKM_PHY1>, + <&clock CLK_CDREX_PAUSE>, + <&clock CLK_CDREX_TIMING_SET>; + clock-names = "fout_spll", + "mout_sclk_spll", + "ff_dout_spll2", + "fout_bpll", + "mout_bpll", + "sclk_bpll", + "mout_mx_mspll_ccore", + "mout_mx_mspll_ccore_phy", + "mout_mclk_cdrex", + "dout_clk2x_phy0", + "clkm_phy0", + "clkm_phy1", + "clk_cdrex_pause", + "clk_cdrex_timing_set"; + status = "okay"; + operating-points-v2 = <&dmc_opp_table>; + devfreq-events = <&ppmu_dmc0_0>, <&ppmu_dmc0_1>, + <&ppmu_dmc1_0>, <&ppmu_dmc1_1>; + }; + +The needed timings of DRAM memory are stored in dedicated nodes. +There are two nodes with regular timings and for bypass mode. + + dmc_bypass_mode: bypass_mode { + compatible = "samsung,dmc-bypass-mode"; + + freq-hz = <400000000>; + volt-uv = <887500>; + dram-timing-row = <0x365a9713>; + dram-timing-data = <0x4740085e>; + dram-timing-power = <0x543a0446>; + }; + + dram_timing: timing { + compatible = "samsung,dram-timing"; + + dram-timing-names = "165MHz", "206MHz", "275MHz", "413MHz", + "543MHz", "633MHz", "728MHz", "825MHz"; + dram-timing-row = <0x11223185>, <0x112331C6>, <0x12244287>, + <0x1B35538A>, <0x244764CD>, <0x2A48758F>, + <0x30598651>, <0x365A9713>; + dram-timing-data = <0x2720085E>, <0x2720085E>, <0x2720085E>, + <0x2720085E>, <0x3730085E>, <0x3730085E>, + <0x3730085E>, <0x4740085E>; + dram-timing-power = <0x140C0225>, <0x180F0225>, <0x1C140225>, + <0x2C1D0225>, <0x38270335>, <0x402D0335>, + <0x4C330336>, <0x543A0446>; + }; + +The frequencies supported by the DMC are stored in OPP table v2. + + dmc_opp_table: opp_table2 { + compatible = "operating-points-v2"; + + opp00 { + opp-hz = /bits/ 64 <165000000>; + opp-microvolt = <875000>; + }; + opp01 { + opp-hz = /bits/ 64 <206000000>; + opp-microvolt = <875000>; + }; + opp02 { + opp-hz = /bits/ 64 <275000000>; + opp-microvolt = <875000>; + }; + opp03 { + opp-hz = /bits/ 64 <413000000>; + opp-microvolt = <887500>; + }; + opp04 { + opp-hz = /bits/ 64 <543000000>; + opp-microvolt = <937500>; + }; + opp05 { + opp-hz = /bits/ 64 <633000000>; + opp-microvolt = <1012500>; + }; + opp06 { + opp-hz = /bits/ 64 <728000000>; + opp-microvolt = <1037500>; + }; + opp07 { + opp-hz = /bits/ 64 <825000000>; + opp-microvolt = <1050000>; + }; + }; + -- 2.7.4