Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp2632802yba; Mon, 8 Apr 2019 01:00:32 -0700 (PDT) X-Google-Smtp-Source: APXvYqwAO9TYzWZJQBWrY3jX3CCp3fVpH2jdySX2YpMBwvhuoBeMaiCQVafGc8JJDUyDnTvhrET3 X-Received: by 2002:a17:902:be04:: with SMTP id r4mr29274243pls.218.1554710432356; Mon, 08 Apr 2019 01:00:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554710432; cv=none; d=google.com; s=arc-20160816; b=ohC+iH8QvJwyZNBMNdxySzCGMD4BHj3uuWvdNmgDXU0l2wVnlklWxPKue7/t1McuRi skYltfw2+aG18wfp9HjAxWqUrnd1ITH97lno6uDll7eZYCarp0MvZg5tbaI3gFXinznV azXDPMI0AhqrH29CcBOCIQZiLH3zU+oRUXJomLcV5691u/41fqfQESveztPbVk3CBQuY CME5Cp6jadgFpd9PNrxQiSeJ2z7+jAtzw9/HkkfdeIuDdmY15gFasLEyT/RgJ+Y0tMFB QbfGUKn3/MHjcgbO62pRGwN0q9WuX33BIMxhdAZb0nVuVoytmgdcNSQ+ZW98AK69UJ6V E91Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=oco+RqLjRDLjReN+OS1UN1Z5Z9iWM/GxVr51ER1fU8o=; b=Yi3f7cI0yJk0ZHdNMdXpBvtnzqyIXRyPq3DEt7zeimDd/tQgHtMiue/80MldEsM2lp tXhQNyf5HMr/bN31mvpAn8Vtnv/1/qYy5clKRIUGEHxRDX+gv44ymeB9azdIpms6e4bz Z5/PPXvmLBFw/2RJR1R0bKF3NM5ddBvVOwiG65fHeNrf+svoCYgeWPmbIA//rSXz2kH4 sZcYgret9HYPT9uCEfcN+8QZsC0WrN7ckKaCgMKA0U2mz7rPMDcKCW6J0Mcy+acW7lES qRX7yaa2j3LWJMb270k2I9aduwDM7kg/sBMoCn2VI1L3E0hRTsuj7yUROchMweQeOa6Q FbQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bgdev-pl.20150623.gappssmtp.com header.s=20150623 header.b=WsFoC+BP; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l7si2052596pgq.263.2019.04.08.01.00.16; Mon, 08 Apr 2019 01:00:32 -0700 (PDT) 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=@bgdev-pl.20150623.gappssmtp.com header.s=20150623 header.b=WsFoC+BP; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726496AbfDHH7i (ORCPT + 99 others); Mon, 8 Apr 2019 03:59:38 -0400 Received: from mail-wm1-f67.google.com ([209.85.128.67]:53990 "EHLO mail-wm1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726119AbfDHH7g (ORCPT ); Mon, 8 Apr 2019 03:59:36 -0400 Received: by mail-wm1-f67.google.com with SMTP id q16so13139610wmj.3 for ; Mon, 08 Apr 2019 00:59:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=oco+RqLjRDLjReN+OS1UN1Z5Z9iWM/GxVr51ER1fU8o=; b=WsFoC+BPiBGxQAtIvxBqWVRBNqIF9Ua/nKMgxcXLP3hDT/VyVphJmb93BMZ9x2Cb2I 5OegoyFxbhvoQL+HTqWp0l3ms4/yauCihDE7q6F0fHZ5hRhwco/68tnY46/hcAf6y212 Bb3j2VwGKTrWg3SCLgJ1Pb30IJfZymrFnKpfRRGxJ4KrttUTHXpzjB1pdQjwYhT4EZ6b QBlvnQ4uBbcgnNru+chF5x3UQ2SfBNeqhJewNvC/3HqPLtkjGqxcZptv5T7ToV+rDog1 z7huTecS63wIn6I8n6x32VF159RuLJHwZc1TU5tuHjczAK/E2TYNwf/0WFuHNhoNxK6B YHyw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=oco+RqLjRDLjReN+OS1UN1Z5Z9iWM/GxVr51ER1fU8o=; b=IYCrBmqWFaq9zeE4zYcAiU4p2ZQBH2pkCFbDSvEZ0yE57wL7r5nLiU6FYNKTml3GxS QC2Dgbf0VmmBlup3wvZHLkmbgb7qyOfGZVVoRVqkGObEv6MVcxFKsJ5/9Tu3aj0bnULN /f6WKt3SDluxPNJOyZqusZaL2T16URz8rO5oo6M/d7QgVmXg1ozLtpFld0j05Vfili5J 0c1bEXP8lo0bRccsvV7X+Up5cpDLX9SJtHHaG3jsz2SsPpJEOMGvabvgaY03n19aNi4i T1dUo2H7LAZ9PvTpO3gZFREhaahQJFhO1vEU+/FyoSOb4JzLhdmwuVd8IzI7Joj91Bqx igDA== X-Gm-Message-State: APjAAAW+c1HrJEmypYY+zPtypZLhZ8Sc1q5pxeBMGJpueJTjhAUDDL8Y fLaJznCdLySAaxj0dGBgGFALDg== X-Received: by 2002:a1c:1aca:: with SMTP id a193mr17463267wma.40.1554710373954; Mon, 08 Apr 2019 00:59:33 -0700 (PDT) Received: from localhost.localdomain (aputeaux-684-1-12-194.w90-86.abo.wanadoo.fr. [90.86.215.194]) by smtp.gmail.com with ESMTPSA id o17sm31658711wrw.73.2019.04.08.00.59.32 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 08 Apr 2019 00:59:33 -0700 (PDT) From: Bartosz Golaszewski To: Sekhar Nori , Kevin Hilman , Rob Herring , Mark Rutland , David Lechner , Adam Ford Cc: linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH v3 1/3] ARM: dts: da850: add cpu node and operating points to DT Date: Mon, 8 Apr 2019 09:59:22 +0200 Message-Id: <20190408075924.2284-2-brgl@bgdev.pl> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190408075924.2284-1-brgl@bgdev.pl> References: <20190408075924.2284-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: David Lechner This adds a cpu node and operating points to the common da850.dtsi file. Additionally, a regulator is added to the LEGO EV3 board along with some board-specific CPU configuration. Regulators need to be hooked up on other boards to get them working. Signed-off-by: David Lechner Signed-off-by: Bartosz Golaszewski --- arch/arm/boot/dts/da850-lcdk.dts | 31 +++++++++++++++ arch/arm/boot/dts/da850-lego-ev3.dts | 30 +++++++++++++++ arch/arm/boot/dts/da850.dtsi | 56 ++++++++++++++++++++++++++++ 3 files changed, 117 insertions(+) diff --git a/arch/arm/boot/dts/da850-lcdk.dts b/arch/arm/boot/dts/da850-lcdk.dts index 26f453dc8370..f29ed9010812 100644 --- a/arch/arm/boot/dts/da850-lcdk.dts +++ b/arch/arm/boot/dts/da850-lcdk.dts @@ -155,12 +155,43 @@ }; }; }; + + cvdd: regulator0 { + compatible = "regulator-fixed"; + regulator-name = "cvdd"; + regulator-min-microvolt = <1300000>; + regulator-max-microvolt = <1300000>; + regulator-always-on; + regulator-boot-on; + }; }; &ref_clk { clock-frequency = <24000000>; }; +&cpu { + cpu-supply = <&cvdd>; +}; + +/* LCDK has a fixed CVDD of 1.3V, so only op points >= 300MHz are valid */ + +&opp_100 { + status = "disabled"; +}; + +&opp_200 { + status = "disabled"; +}; + +&opp_375 { + status = "okay"; +}; + +&opp_456 { + status = "okay"; +}; + &pmx_core { status = "okay"; diff --git a/arch/arm/boot/dts/da850-lego-ev3.dts b/arch/arm/boot/dts/da850-lego-ev3.dts index 66fcadf0ba91..553717f84483 100644 --- a/arch/arm/boot/dts/da850-lego-ev3.dts +++ b/arch/arm/boot/dts/da850-lego-ev3.dts @@ -125,6 +125,15 @@ amp-supply = <&>; }; + cvdd: regulator0 { + compatible = "regulator-fixed"; + regulator-name = "cvdd"; + regulator-min-microvolt = <1200000>; + regulator-max-microvolt = <1200000>; + regulator-always-on; + regulator-boot-on; + }; + /* * This is a 5V current limiting regulator that is shared by USB, * the sensor (input) ports, the motor (output) ports and the A/DC. @@ -204,6 +213,27 @@ clock-frequency = <24000000>; }; +&cpu { + cpu-supply = <&cvdd>; +}; + +/* since we have a fixed regulator, we can't run at these points */ +&opp_100 { + status = "disabled"; +}; + +&opp_200 { + status = "disabled"; +}; + +/* + * The SoC is actually the 456MHz version, but because of the fixed regulator + * This is the fastest we can go. + */ +&opp_375 { + status = "okay"; +}; + &pmx_core { status = "okay"; diff --git a/arch/arm/boot/dts/da850.dtsi b/arch/arm/boot/dts/da850.dtsi index 559659b399d0..ee61d1253b58 100644 --- a/arch/arm/boot/dts/da850.dtsi +++ b/arch/arm/boot/dts/da850.dtsi @@ -20,6 +20,62 @@ reg = <0xc0000000 0x0>; }; + cpus { + #address-cells = <1>; + #size-cells = <0>; + + cpu: cpu@0 { + compatible = "arm,arm926ej-s"; + device_type = "cpu"; + reg = <0>; + clocks = <&psc0 14>; + operating-points-v2 = <&opp_table>; + }; + }; + + opp_table: opp-table { + compatible = "operating-points-v2"; + + opp_100: opp100-100000000 { + opp-hz = /bits/ 64 <100000000>; + opp-microvolt = <1000000 950000 1050000>; + }; + + opp_200: opp110-200000000 { + opp-hz = /bits/ 64 <200000000>; + opp-microvolt = <1100000 1050000 1160000>; + }; + + opp_300: opp120-300000000 { + opp-hz = /bits/ 64 <300000000>; + opp-microvolt = <1200000 1140000 1320000>; + }; + + /* + * Original silicon was 300MHz max, so higher frequencies + * need to be enabled on a per-board basis if the chip is + * capable. + */ + + opp_375: opp120-375000000 { + status = "disabled"; + opp-hz = /bits/ 64 <375000000>; + opp-microvolt = <1200000 1140000 1320000>; + }; + + opp_415: opp130-415000000 { + status = "disabled"; + opp-hz = /bits/ 64 <415000000>; + opp-microvolt = <1300000 1250000 1350000>; + }; + + opp_456: opp130-456000000 { + status = "disabled"; + opp-hz = /bits/ 64 <456000000>; + opp-microvolt = <1300000 1250000 1350000>; + }; + }; + arm { #address-cells = <1>; #size-cells = <1>; -- 2.21.0