From patchwork Fri Nov 16 10:04:24 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 10685809 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 8B71014E2 for ; Fri, 16 Nov 2018 10:05:47 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 799C128A6A for ; Fri, 16 Nov 2018 10:05:47 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6CDDA29362; Fri, 16 Nov 2018 10:05:47 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id D60CD28A6A for ; Fri, 16 Nov 2018 10:05:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=XoT+mWD/FV+9/zSB7lWPL99n4CsMX8hQjcnHZpihAbk=; b=trFXk9IA5vUWaQ wqnxu3RT4NhJfs3+5IK2fnnDIvCVp1ixDOJalVg613XDmTjoERatFKOwCLBHKMYW7Rbh8GdAvTm2U ZMyeK33FWG8LjX45+gy3ppUhrxLK6dKKFQV3rjn+9iFq0KvlIM6ksNqdZB6rhplYQ1lKW9N8RS9IA 0Honm2vj0P//EMLVxojumYB0Qja5xMv+Z+fdFOJDecN/QPZenU0EtOhJKa2loF82r2xV6/NEMT4i8 fTqe71ROeBY+yvJhFEk9OiA9s8/+gtJYJ6353vRs2yuMhI6QtDazR+dyOGZFyJDyuL50FQJufTEex btduUJRTuiTBPxPZkHTQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb0Q-0008AU-7M; Fri, 16 Nov 2018 10:05:42 +0000 Received: from mail-pg1-x542.google.com ([2607:f8b0:4864:20::542]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNazl-0006ET-P2 for linux-arm-kernel@lists.infradead.org; Fri, 16 Nov 2018 10:05:04 +0000 Received: by mail-pg1-x542.google.com with SMTP id f8-v6so10396584pgq.5 for ; Fri, 16 Nov 2018 02:04:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=6jGnK7p9DNH1VSecCKTpjJESfpN6DrO/lgZIFx1WzcQ=; b=b1U75Cq6PiWwsh0z0qHVgT8KLwnvoLvx19itx4tR0J7yUo4r7wTyFJrjq1gAnh3+a/ DflgwvN3jgsXHSjLZDgoryYD+QBV8BMllSbKnzhPJK5kO2SY3Qta71boyGvWMduiBi+S W0xdwbuvTG67CAHgbzPvoKWe3XXQUnYY4xs8U= 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=6jGnK7p9DNH1VSecCKTpjJESfpN6DrO/lgZIFx1WzcQ=; b=uF6c99mj8+MKfgSqjUxqkZt6DkHjQkER9bTGc0MxfDj05tnKypNm8r73M+i4O8OU3d A8IT0l4m5lvWzBFN3PMmKytyXMd30Aljg5iR0XUnxrRl2c3o178PLOt+v4gG6KbFSkpI 2yM63b8vjHV74NDp3agVHTLZN66g3+5aBPRZ+hkAVu62jIZQgxJKL5TPQflW/U5KKnhI /JCSCSSPpECc7rdn0YO3a37Qecp7GIx6za6llSh19kTFmfDq3bWQ1SXCdmDLVx3Yd77D 4ImsSxdxaIv36ser9mbmW/JYQ1cglABmnbYp7bWhh8GsbC9nmpHMjymBaYWWyhqj5Hre YJYQ== X-Gm-Message-State: AGRZ1gIEIbGDLevPCPlp1bMjVlS62+7jRsps1PMb68uzLCYGuYWhVNXp TmUEb2Ro6jzWDZiBRUofMl/WvQ== X-Google-Smtp-Source: AJdET5eiv3nkhyQJtwSUP/6O1OgfLcn/0KROeaB2kUteVHDIeEdepgLTnigyMH524uMy4UFdhn/3yA== X-Received: by 2002:a62:c501:: with SMTP id j1-v6mr5208284pfg.205.1542362691168; Fri, 16 Nov 2018 02:04:51 -0800 (PST) Received: from localhost ([122.172.88.116]) by smtp.gmail.com with ESMTPSA id h7-v6sm51224721pfd.35.2018.11.16.02.04.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Nov 2018 02:04:50 -0800 (PST) From: Viresh Kumar To: Mark Rutland , Rob Herring , arm@kernel.org, Carlo Caione , Kevin Hilman Subject: [PATCH 01/10] ARM64: dts: amlogic: Add all CPUs in cooling maps Date: Fri, 16 Nov 2018 15:34:24 +0530 Message-Id: <2778d0d4813cc56be851719846afecbab5f2e657.1542362530.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.19.1.568.g152ad8e3369a In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181116_020501_844548_53585CAA X-CRM114-Status: GOOD ( 13.02 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Vincent Guittot , Viresh Kumar , Daniel Lezcano , linux-kernel@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Each CPU can (and does) participate in cooling down the system but the DT only captures a handful of them, normally CPU0, in the cooling maps. Things work by chance currently as under normal circumstances its the first CPU of each cluster which is used by the operating systems to probe the cooling devices. But as soon as this CPU ordering changes and any other CPU is used to bring up the cooling device, we will start seeing failures. Also the DT is rather incomplete when we list only one CPU in the cooling maps, as the hardware doesn't have any such limitations. Update cooling maps to include all devices affected by individual trip points. Signed-off-by: Viresh Kumar Acked-by: Neil Armstrong --- .../dts/amlogic/meson-gxm-khadas-vim2.dts | 22 ++++++++----------- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/arch/arm64/boot/dts/amlogic/meson-gxm-khadas-vim2.dts b/arch/arm64/boot/dts/amlogic/meson-gxm-khadas-vim2.dts index 313f88f8759e..cfc92d06a28f 100644 --- a/arch/arm64/boot/dts/amlogic/meson-gxm-khadas-vim2.dts +++ b/arch/arm64/boot/dts/amlogic/meson-gxm-khadas-vim2.dts @@ -132,19 +132,15 @@ map1 { trip = <&cpu_alert1>; - cooling-device = <&gpio_fan 2 THERMAL_NO_LIMIT>; - }; - - map2 { - trip = <&cpu_alert1>; - cooling-device = - <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; - }; - - map3 { - trip = <&cpu_alert1>; - cooling-device = - <&cpu4 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + cooling-device = <&gpio_fan 2 THERMAL_NO_LIMIT>, + <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu4 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu5 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu6 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu7 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; From patchwork Fri Nov 16 10:04:25 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 10685799 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id E458F14DB for ; Fri, 16 Nov 2018 10:05:18 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D40BE297F0 for ; Fri, 16 Nov 2018 10:05:18 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id C733429CB9; Fri, 16 Nov 2018 10:05:18 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 6BBCB297F0 for ; Fri, 16 Nov 2018 10:05:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=UNr6waaKQ/mmTh92lBb4k4OYJCjigkmFMmRDsFAdhX8=; b=h+Sk94LJ9yMxuY Y5ZGFfesLcrjReN2z2fs6H1AELM5kxXd/w2pbaKwbhVgmgppMVQW0NUo1qGvmOBrzLKpL7h72+/CK iLiPy4xZq54hbNjNBiFe+IN37y5JPN/t+jeu5l90oak6slJwwBBtkcOwApc/iTQ+hwVXEo2gE9Ps8 bja9paAV6pe0wyNI37S4F+j2Dle3b+d3KLto88gaRvCUQhjtwypXNNIFkfpc9OD/v7vNcaYxujM+u t9VyNmvcbAZQmfbIDYwPJYttHyQsN8XRHlt6e9n5HjQ9lkgcRcEogG8XBIXikGYArvzyqBCB5fOma DEch1Lc+FLmMyu9476Rg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNazs-0006ar-Op; Fri, 16 Nov 2018 10:05:08 +0000 Received: from mail-pl1-x644.google.com ([2607:f8b0:4864:20::644]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNazh-0006Eq-EL for linux-arm-kernel@lists.infradead.org; Fri, 16 Nov 2018 10:05:00 +0000 Received: by mail-pl1-x644.google.com with SMTP id t13so7973780ply.13 for ; Fri, 16 Nov 2018 02:04:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=ZJ2Y9BTKWZeThRTPqw9iFrF+TUyLNKnmOqI9tUW0Q7o=; b=hgww5nzdpOv5drIV5f/VTRQQbmLzNZ42o9EZrxtK2aBGiTp7aDszcflfrQ2NbuA8HG qFZydP1nEg7ZXwPLSLpCsBt0e+pT8A36sKcHw/+PghrrI85hpzt4DZ+sI6lOWREXpMii o6ZnWGXimOUqXJf2kmQdgW0rgh5KcTXiMRpl8= 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=ZJ2Y9BTKWZeThRTPqw9iFrF+TUyLNKnmOqI9tUW0Q7o=; b=Autl+kiqOTPv9kIn8CqgfbVEHceC6sQv+MtZcwK9kk7JxrPC9Em/jgXXOPGPcsZAUr X87t8wyvicv1Lc23B9LvfKpPBebRRi5hFy/uJfjJcCRfcHIOWgBOci4aKh0mkXitxUIC 5E1g39rSTmqRHuSZ0Y+mJyspPm97+xODg5Yk5fGQgtTYFujzIHcOlDhkb5s894tXFpvl GENzEm+96SF9RFGL9ycfzhC1bMndvgZpHH68u9VHPf8PTGDmyaW+/ocJMsRRmUyeEI5O gpD5rFizCbi9q3/41U5Zc5KgW/qECUJkNry1modSNDN9CUtOQQ/5XncgEM4Yg0ZY6OKZ zbow== X-Gm-Message-State: AGRZ1gLcSj70G0mQtI63di4zpPXH0Qt2haD0gRYfcVh9DTMrJWqyQuEe NeF5VJ4ZcGmf2XmR9mHnwXbnFQ== X-Google-Smtp-Source: AJdET5fL6OQJKJK0wmhEbl7lT9wsvedSDRZEI4E9Rl5pNHw4TWVRcqikk1hmYVqe0yu59lGvxg23vQ== X-Received: by 2002:a17:902:6a3:: with SMTP id 32-v6mr10371947plh.337.1542362695231; Fri, 16 Nov 2018 02:04:55 -0800 (PST) Received: from localhost ([122.172.88.116]) by smtp.gmail.com with ESMTPSA id h7sm25746283pfa.105.2018.11.16.02.04.54 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Nov 2018 02:04:54 -0800 (PST) From: Viresh Kumar To: Mark Rutland , Rob Herring , arm@kernel.org, Kukjin Kim , Krzysztof Kozlowski Subject: [PATCH 02/10] ARM64: dts: exynos: Add all CPUs in cooling maps Date: Fri, 16 Nov 2018 15:34:25 +0530 Message-Id: <74e23257aece9ceef48b1c1cf6c9bafcce3c6fbd.1542362530.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.19.1.568.g152ad8e3369a In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181116_020457_479051_D7C88039 X-CRM114-Status: GOOD ( 13.47 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, linux-samsung-soc@vger.kernel.org, Vincent Guittot , Viresh Kumar , Daniel Lezcano , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Each CPU can (and does) participate in cooling down the system but the DT only captures a handful of them, normally CPU0, in the cooling maps. Things work by chance currently as under normal circumstances its the first CPU of each cluster which is used by the operating systems to probe the cooling devices. But as soon as this CPU ordering changes and any other CPU is used to bring up the cooling device, we will start seeing failures. Also the DT is rather incomplete when we list only one CPU in the cooling maps, as the hardware doesn't have any such limitations. Update cooling maps to include all devices affected by individual trip points. Signed-off-by: Viresh Kumar --- .../arm64/boot/dts/exynos/exynos5433-tmu.dtsi | 36 ++++++++++++------- 1 file changed, 24 insertions(+), 12 deletions(-) diff --git a/arch/arm64/boot/dts/exynos/exynos5433-tmu.dtsi b/arch/arm64/boot/dts/exynos/exynos5433-tmu.dtsi index fe3a0b14bee6..81b72393dd0d 100644 --- a/arch/arm64/boot/dts/exynos/exynos5433-tmu.dtsi +++ b/arch/arm64/boot/dts/exynos/exynos5433-tmu.dtsi @@ -55,37 +55,44 @@ thermal-zones { map0 { /* Set maximum frequency as 1800MHz */ trip = <&atlas0_alert_0>; - cooling-device = <&cpu4 1 2>; + cooling-device = <&cpu4 1 2>, <&cpu5 1 2>, + <&cpu6 1 2>, <&cpu7 1 2>; }; map1 { /* Set maximum frequency as 1700MHz */ trip = <&atlas0_alert_1>; - cooling-device = <&cpu4 2 3>; + cooling-device = <&cpu4 2 3>, <&cpu5 2 3>, + <&cpu6 2 3>, <&cpu7 2 3>; }; map2 { /* Set maximum frequency as 1600MHz */ trip = <&atlas0_alert_2>; - cooling-device = <&cpu4 3 4>; + cooling-device = <&cpu4 3 4>, <&cpu5 3 4>, + <&cpu6 3 4>, <&cpu7 3 4>; }; map3 { /* Set maximum frequency as 1500MHz */ trip = <&atlas0_alert_3>; - cooling-device = <&cpu4 4 5>; + cooling-device = <&cpu4 4 5>, <&cpu5 4 5>, + <&cpu6 4 5>, <&cpu7 4 5>; }; map4 { /* Set maximum frequency as 1400MHz */ trip = <&atlas0_alert_4>; - cooling-device = <&cpu4 5 7>; + cooling-device = <&cpu4 5 7>, <&cpu5 5 7>, + <&cpu6 5 7>, <&cpu7 5 7>; }; map5 { /* Set maximum frequencyas 1200MHz */ trip = <&atlas0_alert_5>; - cooling-device = <&cpu4 7 9>; + cooling-device = <&cpu4 7 9>, <&cpu5 7 9>, + <&cpu6 7 9>, <&cpu7 7 9>; }; map6 { /* Set maximum frequency as 1000MHz */ trip = <&atlas0_alert_6>; - cooling-device = <&cpu4 9 14>; + cooling-device = <&cpu4 9 14>, <&cpu5 9 14>, + <&cpu6 9 14>, <&cpu7 9 14>; }; }; }; @@ -222,27 +229,32 @@ thermal-zones { map0 { /* Set maximum frequency as 1200MHz */ trip = <&apollo_alert_2>; - cooling-device = <&cpu0 1 2>; + cooling-device = <&cpu0 1 2>, <&cpu1 1 2>, + <&cpu2 1 2>, <&cpu3 1 2>; }; map1 { /* Set maximum frequency as 1100MHz */ trip = <&apollo_alert_3>; - cooling-device = <&cpu0 2 3>; + cooling-device = <&cpu0 2 3>, <&cpu1 2 3>, + <&cpu2 2 3>, <&cpu3 2 3>; }; map2 { /* Set maximum frequency as 1000MHz */ trip = <&apollo_alert_4>; - cooling-device = <&cpu0 3 4>; + cooling-device = <&cpu0 3 4>, <&cpu1 3 4>, + <&cpu2 3 4>, <&cpu3 3 4>; }; map3 { /* Set maximum frequency as 900MHz */ trip = <&apollo_alert_5>; - cooling-device = <&cpu0 4 5>; + cooling-device = <&cpu0 4 5>, <&cpu1 4 5>, + <&cpu2 4 5>, <&cpu3 4 5>; }; map4 { /* Set maximum frequency as 800MHz */ trip = <&apollo_alert_6>; - cooling-device = <&cpu0 5 9>; + cooling-device = <&cpu0 5 9>, <&cpu1 5 9>, + <&cpu2 5 9>, <&cpu3 5 9>; }; }; }; From patchwork Fri Nov 16 10:04:26 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 10685815 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id AE9D014DB for ; Fri, 16 Nov 2018 10:06:14 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9C227287A3 for ; Fri, 16 Nov 2018 10:06:14 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8EC972915F; Fri, 16 Nov 2018 10:06:14 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 0CA31287A3 for ; Fri, 16 Nov 2018 10:06:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=RnZFoKeOOXHSogflC44ycgDJ1jKa7UJe+NdxCBVKoTU=; b=Iu2fgkqcbDjKFj TDYb+5B4DE+7zDJqn4H4tm5ECusXrcWYPtPEeMFFFVjbCcwH8BD4LFdJHWXILN66pWKBBH0gRxq4N ED8Et6N4KyVVLO5A+VBX8d3EsCJATMv+SscJO2gvbY5L96FWM6Iz1MvHxcKQcJ/q8WDF1PM/jygN4 unp3mjOR+cfCR/uHXo6CmcnNMWUwRTuYhg/qMeD0wTeuMRANEbCl+6lU6pt4+M2r3WrBM3DUJjM1T mOYMUr02YyyM/p8xpiqqAT3rxu4A7Kut6Dat1N3Nt4jyq8e/s70/RhIEpj/Jz0jXPu3rCnq7LZeUL c4lE8V6MvnEFJYscLOOQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb0l-0008S0-W0; Fri, 16 Nov 2018 10:06:04 +0000 Received: from mail-pg1-x541.google.com ([2607:f8b0:4864:20::541]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNazu-0006GU-7B for linux-arm-kernel@lists.infradead.org; Fri, 16 Nov 2018 10:05:11 +0000 Received: by mail-pg1-x541.google.com with SMTP id z10so10403287pgp.7 for ; Fri, 16 Nov 2018 02:05:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=oskLWY4mMeTJJ9TYoYBq3J1qg+P8pf5LnWRqIcwKGK8=; b=ATnBdGjgO7zh0Orx+cQY5HgoRJ4l9UbThujztH+bBaMJGHsFpCw1g+uMRsgziODVZb rbecT9tokiUQH9Sxkd6bI6PKhqIioXGKtsSJ80pXMCVb7cLjyKGLCWsapQGglk8SjHYz 3j+FQd43roFL2giLKateOQSrXnm4Je8L7ScME= 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=oskLWY4mMeTJJ9TYoYBq3J1qg+P8pf5LnWRqIcwKGK8=; b=UKjB3gTubApfm+QPHLp2FCFkIoGAKt0IU43Ru0/WNkEPlWvFpmWXfEvhjuSABBkgpi fO6sqb8Anr9OcbdxgmbbrF0am4ANFUoNCLNBLlJXl1Bw/OM6Uekl6Js1Z6P2+H+bmMPA +hK6UHUffMVUnYX11PmCyHQlR4V/4s5yupl3Illg2PEgZTFHiTXRULR7b84mlToTxGAE g6V8+Mq03Gmwf8e9lIBhejVL650RlvCTHmN3Dz7q3JbUczwo6NACgMO9XuaiUbD2jp8r Fuj1PjHWvMbJZcQ1/XN/8OUmJYdNbLAy5XB3dkl2h+EMn+V+8UEzGx3jyaX8K/nrDM4c qWoQ== X-Gm-Message-State: AGRZ1gJV11G9iU1PW0g20Lhgvdrz9zzMuu/vqEkzmWWj7VGEYlMinmkU W2sPo7Km9WY55cvXbQgtC+cjpQ== X-Google-Smtp-Source: AJdET5dREXH8/pgZpQdplTK2PixR+p4HIWciuMrOJU2yRz/F5loN/y1ujUTc6zD5ASZeKRCw1RV7yg== X-Received: by 2002:a63:7a5b:: with SMTP id j27mr9396597pgn.112.1542362699588; Fri, 16 Nov 2018 02:04:59 -0800 (PST) Received: from localhost ([122.172.88.116]) by smtp.gmail.com with ESMTPSA id r2sm10042207pfh.57.2018.11.16.02.04.58 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Nov 2018 02:04:59 -0800 (PST) From: Viresh Kumar To: Mark Rutland , Rob Herring , arm@kernel.org, Shawn Guo , Li Yang Subject: [PATCH 03/10] ARM64: dts: fsl: Add all CPUs in cooling maps Date: Fri, 16 Nov 2018 15:34:26 +0530 Message-Id: X-Mailer: git-send-email 2.19.1.568.g152ad8e3369a In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181116_020510_364229_14D54CAE X-CRM114-Status: GOOD ( 12.95 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Vincent Guittot , Viresh Kumar , Daniel Lezcano , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Each CPU can (and does) participate in cooling down the system but the DT only captures a handful of them, normally CPU0, in the cooling maps. Things work by chance currently as under normal circumstances its the first CPU of each cluster which is used by the operating systems to probe the cooling devices. But as soon as this CPU ordering changes and any other CPU is used to bring up the cooling device, we will start seeing failures. Also the DT is rather incomplete when we list only one CPU in the cooling maps, as the hardware doesn't have any such limitations. Update cooling maps to include all devices affected by individual trip points. Signed-off-by: Viresh Kumar --- .../arm64/boot/dts/freescale/fsl-ls1043a.dtsi | 6 ++-- .../arm64/boot/dts/freescale/fsl-ls1046a.dtsi | 6 ++-- .../arm64/boot/dts/freescale/fsl-ls1088a.dtsi | 17 ++++++----- .../arm64/boot/dts/freescale/fsl-ls208xa.dtsi | 28 ++++++------------- 4 files changed, 24 insertions(+), 33 deletions(-) diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi index 3fed504b5381..c7224c5bb6cc 100644 --- a/arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi +++ b/arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi @@ -171,8 +171,10 @@ map0 { trip = <&cpu_alert>; cooling-device = - <&cpu0 THERMAL_NO_LIMIT - THERMAL_NO_LIMIT>; + <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi index 51cbd50012d6..8c94d8279b5e 100644 --- a/arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi +++ b/arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi @@ -140,8 +140,10 @@ map0 { trip = <&cpu_alert>; cooling-device = - <&cpu0 THERMAL_NO_LIMIT - THERMAL_NO_LIMIT>; + <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1088a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1088a.dtsi index a07f612ab56b..7faee0d270d2 100644 --- a/arch/arm64/boot/dts/freescale/fsl-ls1088a.dtsi +++ b/arch/arm64/boot/dts/freescale/fsl-ls1088a.dtsi @@ -152,15 +152,14 @@ map0 { trip = <&cpu_alert>; cooling-device = - <&cpu0 THERMAL_NO_LIMIT - THERMAL_NO_LIMIT>; - }; - - map1 { - trip = <&cpu_alert>; - cooling-device = - <&cpu4 THERMAL_NO_LIMIT - THERMAL_NO_LIMIT>; + <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu4 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu5 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu6 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu7 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; diff --git a/arch/arm64/boot/dts/freescale/fsl-ls208xa.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls208xa.dtsi index d188774a36e8..f11187f7465c 100644 --- a/arch/arm64/boot/dts/freescale/fsl-ls208xa.dtsi +++ b/arch/arm64/boot/dts/freescale/fsl-ls208xa.dtsi @@ -101,26 +101,14 @@ map0 { trip = <&cpu_alert>; cooling-device = - <&cpu0 THERMAL_NO_LIMIT - THERMAL_NO_LIMIT>; - }; - map1 { - trip = <&cpu_alert>; - cooling-device = - <&cpu2 THERMAL_NO_LIMIT - THERMAL_NO_LIMIT>; - }; - map2 { - trip = <&cpu_alert>; - cooling-device = - <&cpu4 THERMAL_NO_LIMIT - THERMAL_NO_LIMIT>; - }; - map3 { - trip = <&cpu_alert>; - cooling-device = - <&cpu6 THERMAL_NO_LIMIT - THERMAL_NO_LIMIT>; + <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu4 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu5 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu6 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu7 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; From patchwork Fri Nov 16 10:04:27 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 10685817 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 958DB14E2 for ; Fri, 16 Nov 2018 10:06:46 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 843BF287A3 for ; Fri, 16 Nov 2018 10:06:46 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7848B2915F; Fri, 16 Nov 2018 10:06:46 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id EECF0287A3 for ; Fri, 16 Nov 2018 10:06:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=mEtilHsvksQZVD/YNnJ6jonr8XGp1PVdCXmj7g4O8+k=; b=RVXzb5WysxwufM zVEuWPRzONIwTx3JKXe4UVndvMN0dBxzVsLZN9mVSMkgMRhUqy0z7EC6OUdVIzgQzcNmcW8DLQ13r 6E1bBYhMepyartYCebUtuCiWzxNZWHXABm1Q2RTxwdXSPsfBUnBK/HaZ6aXcs3fWPvd7nxL8ea4QI SUfHNvgHfY6hBmdVZEiQHRjicoHKCabei5BElddxWr9MHYOAgEGUvhddaCbXazY4bYS6RKWo3Q5JG 01PwkPQO4jNpL6GjVGrNsjQnK2117Y+YaD7x9rtbQcUgLYDpP7vcqxbd3WwWVqXoL8bQ88A6xk32I Xu8bYzGRbnnUPpPTfc4w==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb1M-0000Zh-RB; Fri, 16 Nov 2018 10:06:40 +0000 Received: from mail-pg1-x544.google.com ([2607:f8b0:4864:20::544]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb00-0006Sw-CH for linux-arm-kernel@lists.infradead.org; Fri, 16 Nov 2018 10:05:17 +0000 Received: by mail-pg1-x544.google.com with SMTP id 32-v6so10410037pgu.2 for ; Fri, 16 Nov 2018 02:05:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=HClVvGiwOuWgQ6TjJ14HNKIrS62CNCv2+c1OlYODQLQ=; b=EYgZ6R/GukaNgdoqsL+uxEcbK4u50GApx9Jrvrdq5PtjcvbOzdKihSLY8qHyk4JUah JmTUeiVCXXf0NaYEjIQgSxfEqzMrhj2guSYLHqQs7ijcz+wlMZZbhmO5xNnUky32xYNo fr7LO3IgRE/Gm4kOImnuv0ghPrZqulGfKR3WI= 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=HClVvGiwOuWgQ6TjJ14HNKIrS62CNCv2+c1OlYODQLQ=; b=L8Jp7GxLcS4XLysKvXxUA9ZbYIwVfcZw5U0WJfBzsg6E6oGjRmawNUIWtbvztCUHOt kAhYFf7Q5fafVTq54d2N6zZrVUmEd999fTjM9j4gEvO5P15dAhrQ0ierqMKj/Lzj6J7c 9mMvy2kp42eBeZ1ZWStikiEvQ8LH2h7UDcaE8pAN2TpfVwK9Msa7mAfFK9ndh8C82U0t gqOi2hyDyYWOu3pLxnW5itSqgP5J+gb/jyVqxMhOuobvfHz9gWJpnXkp3jrIe8JaPslW iv7EDdQ3Dhg+UgxI8XIwHBM3Tm1l5iYFh2Bl1habuzf8ERPss9x/AcJB+uCaHiBqiTbY TgTQ== X-Gm-Message-State: AGRZ1gKuxWd532xVE8+KJBv1jXhvFgL4I0UoYe36yZ7CgdLPaS59RCT7 NkK/YeLC74fH2Fg2BXWBT2gCQw== X-Google-Smtp-Source: AJdET5cORx44UTQ4adNwvGIigFS0ZpcMALU2BSxZXv3g94Lib06777UYHkmWoxoxwF6PydFVvWvZIw== X-Received: by 2002:a63:9a52:: with SMTP id e18mr9300065pgo.14.1542362705320; Fri, 16 Nov 2018 02:05:05 -0800 (PST) Received: from localhost ([122.172.88.116]) by smtp.gmail.com with ESMTPSA id y9-v6sm32421519pfe.152.2018.11.16.02.05.04 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Nov 2018 02:05:04 -0800 (PST) From: Viresh Kumar To: Mark Rutland , Rob Herring , arm@kernel.org, Wei Xu Subject: [PATCH 04/10] arm64: dts: hi3660: Add missing cooling device properties for CPUs Date: Fri, 16 Nov 2018 15:34:27 +0530 Message-Id: <042e5e647a7b54f4322024f1b3e286b6b6d69175.1542362530.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.19.1.568.g152ad8e3369a In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181116_020516_433541_5B1202F0 X-CRM114-Status: GOOD ( 12.86 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Vincent Guittot , Viresh Kumar , Daniel Lezcano , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP The cooling device properties, like "#cooling-cells" and "dynamic-power-coefficient", should either be present for all the CPUs of a cluster or none. If these are present only for a subset of CPUs of a cluster then things will start falling apart as soon as the CPUs are brought online in a different order. For example, this will happen because the operating system looks for such properties in the CPU node it is trying to bring up, so that it can register a cooling device. Add such missing properties. Signed-off-by: Viresh Kumar --- arch/arm64/boot/dts/hisilicon/hi3660.dtsi | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/arch/arm64/boot/dts/hisilicon/hi3660.dtsi b/arch/arm64/boot/dts/hisilicon/hi3660.dtsi index f432b0a88c65..d943a96eedee 100644 --- a/arch/arm64/boot/dts/hisilicon/hi3660.dtsi +++ b/arch/arm64/boot/dts/hisilicon/hi3660.dtsi @@ -79,6 +79,7 @@ capacity-dmips-mhz = <592>; clocks = <&stub_clock HI3660_CLK_STUB_CLUSTER0>; operating-points-v2 = <&cluster0_opp>; + #cooling-cells = <2>; }; cpu2: cpu@2 { @@ -91,6 +92,7 @@ capacity-dmips-mhz = <592>; clocks = <&stub_clock HI3660_CLK_STUB_CLUSTER0>; operating-points-v2 = <&cluster0_opp>; + #cooling-cells = <2>; }; cpu3: cpu@3 { @@ -103,6 +105,7 @@ capacity-dmips-mhz = <592>; clocks = <&stub_clock HI3660_CLK_STUB_CLUSTER0>; operating-points-v2 = <&cluster0_opp>; + #cooling-cells = <2>; }; cpu4: cpu@100 { @@ -129,6 +132,7 @@ capacity-dmips-mhz = <1024>; clocks = <&stub_clock HI3660_CLK_STUB_CLUSTER1>; operating-points-v2 = <&cluster1_opp>; + #cooling-cells = <2>; }; cpu6: cpu@102 { @@ -141,6 +145,7 @@ capacity-dmips-mhz = <1024>; clocks = <&stub_clock HI3660_CLK_STUB_CLUSTER1>; operating-points-v2 = <&cluster1_opp>; + #cooling-cells = <2>; }; cpu7: cpu@103 { @@ -153,6 +158,7 @@ capacity-dmips-mhz = <1024>; clocks = <&stub_clock HI3660_CLK_STUB_CLUSTER1>; operating-points-v2 = <&cluster1_opp>; + #cooling-cells = <2>; }; idle-states { From patchwork Fri Nov 16 10:04:28 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 10685821 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 75C6B14E2 for ; Fri, 16 Nov 2018 10:07:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 649AB287A3 for ; Fri, 16 Nov 2018 10:07:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 58B122915F; Fri, 16 Nov 2018 10:07:24 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id E8099287A3 for ; Fri, 16 Nov 2018 10:07:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=3/uNXqyCxFZ0yo3DPRA9SoO9RKJu+A/4HJaQIcfvS0c=; b=tVWX/DL/FpwRJ5 V3RfayOxQqjJinQqjh/mgVaNICNGwjyxemPZv6C7FDecx7VhLelwSjC7ukVsCuHswUSxWiKytfN+p 8ziTQgO//ynGgTU8sRMho4sC0j5+aaDNcD1oPM7VeXMyTPdARk0oz2hzNyP8aB9wMMZ3znySv3HMd +IwlacPFw+zlTFmACkiKT8dnlgQzG2dCuyv8TuXA+78i4t/krVFaw2opOyj1VDd6QN928LvNVcVZf nveTqug08zJOKLA5sjIAAppZa1tQRSWmbyaA+u8+uEyMnLfhiapnD8APy9lx2F4z2TYpMgx8EqLe8 gv8wq8E7ELkY5hMnmHhA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb1z-0001AL-7T; Fri, 16 Nov 2018 10:07:19 +0000 Received: from mail-pl1-x643.google.com ([2607:f8b0:4864:20::643]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb04-0006lo-Hl for linux-arm-kernel@lists.infradead.org; Fri, 16 Nov 2018 10:05:26 +0000 Received: by mail-pl1-x643.google.com with SMTP id b5-v6so10949614pla.6 for ; Fri, 16 Nov 2018 02:05:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=QmjHQrzH3LPsysyMlkzh+Qm9rUsTXjJj/VyKPq1LnW8=; b=El0fMUQ3VTzNvHQ+No7yCC641xxRow2h2idrjFaDry9uLyyOekkFxoZPs17XGeLHtg Qr+tx6cU+FPu4OeX1wU737un2FszbXEtLjxKgMbXBLq1kjDeLP+HFFlya1yVbtwXrrXw sExaUXVj7dZcDR6VJ5rZgPdZZ9aqwTbf4gfwM= 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=QmjHQrzH3LPsysyMlkzh+Qm9rUsTXjJj/VyKPq1LnW8=; b=P4rZ0kyWaJXr6t0z4DvEWh5r/zu9c4dKQ+OLTNfSQA8z+dFngW9rwCRdGSzaqbZxYN zqiSuOh/C1uYt4mFkbfw0+o0RceweHCzM4k0oUaAhXzx62wsSJrx2cbnOSeO/n3cod6N +SQHjoNt92hAx7uJ2Lyv2AWjT7E+mnyIf6h9SBA8+0QdD9PFWr4BDl5z0U4CJNEQEgbZ fxH5W7KtDBEzG23NmxBOqy38IBNFHhKMSOH29zbrN2zMNRsaV5qL0hw5mwSrTYLLHfGD BLqwDWME8aQfiyPv2ugitlWfsr1kIJEK6TeUizWCGAs/RR30WjCqWt15mIi+gfTD7lV+ h3+w== X-Gm-Message-State: AGRZ1gLIombai2ntAdmOK2LZZcYQVsfO+mXrYteDKRwvJcuXZzQMnyZz sBuyxi2IQQBADy1dxu85TjcBYg== X-Google-Smtp-Source: AJdET5dzsVUVn0P59zjnuOoXv1A6JX0AvMsNwHLSVXEau9JNGRYmlpZCfpGhgRrFE0MWePflodTgQg== X-Received: by 2002:a17:902:a70b:: with SMTP id w11mr6181411plq.84.1542362709696; Fri, 16 Nov 2018 02:05:09 -0800 (PST) Received: from localhost ([122.172.88.116]) by smtp.gmail.com with ESMTPSA id s22-v6sm56173002pfi.15.2018.11.16.02.05.08 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Nov 2018 02:05:09 -0800 (PST) From: Viresh Kumar To: Mark Rutland , Rob Herring , arm@kernel.org, Wei Xu Subject: [PATCH 05/10] ARM64: dts: hisilicon: Add all CPUs in cooling maps Date: Fri, 16 Nov 2018 15:34:28 +0530 Message-Id: <89bb8c62404aa875d597da89c18852ce81fb9f26.1542362530.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.19.1.568.g152ad8e3369a In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181116_020520_689122_1E1AC2C7 X-CRM114-Status: GOOD ( 13.66 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Vincent Guittot , Viresh Kumar , Daniel Lezcano , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Each CPU can (and does) participate in cooling down the system but the DT only captures a handful of them, normally CPU0, in the cooling maps. Things work by chance currently as under normal circumstances its the first CPU of each cluster which is used by the operating systems to probe the cooling devices. But as soon as this CPU ordering changes and any other CPU is used to bring up the cooling device, we will start seeing failures. Also the DT is rather incomplete when we list only one CPU in the cooling maps, as the hardware doesn't have any such limitations. Update cooling maps to include all devices affected by individual trip points. Signed-off-by: Viresh Kumar --- arch/arm64/boot/dts/hisilicon/hi3660.dtsi | 10 ++++++++-- arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 9 ++++++++- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/arch/arm64/boot/dts/hisilicon/hi3660.dtsi b/arch/arm64/boot/dts/hisilicon/hi3660.dtsi index d943a96eedee..20ae40df61d5 100644 --- a/arch/arm64/boot/dts/hisilicon/hi3660.dtsi +++ b/arch/arm64/boot/dts/hisilicon/hi3660.dtsi @@ -1118,12 +1118,18 @@ map0 { trip = <&target>; contribution = <1024>; - cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; map1 { trip = <&target>; contribution = <512>; - cooling-device = <&cpu4 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + cooling-device = <&cpu4 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu5 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu6 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu7 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; diff --git a/arch/arm64/boot/dts/hisilicon/hi6220.dtsi b/arch/arm64/boot/dts/hisilicon/hi6220.dtsi index 97d5bf2c6ec5..aec9e371c2a7 100644 --- a/arch/arm64/boot/dts/hisilicon/hi6220.dtsi +++ b/arch/arm64/boot/dts/hisilicon/hi6220.dtsi @@ -893,7 +893,14 @@ cooling-maps { map0 { trip = <&target>; - cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu4 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu5 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu6 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu7 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; From patchwork Fri Nov 16 10:04:29 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 10685819 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 41D7914DB for ; Fri, 16 Nov 2018 10:07:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2FF99287A3 for ; Fri, 16 Nov 2018 10:07:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 20F6B2915F; Fri, 16 Nov 2018 10:07:15 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 8E870287A3 for ; Fri, 16 Nov 2018 10:07:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=c+Cccx5/JwdsT14VmXHcjkAct1y9Xuu1tig2XVV6Rnw=; b=IZ4kpOUR/lxiNX SRzhxUQtBAjzmYjHAFxCvPU8UGIS2LujhDGVJXBsKMkXA5fNNRgGw2+w1gyoyZUqTtsyjj3FaMM5p YsVhVN8Or7tbkTcy5rM/2VjmWVLK3bwLZWVc8c205z3WCNPUYeZT1i2pttRn+yLpgxfcwsuJKepOJ Mqnhsu5Ks3P71wez406tDo87DWGUS8uE/6EE9QIQ5IApIGBAvbHuB/d9VwvQHAvn0Tiy9ywxzzdHO oZiiCiReOWj6osOsVKeXwcK5+U6ombD9h24EBKe+KuS4nqIyMSgoC8MUANonXU04qvjQ0rm+rCb0/ S27A+2Lm+FCu1igbrNkQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb1h-0000tv-QP; Fri, 16 Nov 2018 10:07:01 +0000 Received: from mail-pf1-x444.google.com ([2607:f8b0:4864:20::444]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb09-0007LV-F2 for linux-arm-kernel@lists.infradead.org; Fri, 16 Nov 2018 10:05:27 +0000 Received: by mail-pf1-x444.google.com with SMTP id e22-v6so11172366pfn.8 for ; Fri, 16 Nov 2018 02:05:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=RnCIsEGq5MZTTZCkNy8l3CMIA4bwOFY/LPw8vXjcyjo=; b=T+iqTvBvTwFjGud//iZpTeH9leHdAkXHiolZPRv3m8YPKwjf2NcPiFwBMBs7pPsl7i R5glNd1K+psMyhUEK1DQEqo7NLCNyyuPWywmWuqlnBOqjjuysRuc+lDVK/lwYT+9t6dK KFeF0TCLS7C54iI2qZj7AIdlKNDijQ52Ooaf8= 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=RnCIsEGq5MZTTZCkNy8l3CMIA4bwOFY/LPw8vXjcyjo=; b=oyCkHBiggNOJtbvxJpSSFjU/MPEK2BxejugOD8kgo9KAIQVzNhN2yVPh0l3j8l/m2a 8KkA4j78y2H56WU5uMTcKsIiHjVbU3zAniNWLZ1jjawCg8NIXnouzLfS344Eo653Df1+ h6DaNKTSPmn5eQ3bo0NWYUqLOLMdU3drbuU6lF5V/KsrwwgOOkAQxWr2lUJB1IKXElV2 U6n/g/8Nwbk8EjhiwEkCjUM48uawjJfhCHcOfq8ZweCU0kI281Oqr8v5386NeLDHglNL hhbRPLN6kZat1VTIFYW98Q1NC5xdil1fpfnX40qaptiq85tRl2dpPJ4nGF5sDqYNnb7A kMMQ== X-Gm-Message-State: AGRZ1gJWz76j2D2a9c/Pu4NlTHyd0pKyU6lB4a81BQHUTG92n4z/3rqE tksgNCKE8mEtfErpf+fNVaq17g== X-Google-Smtp-Source: AJdET5fag+/4M4Kh2zoKCTv3gSeGIG7dumpyvhJU29YRSRveHS/q5GVSeYkuhb45R2PZnJAZr4G4Yw== X-Received: by 2002:a63:314c:: with SMTP id x73mr9435566pgx.323.1542362714354; Fri, 16 Nov 2018 02:05:14 -0800 (PST) Received: from localhost ([122.172.88.116]) by smtp.gmail.com with ESMTPSA id u76-v6sm41233381pfa.176.2018.11.16.02.05.12 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Nov 2018 02:05:13 -0800 (PST) From: Viresh Kumar To: Mark Rutland , Rob Herring , arm@kernel.org, Matthias Brugger Subject: [PATCH 06/10] ARM64: dts: mediatek: Add all CPUs in cooling maps Date: Fri, 16 Nov 2018 15:34:29 +0530 Message-Id: <3c7c9155ac01a2d745ba5e4434c958820200d088.1542362530.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.19.1.568.g152ad8e3369a In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181116_020525_506019_3E6CC568 X-CRM114-Status: GOOD ( 14.66 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Vincent Guittot , Viresh Kumar , Daniel Lezcano , linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Each CPU can (and does) participate in cooling down the system but the DT only captures a handful of them, normally CPU0, in the cooling maps. Things work by chance currently as under normal circumstances its the first CPU of each cluster which is used by the operating systems to probe the cooling devices. But as soon as this CPU ordering changes and any other CPU is used to bring up the cooling device, we will start seeing failures. Also the DT is rather incomplete when we list only one CPU in the cooling maps, as the hardware doesn't have any such limitations. Update cooling maps to include all devices affected by individual trip points. Signed-off-by: Viresh Kumar --- arch/arm64/boot/dts/mediatek/mt7622.dtsi | 9 ++++++--- arch/arm64/boot/dts/mediatek/mt8173.dtsi | 6 ++++-- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/arch/arm64/boot/dts/mediatek/mt7622.dtsi b/arch/arm64/boot/dts/mediatek/mt7622.dtsi index fe0c875f1d95..53e707df98d9 100644 --- a/arch/arm64/boot/dts/mediatek/mt7622.dtsi +++ b/arch/arm64/boot/dts/mediatek/mt7622.dtsi @@ -170,17 +170,20 @@ cooling-maps { map0 { trip = <&cpu_passive>; - cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; map1 { trip = <&cpu_active>; - cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; map2 { trip = <&cpu_hot>; - cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; diff --git a/arch/arm64/boot/dts/mediatek/mt8173.dtsi b/arch/arm64/boot/dts/mediatek/mt8173.dtsi index abd2f15a544b..e578f7d18038 100644 --- a/arch/arm64/boot/dts/mediatek/mt8173.dtsi +++ b/arch/arm64/boot/dts/mediatek/mt8173.dtsi @@ -275,12 +275,14 @@ cooling-maps { map@0 { trip = <&target>; - cooling-device = <&cpu0 0 0>; + cooling-device = <&cpu0 0 0>, + <&cpu1 0 0>; contribution = <3072>; }; map@1 { trip = <&target>; - cooling-device = <&cpu2 0 0>; + cooling-device = <&cpu2 0 0>, + <&cpu3 0 0>; contribution = <1024>; }; }; From patchwork Fri Nov 16 10:04:30 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 10685825 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 79C7714DB for ; Fri, 16 Nov 2018 10:07:52 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 63FC1287A3 for ; Fri, 16 Nov 2018 10:07:52 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 575282915F; Fri, 16 Nov 2018 10:07:52 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 201BA287A3 for ; Fri, 16 Nov 2018 10:07:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=JiorTX9jyHmvvPfDI3k5PxEb9lC3srBBo2ovUkF2CBM=; b=uquM3lI6DgJaMB hBus9Ib7SQW4ZtGNu/OcqvE5/Ki/vV5Qu4/A+L4kckhtrV2VJ9DEpGinwGw0sDJa0PTO4VYiwKcIV Fj82MXWwlMZNtJCuUwYAAOxo7r3oCinWCpzGnutNJa7xdCGIwrkCe/g+//EAeR8RdGe4+JZJxppIb iXZtRx5e20ALq19F0vQ8u+fgNUplqlXWvke6SVBqGOAi6glGH4yvXWrwk7FhlQ/NLIxKrTyLTYu+6 8a/sapG25FYg4WkHFJV38felGvddzwS4xHzEhp1JquDqLY+tpbuHuKfXFqNgKIctsHy4zFNXTjJiN xcc0uaqQZ/ZE8d3GDOzA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb2J-0001Uv-Tr; Fri, 16 Nov 2018 10:07:39 +0000 Received: from mail-pg1-x542.google.com ([2607:f8b0:4864:20::542]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb0D-0007kZ-TM for linux-arm-kernel@lists.infradead.org; Fri, 16 Nov 2018 10:05:36 +0000 Received: by mail-pg1-x542.google.com with SMTP id f8-v6so10397217pgq.5 for ; Fri, 16 Nov 2018 02:05:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=HuDFUrU28J59C1sp5glUdfijZEsUqR6FAQUgWuELHt4=; b=HqdsL4I1tJ9nEYhjZeVAExIPh2XFK7J0bCcMgpeAYiWvOIi27WouWHqsYtCaJ6z1hc wqGYfgkJxX3PX1+58Oxj5bzXZw9PFuBmVpMxJ7dM1H9AOyc/KI9HoqAQM5e9bc3xWZOz TodNwflfBk/2lqobqd23l3p6RBUKVucHrA3ho= 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=HuDFUrU28J59C1sp5glUdfijZEsUqR6FAQUgWuELHt4=; b=oqsw9U3Tb7ppq+Zy9HkBtrCZs2/P3cxXiOt+2Szql2fRytDwOY9WSI3p+toe0ttsZI btUmJk/o7Sc6ksfY6y+CswahhlY6huie3m9R1mx5FS1z8X5O6cT/B7RazCa/uQQOCFs0 kkgPX38eGyD6RTkE4hWZuCsR/6DJe4Oaou+E7CZlz34Vl673pDTw8VPmUmQOp2isXxQ/ Dty95HnLRydX3JsKU6GrHvRqNOLQEtsvdOihbbuqYxdHdZ6iVTh3l0KqAntzSKycP110 jeqerohykfA9pNwZyXTlaXly3fC/YMQz0uNn6rRFxcFtR2YWekA+xEG/yfCC/DsvdqBI JQyg== X-Gm-Message-State: AGRZ1gLRp+WCbqCDaqqmm5NCMyOEIj8n7emu9/ckODSDR/xdxrIuZ8gV hFJTaDa5Ul6/A0JXmUic+8Ivf5K8Cbk= X-Google-Smtp-Source: AJdET5dHny/jRZrI6uDp+du0UONoToFOu6s5PNBwV124fVGbL1L8ifCBwYWM3j+/tzlD0VXOvCxDkA== X-Received: by 2002:a63:82c6:: with SMTP id w189mr9454796pgd.344.1542362719182; Fri, 16 Nov 2018 02:05:19 -0800 (PST) Received: from localhost ([122.172.88.116]) by smtp.gmail.com with ESMTPSA id t26-v6sm48373412pfa.158.2018.11.16.02.05.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Nov 2018 02:05:18 -0800 (PST) From: Viresh Kumar To: Mark Rutland , Rob Herring , arm@kernel.org, Andy Gross , David Brown Subject: [PATCH 07/10] ARM64: dts: msm8916: Add all CPUs in cooling maps Date: Fri, 16 Nov 2018 15:34:30 +0530 Message-Id: <01bb903b2febf4b006f28fad33308cc8084ccbaf.1542362530.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.19.1.568.g152ad8e3369a In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181116_020529_977058_70BD09A0 X-CRM114-Status: GOOD ( 14.11 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Vincent Guittot , Viresh Kumar , Daniel Lezcano , linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Each CPU can (and does) participate in cooling down the system but the DT only captures a handful of them, normally CPU0, in the cooling maps. Things work by chance currently as under normal circumstances its the first CPU of each cluster which is used by the operating systems to probe the cooling devices. But as soon as this CPU ordering changes and any other CPU is used to bring up the cooling device, we will start seeing failures. Also the DT is rather incomplete when we list only one CPU in the cooling maps, as the hardware doesn't have any such limitations. Update cooling maps to include all devices affected by individual trip points. Signed-off-by: Viresh Kumar --- arch/arm64/boot/dts/qcom/msm8916.dtsi | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/msm8916.dtsi b/arch/arm64/boot/dts/qcom/msm8916.dtsi index d302d8d639a1..482e275f0a03 100644 --- a/arch/arm64/boot/dts/qcom/msm8916.dtsi +++ b/arch/arm64/boot/dts/qcom/msm8916.dtsi @@ -202,7 +202,10 @@ cooling-maps { map0 { trip = <&cpu_alert0>; - cooling-device = <&CPU0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + cooling-device = <&CPU0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&CPU1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&CPU2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&CPU3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; @@ -229,7 +232,10 @@ cooling-maps { map0 { trip = <&cpu_alert1>; - cooling-device = <&CPU0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + cooling-device = <&CPU0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&CPU1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&CPU2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&CPU3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; From patchwork Fri Nov 16 10:04:31 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 10685827 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 84EB814DB for ; Fri, 16 Nov 2018 10:08:14 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 73420287A3 for ; Fri, 16 Nov 2018 10:08:14 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 673F22915F; Fri, 16 Nov 2018 10:08:14 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id EF138287A3 for ; Fri, 16 Nov 2018 10:08:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=Jk020gE5zvxwytG1IxcjfSBsz0W+OIhwVAV2P5WxLMg=; b=L/dEavXE0icot3 ezPBbv4tgouSeNJFcZyAKZ+GwLZCrasKiK5WmiztFRVLIUJL48gBts5SGI+wujUUAjLUkTwxwoMZG TvaitKypKgkcTaw3x0H04ke3tjdzOGbBJGg0FOErcbX3tSRRuOPtFfGePYwOD1ceaksuo4mB0ZTgN 0e/699fgfi7s/EYu3rB+JG1s4Y+lpKbRc8a4uT6nabbVEJqC20PAkokn0huCMKVM7KtG4BHI8BFu8 AJFYo44peL5/kS97o45vlfYAESqM07VSeK7EOPGQjslHOBnsO565oA+q2+qUe/ENGSlEN3IdvBb08 Geksh388UVcGVbMvk39A==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb2h-0001oq-Km; Fri, 16 Nov 2018 10:08:03 +0000 Received: from mail-pl1-x642.google.com ([2607:f8b0:4864:20::642]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb0I-0007or-EJ for linux-arm-kernel@lists.infradead.org; Fri, 16 Nov 2018 10:05:40 +0000 Received: by mail-pl1-x642.google.com with SMTP id w22-v6so10954172plk.0 for ; Fri, 16 Nov 2018 02:05:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=SF62PrzKsc3DFSelUulAf5/CE9NMeGCTdyY77HTuy1c=; b=PnpCbbhTW06C0H0dmVz2PQDq+LdWEyZzDI+ZgwXXfb6wI7dbqTUiEw94Mwr/E4LoMc V+U3PTjh02eBJW5jd+RWoMOA9XgiSQarp7dTK9y7zpBDVwlGDMm/VLI7DZvtG+RwhvsR VLw1jZupl3w/fHsQbTjVOr0fNbgzu92fqrp3o= 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=SF62PrzKsc3DFSelUulAf5/CE9NMeGCTdyY77HTuy1c=; b=PhGle2njNYUIFv7KN/1I+4e8DNT90NfC6jIKi0mAWSMypwA9hdTU0aAnK7cBrApIlT jgl8ZnlMz5rvUsIhsenwT3r1/dUWmDKgGU8A7jLq5fHOIp+/hvgnYgHU/MygHZYerX48 RfumJ4sXDLempfBtkwlzYveK2mjurvKR4mYCou+g3SfgFm/VQ1n2Sa40oRbuj0hxBc30 isV73sCwlooCWkXMXzDE/C1kzTNXl9NcQ6YQM+jQ9TnXbf7rMgGc0yq4iK/ZDTPji+qw Y3QNw+ppMD+a+2mkGlyepN2oTzKGAtAJ2T+kwBSMByL20jAVCeyz2Pl2LkQ7ceSDXHl3 5S4g== X-Gm-Message-State: AGRZ1gI/HMbxqU2arPqFsMcz63bc/LJLglLHk+tnTOSGa8NRZrLeOISF hjWSOmF3p+R7BYIa6YMVQkXyVw== X-Google-Smtp-Source: AJdET5egE/u+vdbiW4gAR2BSipj0p0ZhT8QMmGfDO7ULuxLK8+VBXWs3TPmG96Hqf//6NrpzTKb7Dg== X-Received: by 2002:a17:902:3143:: with SMTP id w61-v6mr10080122plb.58.1542362723769; Fri, 16 Nov 2018 02:05:23 -0800 (PST) Received: from localhost ([122.172.88.116]) by smtp.gmail.com with ESMTPSA id q145-v6sm97195004pfq.143.2018.11.16.02.05.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Nov 2018 02:05:23 -0800 (PST) From: Viresh Kumar To: Mark Rutland , Rob Herring , arm@kernel.org, Simon Horman , Magnus Damm Subject: [PATCH 08/10] ARM64: dts: renesas: Add all CPUs in cooling maps Date: Fri, 16 Nov 2018 15:34:31 +0530 Message-Id: X-Mailer: git-send-email 2.19.1.568.g152ad8e3369a In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181116_020534_483007_8CDCBDB9 X-CRM114-Status: GOOD ( 14.10 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Vincent Guittot , Viresh Kumar , Daniel Lezcano , linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Each CPU can (and does) participate in cooling down the system but the DT only captures a handful of them, normally CPU0, in the cooling maps. Things work by chance currently as under normal circumstances its the first CPU of each cluster which is used by the operating systems to probe the cooling devices. But as soon as this CPU ordering changes and any other CPU is used to bring up the cooling device, we will start seeing failures. Also the DT is rather incomplete when we list only one CPU in the cooling maps, as the hardware doesn't have any such limitations. Update cooling maps to include all devices affected by individual trip points. Signed-off-by: Viresh Kumar --- arch/arm64/boot/dts/renesas/r8a7795.dtsi | 15 ++++++++++++--- arch/arm64/boot/dts/renesas/r8a7796.dtsi | 6 +++--- 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/arch/arm64/boot/dts/renesas/r8a7795.dtsi b/arch/arm64/boot/dts/renesas/r8a7795.dtsi index a79c8d369e0b..3a662df32143 100644 --- a/arch/arm64/boot/dts/renesas/r8a7795.dtsi +++ b/arch/arm64/boot/dts/renesas/r8a7795.dtsi @@ -2878,7 +2878,10 @@ cooling-maps { map0 { trip = <&sensor1_passive>; - cooling-device = <&a57_0 4 4>; + cooling-device = <&a57_0 4 4>, + <&a57_1 4 4>, + <&a57_2 4 4>, + <&a57_3 4 4>; }; }; }; @@ -2904,7 +2907,10 @@ cooling-maps { map0 { trip = <&sensor2_passive>; - cooling-device = <&a57_0 4 4>; + cooling-device = <&a57_0 4 4>, + <&a57_1 4 4>, + <&a57_2 4 4>, + <&a57_3 4 4>; }; }; }; @@ -2930,7 +2936,10 @@ cooling-maps { map0 { trip = <&sensor3_passive>; - cooling-device = <&a57_0 4 4>; + cooling-device = <&a57_0 4 4>, + <&a57_1 4 4>, + <&a57_2 4 4>, + <&a57_3 4 4>; }; }; }; diff --git a/arch/arm64/boot/dts/renesas/r8a7796.dtsi b/arch/arm64/boot/dts/renesas/r8a7796.dtsi index 1ec6aaa520c1..dd95e937f87a 100644 --- a/arch/arm64/boot/dts/renesas/r8a7796.dtsi +++ b/arch/arm64/boot/dts/renesas/r8a7796.dtsi @@ -2526,7 +2526,7 @@ cooling-maps { map0 { trip = <&sensor1_passive>; - cooling-device = <&a57_0 5 5>; + cooling-device = <&a57_0 5 5>, <&a57_1 5 5>; }; }; }; @@ -2552,7 +2552,7 @@ cooling-maps { map0 { trip = <&sensor2_passive>; - cooling-device = <&a57_0 5 5>; + cooling-device = <&a57_0 5 5>, <&a57_1 5 5>; }; }; }; @@ -2578,7 +2578,7 @@ cooling-maps { map0 { trip = <&sensor3_passive>; - cooling-device = <&a57_0 5 5>; + cooling-device = <&a57_0 5 5>, <&a57_1 5 5>; }; }; }; From patchwork Fri Nov 16 10:04:32 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 10685833 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 324AA14E2 for ; Fri, 16 Nov 2018 10:08:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1E5BC2CCD5 for ; Fri, 16 Nov 2018 10:08:54 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0F0CC2CCEC; Fri, 16 Nov 2018 10:08:54 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 7E9462CCD5 for ; Fri, 16 Nov 2018 10:08:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=nRP3uuJA0CDf9Uz3mPszDJ+Oh39h9XPSP6zR7N3vflg=; b=G1ICcTrUHATh/A ctm1f6H44gCz9+kY2wPopt3eAcUJAahdqAyTWJUY4Vy+SWE7b+eZmSliJRJSLHershEgm2BNYoY+9 IS6us1KTy/HkBes9l9I0XCoooMG8HUz72UK5EHjDLyFYvqoXRGbPls2UC7IGktEoqLNjyZHy4+Ikj /mGAP3P5doMXC6xFXaQUz+UaBeqivSohFaIazkALtMKblwv8YbgGCBuOLnJlCkN9LckPDtmI4jK5e 0ujzZpO3z1X4Ge18CMSMXw+IbfbWjSyiqLRrofyzv4EkizALLYOHQprdNN05JSeL85TWgEMj2Dx6E ybBIWKrD5bNDNXNjxmDw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb3K-0002cm-UB; Fri, 16 Nov 2018 10:08:42 +0000 Received: from mail-pf1-x441.google.com ([2607:f8b0:4864:20::441]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb0O-0007uW-GI for linux-arm-kernel@lists.infradead.org; Fri, 16 Nov 2018 10:05:43 +0000 Received: by mail-pf1-x441.google.com with SMTP id x2-v6so11173757pfm.7 for ; Fri, 16 Nov 2018 02:05:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=om0H71tufNAx0r7YflYDpC1gYfbPSxJIkzk36iVdtAw=; b=auctwtugckjHOD5UYwG5YZKu9lugfvTLsmETpIWATYFmmRKSoMz8hKoNZJg1vRIqcc /SVMWzBdcg7V3+I8AUw8f2GHCNQ+v7i9aAXAF4QWrcOQyLan24bCiBP7wKBz7+Ufx6h2 wgVPCk/H/6x9eUb2oDprX/qc/SAKcd8l7q3i0= 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=om0H71tufNAx0r7YflYDpC1gYfbPSxJIkzk36iVdtAw=; b=p6sAzcOOy/xYTuBYu9fb9lq+rMOUIlUqmzxy9i89kewmSEakwcrGyCiII9otWKwObZ 52jX01PdjkHiT5ivnvMfpMNqVQaHCx5Tb7iYH9KRy7BvZv0N+ngkTZc/dRESNiHSp3gd GaWNp3UC0rzekGKFtD6jVbxXZmLe7pscc8zenHB6jTualaXaZUBx6zCv2DzeR7tSIDc/ LA7U7pW3tYdFz+mol1gwjjTOLM91tvLV8x1YQYXCBz6ZvO5SnXR3Gmd9lLrmabq3sliI 9IsPq8uLOJKynSri58craa6ybJ2RrSF9jaeqeQ7EoXrdXfmnfyfSiMPD5vMAYxRsGXfQ KFig== X-Gm-Message-State: AGRZ1gKBEloetCRoK+uNdB1x7soQoQts7dzgQAqC9LE2iWpFHFlitbVj QYc9nBYJGa7wnq5Z45uLWREzHg== X-Google-Smtp-Source: AJdET5cb467S8Az2pHGP9fdJoTx6K+t306shHiBHqvOLREarsw3+f0vbG0GrtEiBuTosP1V5I0zlhw== X-Received: by 2002:a62:178c:: with SMTP id 134-v6mr10578182pfx.29.1542362728307; Fri, 16 Nov 2018 02:05:28 -0800 (PST) Received: from localhost ([122.172.88.116]) by smtp.gmail.com with ESMTPSA id c7-v6sm37915148pfh.25.2018.11.16.02.05.27 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Nov 2018 02:05:27 -0800 (PST) From: Viresh Kumar To: Mark Rutland , Rob Herring , arm@kernel.org, Heiko Stuebner Subject: [PATCH 09/10] ARM64: dts: rockchip: Add all CPUs in cooling maps Date: Fri, 16 Nov 2018 15:34:32 +0530 Message-Id: X-Mailer: git-send-email 2.19.1.568.g152ad8e3369a In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181116_020540_577032_25F94649 X-CRM114-Status: GOOD ( 15.95 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Vincent Guittot , Viresh Kumar , Daniel Lezcano , linux-kernel@vger.kernel.org, linux-rockchip@lists.infradead.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Each CPU can (and does) participate in cooling down the system but the DT only captures a handful of them, normally CPU0, in the cooling maps. Things work by chance currently as under normal circumstances its the first CPU of each cluster which is used by the operating systems to probe the cooling devices. But as soon as this CPU ordering changes and any other CPU is used to bring up the cooling device, we will start seeing failures. Also the DT is rather incomplete when we list only one CPU in the cooling maps, as the hardware doesn't have any such limitations. Update cooling maps to include all devices affected by individual trip points. Signed-off-by: Viresh Kumar --- arch/arm64/boot/dts/rockchip/rk3328.dtsi | 5 ++++- arch/arm64/boot/dts/rockchip/rk3368.dtsi | 15 ++++++++++++--- arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts | 8 ++++++-- arch/arm64/boot/dts/rockchip/rk3399.dtsi | 12 +++++++++--- 4 files changed, 31 insertions(+), 9 deletions(-) diff --git a/arch/arm64/boot/dts/rockchip/rk3328.dtsi b/arch/arm64/boot/dts/rockchip/rk3328.dtsi index e1a33dd981e0..ecd7f19c3542 100644 --- a/arch/arm64/boot/dts/rockchip/rk3328.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3328.dtsi @@ -479,7 +479,10 @@ cooling-maps { map0 { trip = <&target>; - cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; contribution = <4096>; }; }; diff --git a/arch/arm64/boot/dts/rockchip/rk3368.dtsi b/arch/arm64/boot/dts/rockchip/rk3368.dtsi index 9c24de1ba43c..7014d10b954c 100644 --- a/arch/arm64/boot/dts/rockchip/rk3368.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3368.dtsi @@ -426,12 +426,18 @@ map0 { trip = <&cpu_alert0>; cooling-device = - <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_b1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_b2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_b3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; map1 { trip = <&cpu_alert1>; cooling-device = - <&cpu_l0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + <&cpu_l0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_l1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_l2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_l3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; @@ -459,7 +465,10 @@ map0 { trip = <&gpu_alert0>; cooling-device = - <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_b1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_b2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_b3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; diff --git a/arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts b/arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts index 2cc7c47d6a85..81e73103fa78 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts +++ b/arch/arm64/boot/dts/rockchip/rk3399-gru-kevin.dts @@ -118,13 +118,17 @@ map0 { trip = <&ppvar_bigcpu_alert>; cooling-device = - <&cpu_l0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + <&cpu_l0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_l1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_l2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_l3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; contribution = <4096>; }; map1 { trip = <&ppvar_bigcpu_alert>; cooling-device = - <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_b1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; contribution = <1024>; }; }; diff --git a/arch/arm64/boot/dts/rockchip/rk3399.dtsi b/arch/arm64/boot/dts/rockchip/rk3399.dtsi index 99e7f65c1779..d4ebffc28953 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3399.dtsi @@ -770,13 +770,18 @@ map0 { trip = <&cpu_alert0>; cooling-device = - <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_b1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; map1 { trip = <&cpu_alert1>; cooling-device = <&cpu_l0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, - <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + <&cpu_l1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_l2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_l3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_b1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; @@ -804,7 +809,8 @@ map0 { trip = <&gpu_alert0>; cooling-device = - <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + <&cpu_b0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu_b1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; }; From patchwork Fri Nov 16 10:04:33 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 10685831 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id AFC5014E2 for ; Fri, 16 Nov 2018 10:08:29 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9E76728A6A for ; Fri, 16 Nov 2018 10:08:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 927EB29362; Fri, 16 Nov 2018 10:08:29 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 14C8528A6A for ; Fri, 16 Nov 2018 10:08:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=H+mb9MKdEPStmGeA1/EfE2G1caGMt3NLZAqh/kkthlo=; b=XwcOF8i7/3edgc BrN5oJLCKZzWclSj1ZgqbuK8DSK7oLtZ2xPNSzIiTjhRXJXbdY9b0MYML6jj1vb4nhmKAWxhBpPoN JUmIuha1qAsp7EYm9JoA+GaQ2HbRlu3iYJt6Q8blmwu9iyC5m5zOAyTRbr+M2zeWd4p9Hc13wSJhR qoa+cBeoxJ7LxtICFLGSZZhBDNkauZ2Hm7CaPjvthj9lgwJFX5vg2yl3Kow1kwZ6MJYF5S+wsHqTa qcrf2qcy5MMEev/ig6KQikrIsJsEG/CreMt/gNbVoBBgSSWG/HodD6Ow+th9p0XfjbKf/QLkn2xsS 4T1d/slVJ/EHl33yAVZQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb32-00026f-Cb; Fri, 16 Nov 2018 10:08:24 +0000 Received: from mail-pf1-x444.google.com ([2607:f8b0:4864:20::444]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gNb0O-00080a-GC for linux-arm-kernel@lists.infradead.org; Fri, 16 Nov 2018 10:05:43 +0000 Received: by mail-pf1-x444.google.com with SMTP id b85so4358032pfc.3 for ; Fri, 16 Nov 2018 02:05:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=KuQ2y36Xrogh3AFeo+w7wq6zdpbFBC/erJbwrEPtLJs=; b=jW92B1VzqoIqDzqfecPcu+sFg3tYWXLZGvNmhlicA/IAPUk2KrDwq6Cd/dXpVmP/Ch tc8tdaerC+mPnSf3WEy6lguWwJvNA8r2ShnOFqXsyYp0ajfqyXaQMmd3DuZxDcpGVjul t/MXnPBObHOJLawXqGPkrM4efmpv8szog/bXc= 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=KuQ2y36Xrogh3AFeo+w7wq6zdpbFBC/erJbwrEPtLJs=; b=SoOAIChdK0vL2HvzLeW/yhiC6jqf7+fXN84LXHqawN6dRGy5vczABLjjaCK51JDrvY qjV/l/HBPqNxoN5ojjvMTmOOii68GzW+2bnDWZ/lGmWokfbMe+F773w2pVa7/gCdWkzC F6zT26+kY9XIdCuMq+ETV9ygRMF0HHyKI23bHUNhE+jk1Koljs/Y/4yAolm9ZBszA6+t ayqPh/KqN1vx8jxn1/RkivOH6kLxsnlByI98nUiFdYs4Vi0tJzvIx4CwKJAB21Vtf+GU GwrUianRUkjWrgzZ98CeuG+ouhCWf51frEaAyEoCbIgnb/1D4CTjCcLztwrwQ77fk1Zd JL5g== X-Gm-Message-State: AGRZ1gIwbH/VWiItHrkzIX5vTSo2BIGS2lbhIup6cM2W4yTI4nc2W1wD I0hh4tEtF+Mn/4WfZ+OEDDjJjQ== X-Google-Smtp-Source: AJdET5cQ/pFNqQDeGVqoVWAXo3OsGpLnmRROYg1543bE0SKQ5rAbtrwuV09x3/9tqL5x2ckwMAUTtA== X-Received: by 2002:a63:5153:: with SMTP id r19mr9270294pgl.281.1542362733085; Fri, 16 Nov 2018 02:05:33 -0800 (PST) Received: from localhost ([122.172.88.116]) by smtp.gmail.com with ESMTPSA id 79sm29801208pge.66.2018.11.16.02.05.31 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Nov 2018 02:05:32 -0800 (PST) From: Viresh Kumar To: Mark Rutland , Rob Herring , arm@kernel.org, Masahiro Yamada Subject: [PATCH 10/10] ARM64: dts: uniphier: Add all CPUs in cooling maps Date: Fri, 16 Nov 2018 15:34:33 +0530 Message-Id: X-Mailer: git-send-email 2.19.1.568.g152ad8e3369a In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181116_020540_567131_51D6250E X-CRM114-Status: GOOD ( 14.06 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Vincent Guittot , Viresh Kumar , Daniel Lezcano , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Each CPU can (and does) participate in cooling down the system but the DT only captures a handful of them, normally CPU0, in the cooling maps. Things work by chance currently as under normal circumstances its the first CPU of each cluster which is used by the operating systems to probe the cooling devices. But as soon as this CPU ordering changes and any other CPU is used to bring up the cooling device, we will start seeing failures. Also the DT is rather incomplete when we list only one CPU in the cooling maps, as the hardware doesn't have any such limitations. Update cooling maps to include all devices affected by individual trip points. Signed-off-by: Viresh Kumar --- arch/arm64/boot/dts/socionext/uniphier-ld20.dtsi | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/arch/arm64/boot/dts/socionext/uniphier-ld20.dtsi b/arch/arm64/boot/dts/socionext/uniphier-ld20.dtsi index d7e2d8969601..4a0c46cb11cd 100644 --- a/arch/arm64/boot/dts/socionext/uniphier-ld20.dtsi +++ b/arch/arm64/boot/dts/socionext/uniphier-ld20.dtsi @@ -206,13 +206,10 @@ cooling-maps { map0 { trip = <&cpu_alert>; - cooling-device = <&cpu0 - THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; - }; - map1 { - trip = <&cpu_alert>; - cooling-device = <&cpu2 - THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu2 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu3 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; }; }; };