From patchwork Thu Dec 1 20:36:52 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Morgan X-Patchwork-Id: 13061794 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E7D91C43217 for ; Thu, 1 Dec 2022 20:42:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=xSaXpyoxDtEEFvjIJsPKkq8rmqPg+Ln5SopzH0zhuJ0=; b=lbUddG/FAZUhFb iOaQmT6AWjjFZSzMoqcKAccnBiovrFMFs5GivMiXdyxPdlDFa2LyirlbkHHJlfouXb/uo+E2MMkUg IOpGrpLfozZgDgfGNiDPHMgyZRulGYHYBNNZfoBrdnlComt4Unovu6JQ7y0NyUgs2l+O8FTRAeHho rAttJi7GxYTZ5l2k5tQ5nwucvwjiWHDHE5iDFmDMmtU0pKo/zc+5S6GvVj9Wijgmd3+bJtdnRCI2K mhisGo7J3n6ofzgNMu3pKr0jUTOx34dUC+bEW5hn9+yZLBJGgBANrLaKcx/uvQ26KRwJf2Q3gI6kA YRaQvD8FfEsZp74d34HQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1p0qOF-00AucE-4T; Thu, 01 Dec 2022 20:42:39 +0000 Received: from mail-oa1-x2f.google.com ([2001:4860:4864:20::2f]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1p0qIr-00ArAl-MP for linux-rockchip@lists.infradead.org; Thu, 01 Dec 2022 20:37:07 +0000 Received: by mail-oa1-x2f.google.com with SMTP id 586e51a60fabf-142306beb9aso3479937fac.11 for ; Thu, 01 Dec 2022 12:37:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=HHhagubBU9I/eLAgfTTLb4aJShqjddvM8h9wwY5WXbk=; b=WOFAwNLlPMAJkPINQJWRTY8NNxpX2UsOwq/lRZ7LnqNfbPCPl0eoGZCVWqQAssTxo1 sMsqsGmPDPqYLYyKsmv2Kzn+jcE96esdcDcVbsTjbHxCqQxD3GuJVXSkVtz/Kv7u+3F6 JuWupgiHJuliheS4DsurKS5ocI4a8hAvp2nZDNfL2zXLmB/UuW3IDpi/EH2SGs8v62yg JK6lsIcAusewyCr+PFiK3GdvtIXE8qgC5PuIcE6/eyttzBt+uc+SZNou/ugsh5cXR2vy LlIyvb4WdBeMjbCPwEVDFks64mVxXTVdVi5DCg/7+wC+hM5bskdxgiaM1HZLUff9yLBV /yqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=HHhagubBU9I/eLAgfTTLb4aJShqjddvM8h9wwY5WXbk=; b=LVBoJPaqyq55vJFCRNA7IPPpwLbkfnry/E71TOxSjI1pq12fKtJTSkwXGXQKCASfwW ZEIzn/U3FCC+xBcdYotcpupuj7UiRJ38ZFz+ZBQYzSFn13hmKg92zmlCHnw4nz4nDqDM H5TrKBmYae4D8joJSHtC2MDLRlg33hhyuWCWK8UMoMxOBpqN1/ww1ol7vjdpUtxb3Wi6 ZOHfCadKunlFpeV1h64q3VNqI2481F/ifx+If6bVep2gXVWtXz+61DSPWna6Q0eyIPth 4O4zgXmFx+2ojRhcIkJYys304FmptXfK4kZc1gDamy1n4Ci91BHMCbYjVc9BkYk+bBDe M6kQ== X-Gm-Message-State: ANoB5pnbCb1GTHiTrl4gIjSrVBsZOWQ4czMi9G/v1wJl9EF4W3+fF7J3 dZqN0OjxP166a7WerFGPRjFCvsH4xbg= X-Google-Smtp-Source: AA0mqf7EnvyKcdI0cEdYMyvgGliVp9Y/xtR5JszOeeOoJnvBaEtCX5tleO0/+ysiEJLtYn5Q29AY4w== X-Received: by 2002:a05:6871:792:b0:141:c075:9346 with SMTP id o18-20020a056871079200b00141c0759346mr27877631oap.30.1669927021435; Thu, 01 Dec 2022 12:37:01 -0800 (PST) Received: from localhost.localdomain ([76.244.6.13]) by smtp.gmail.com with ESMTPSA id r81-20020a4a3754000000b0049fd73ccf72sm2142142oor.42.2022.12.01.12.37.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Dec 2022 12:37:00 -0800 (PST) From: Chris Morgan To: linux-rockchip@lists.infradead.org Cc: devicetree@vger.kernel.org, maccraft123mc@gmail.com, heiko@sntech.de, krzysztof.kozlowski+dt@linaro.org, robh+dt@kernel.org, Chris Morgan Subject: [PATCH 1/4] arm64: dts: rockchip: Change audio card name for Odroid Go Date: Thu, 1 Dec 2022 14:36:52 -0600 Message-Id: <20221201203655.1245-2-macroalpha82@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221201203655.1245-1-macroalpha82@gmail.com> References: <20221201203655.1245-1-macroalpha82@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221201_123705_769097_B421C7D6 X-CRM114-Status: GOOD ( 12.76 ) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org From: Chris Morgan Change the audio card name for the Odroid Go Advance series to rk817_int. This matches the audio card name of the Anbernic RG353V. This is done to provide a consistent card name so that a single ALSA UCM file can be used for all (identical) implementations of this codec and configuration combo. The rk817_int configuration is for when the internal speaker amplifier of the rk817 is used. The other Anbernic devices have the name as rk817_ext for when an external speaker amplifier is used. Signed-off-by: Chris Morgan --- arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi b/arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi index fbc6bfbaa5c1..60063f4bb366 100644 --- a/arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi @@ -127,7 +127,7 @@ blue_led: led-0 { rk817-sound { compatible = "simple-audio-card"; - simple-audio-card,name = "Analog"; + simple-audio-card,name = "rk817_int"; simple-audio-card,format = "i2s"; simple-audio-card,hp-det-gpio = <&gpio2 RK_PC6 GPIO_ACTIVE_HIGH>; simple-audio-card,mclk-fs = <256>; From patchwork Thu Dec 1 20:36:53 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Morgan X-Patchwork-Id: 13061793 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 2DD55C47088 for ; Thu, 1 Dec 2022 20:42:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=hCjQvnbDMz3sVuNgcRwPc2teXtohWgstYIySjXUtDCU=; b=bdyaORYpgUyQ8J pu+ku8QmNv25Ja7ala1/yUco795D5KSZMlzceOTwxIk+s7g06dGxyQ9D50A2x0IFXOxFB1pqeCUKT FGs8uF3BnGwNus5GQi5w+KX93IDmXtbJqP36X2G66jFspp5Zrn53NBb/o+qJxONyvhWyI8qP6vaoO 4moS5C1eRIwUM2rtBBlzrdRzTNSveGIrTekxzHGWWESRbOW+esxkuqlDg44IY6HC/1r1t2NhW+LQ0 XNNstvUtblRBcLllgFmDsCujCw2egAPD5Q74E2jLfHXHdVEzaw8u6lNN+mqrCUOOtRdUDv/n1PTgQ 86BtVtUJJN55QAosf8kw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1p0qOF-00AucI-Dh; Thu, 01 Dec 2022 20:42:39 +0000 Received: from mail-oa1-x2e.google.com ([2001:4860:4864:20::2e]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1p0qIs-00ArBQ-Fu for linux-rockchip@lists.infradead.org; Thu, 01 Dec 2022 20:37:08 +0000 Received: by mail-oa1-x2e.google.com with SMTP id 586e51a60fabf-143ffc8c2b2so3538146fac.2 for ; Thu, 01 Dec 2022 12:37:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=kG+ctqd9teSCMiayuOxjPWFcl8agpohKd1uUpE0d4x0=; b=XFod0UnAcwD+9HZiFEkNVVUGDR7r1ylQFGkeOIptemvQBWaAm8mLU2oBy1tpxZxktJ NVFcw/h0kOr3HTw2wnyAaQlnuUoTNPQR9khmwGnmXNWy466LNGp9kbBckww6i48vwLfb nVZePvLt/0C2iqy1VDRpf4HUsRCh1OVFZfEnoZy0PBIw+x+RYNGeQCILCDwkoEiZPnvQ 9Gcq1B2V1O2Y3vK/3q+RfQQ5o0YYNjFdteTNFEF3TkK083ol/wmmCv/pbB3BdbXikwqh zby9Iy6GWBTDJOHBegLng3GTVXrLSkaVWNz3uHlxD6WPfOOB53QRTc0se7oJZgl6W9YZ Ojng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=kG+ctqd9teSCMiayuOxjPWFcl8agpohKd1uUpE0d4x0=; b=aDqxAtGs9p/utrjou2eUpusg5BbXgQfhcmruhJIzjcyCBl9gOUqAsbfCCLwyMaDpoy tT4lZayHNJ+UqqY2InbH2gtUlh/eEL927N2I+thnUzTRAtSCjIaiyIf4VF9XlFuhHTFc huRFaBTFcZm9iJkSjYNsOPPl3LbxbW08TrbX7d1Vh4+LgEeyBPhGsFjrjb0ncTqUhEQA ofnvO5HGHMkJDRdoX4LjiAHkRnty5z08lG7QZCdjXTuDnxXMyrydyglEcHXk8kc0omc3 RP8aMU8jaoEpVFjgR/sf/+2NIRiViWQRNFDrjoTn4OyV5TI0iXFtyXluXm+Az3RnziYY v+RQ== X-Gm-Message-State: ANoB5plhqb8sRCNNmGXn7roy1o0Lv0AoMqBZAApEGI5lG+T76I2KyBC/ 6R3tkkio8C0In0fizHIXMX9xAAZRtjU= X-Google-Smtp-Source: AA0mqf4+24um7ZcR5CWbp77KpWBR42nA3acpMhuAqJ7rgMXGTdcB+7tCniwHGtESiGH09AMg14QD2Q== X-Received: by 2002:a05:6870:e88:b0:142:9422:84e4 with SMTP id mm8-20020a0568700e8800b00142942284e4mr29981790oab.57.1669927022468; Thu, 01 Dec 2022 12:37:02 -0800 (PST) Received: from localhost.localdomain ([76.244.6.13]) by smtp.gmail.com with ESMTPSA id r81-20020a4a3754000000b0049fd73ccf72sm2142142oor.42.2022.12.01.12.37.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Dec 2022 12:37:02 -0800 (PST) From: Chris Morgan To: linux-rockchip@lists.infradead.org Cc: devicetree@vger.kernel.org, maccraft123mc@gmail.com, heiko@sntech.de, krzysztof.kozlowski+dt@linaro.org, robh+dt@kernel.org, Chris Morgan Subject: [PATCH 2/4] arm64: dts: rockchip: don't set cpll rate for Odroid Go Date: Thu, 1 Dec 2022 14:36:53 -0600 Message-Id: <20221201203655.1245-3-macroalpha82@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221201203655.1245-1-macroalpha82@gmail.com> References: <20221201203655.1245-1-macroalpha82@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221201_123706_551133_9C804459 X-CRM114-Status: GOOD ( 10.74 ) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org From: Chris Morgan The Odroid Go Advance devicetree tries to set the rate for the cpll clock to 17MHz, which is not a supported rate. This fails, and triggers the error of "clk: couldn't set cpll clk rate to 17000000 (-22), current rate: 17000000" in the dmesg log. Remove the incorrect rate. Signed-off-by: Chris Morgan --- arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi b/arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi index 60063f4bb366..802be64626d6 100644 --- a/arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi @@ -192,14 +192,12 @@ &cru { assigned-clocks = <&cru PLL_NPLL>, <&cru ACLK_BUS_PRE>, <&cru ACLK_PERI_PRE>, <&cru HCLK_BUS_PRE>, <&cru HCLK_PERI_PRE>, - <&cru PCLK_BUS_PRE>, <&cru SCLK_GPU>, - <&cru PLL_CPLL>; + <&cru PCLK_BUS_PRE>, <&cru SCLK_GPU>; assigned-clock-rates = <1188000000>, <200000000>, <200000000>, <150000000>, <150000000>, - <100000000>, <200000000>, - <17000000>; + <100000000>, <200000000>; }; &display_subsystem { From patchwork Thu Dec 1 20:36:54 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Morgan X-Patchwork-Id: 13061792 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id F2597C43217 for ; Thu, 1 Dec 2022 20:42:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=tdESTrm87WihZh1f8wbyhwgZCmxoyj9knQ1ORaSHdQ0=; b=mUhIlPptmCjOXD mZSlC+qOxFVve31rOhrQsyyrSg2p3vvw/FUQ/2D/fHTCcmB2hYyAbGsogfoIe4ANYYh35oo9sLx8H bxp2X0A4Uf8l6DJ1Q5QW8X+Qrv9vAEo7iQGnlV7cw4CQ7lN7z7PwU/6ZvywREra7qrFaRzmBlaDe5 usyI0bzZzCI2fZIWy5Pkjh5Cp/yI6yrxD0EwuoZCbYa/7+KZmd48t56ExQaVxlC4b8borX0AY+zMO kcCWx4xaKmSDmFz6Pe6S6EA/y5UntjrRlN5d3nTSSklMG6XJdYembldD0OAsI08QMiWboWFilGjAw yPLuvmpjV2U2O5igrE2w==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1p0qOE-00AucA-Qr; Thu, 01 Dec 2022 20:42:38 +0000 Received: from mail-oa1-x2b.google.com ([2001:4860:4864:20::2b]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1p0qIr-00ArC8-JU for linux-rockchip@lists.infradead.org; Thu, 01 Dec 2022 20:37:06 +0000 Received: by mail-oa1-x2b.google.com with SMTP id 586e51a60fabf-12c8312131fso3512460fac.4 for ; Thu, 01 Dec 2022 12:37:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=KDNVIS6v1yG6sAvFOYg/2+Zxz4ZXp/Ow5NLTwsyPqTQ=; b=CvmuuY+wkEu+uT9ff0B1aNBJgUaRDd7us1n2vCBeR82xZfRBOaHewq3903/N34zrA9 FkJN+nPJH1eEZEGJ9GsNYO514rTQQ1kBeB9lHSPUIZBUP/xiitn9po9PJs/lc67QI8+j 3ezbkOBRj6OvXCWdLhKNvxR/IuIraY3IV9sygT5Kr3IlYO5dVO4IzdsisWkqLHNPIudY sUCrblfeGWV+Xdj2QdSdYPvZDOZlFVWlKO49jND/gFtmNr2gBm8LB3DIIjr4bS6GoJ3o MiatGl/Bc63gM3Nd96H/t21WkAjhUnumaDwuhPvb0g6hiTnCTib+2NhYkAYRTh0I64Gq jMcg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=KDNVIS6v1yG6sAvFOYg/2+Zxz4ZXp/Ow5NLTwsyPqTQ=; b=MsVstkzUYvY9ei4OdQ+eq/RK+T8ofS88eKeD8Kb/pBsEVG4v61j+2+HxsIiidi2ZuH SSwx4LaZe00TSN8Ia7KaHSMPT123gDKpo+Qxc0QQIKycyYNTfG+rr3ysMZt2wWJZPpOq D2NBzQWDBUp1N1mOli/efc6ewPI1jVIi7Vm1FSnDlWbuscKUF9ERQH/8SYtlOdaWrRhR ntAtqYqhPSDk4VPfPtRzX+2Q95E/oUAEdle9pnsf1jA5+djgCG0V5a+xhiWV6kGvPj9p KmStu3RI77rVZDS+RSA0y/N8o9qbBskjfdHzkYPYLhYta95CY5Zn3zOBXBsAPcQJksjE Zs/A== X-Gm-Message-State: ANoB5pnr485za/GYvM/Zv9F2ZzBSgs3a/MBS++fa9arCU6P/t2Hvp97h qd/J9K2bGGC6vKxxXGhhXk2E88oSEDs= X-Google-Smtp-Source: AA0mqf6tqXSIMh4TUCBXKPIj9DYC2ccLMsIsrsKIgoHSvwThYP7VK6hWkaFN+IlGAUxfMVTxBHDrLQ== X-Received: by 2002:a05:6870:479b:b0:142:7f3b:d60a with SMTP id c27-20020a056870479b00b001427f3bd60amr37573173oaq.111.1669927023423; Thu, 01 Dec 2022 12:37:03 -0800 (PST) Received: from localhost.localdomain ([76.244.6.13]) by smtp.gmail.com with ESMTPSA id r81-20020a4a3754000000b0049fd73ccf72sm2142142oor.42.2022.12.01.12.37.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Dec 2022 12:37:02 -0800 (PST) From: Chris Morgan To: linux-rockchip@lists.infradead.org Cc: devicetree@vger.kernel.org, maccraft123mc@gmail.com, heiko@sntech.de, krzysztof.kozlowski+dt@linaro.org, robh+dt@kernel.org, Chris Morgan Subject: [PATCH 3/4] arm64: dts: rockchip: update px30 thermal zones for GPU Date: Thu, 1 Dec 2022 14:36:54 -0600 Message-Id: <20221201203655.1245-4-macroalpha82@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221201203655.1245-1-macroalpha82@gmail.com> References: <20221201203655.1245-1-macroalpha82@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221201_123705_668489_1FF63D7C X-CRM114-Status: GOOD ( 13.83 ) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org From: Chris Morgan Without the trips, the following errors are received in the dmesg log and the rockchip-thermal driver fails to load the gpu sensor: "thermal_sys: Failed to find 'trips' node" "rockchip-thermal ff280000.tsadc: failed to register sensor 1: -22" Trip values are assumed, unfortunately, as the same values as the CPU. The datasheet and TRM didn't appear to have any information regarding thermals for the GPU. Stress tested successfully on my Odroid Go Advance. Signed-off-by: Chris Morgan --- arch/arm64/boot/dts/rockchip/px30.dtsi | 33 +++++++++++++++++++++----- 1 file changed, 27 insertions(+), 6 deletions(-) diff --git a/arch/arm64/boot/dts/rockchip/px30.dtsi b/arch/arm64/boot/dts/rockchip/px30.dtsi index bfa3580429d1..4f6959eb564d 100644 --- a/arch/arm64/boot/dts/rockchip/px30.dtsi +++ b/arch/arm64/boot/dts/rockchip/px30.dtsi @@ -210,12 +210,6 @@ map0 { cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; contribution = <4096>; }; - - map1 { - trip = <&target>; - cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; - contribution = <4096>; - }; }; }; @@ -223,6 +217,33 @@ gpu_thermal: gpu-thermal { polling-delay-passive = <100>; /* milliseconds */ polling-delay = <1000>; /* milliseconds */ thermal-sensors = <&tsadc 1>; + + trips { + gpu_threshold: gpu-threshold { + temperature = <70000>; + hysteresis = <2000>; + type = "passive"; + }; + + gpu_target: gpu-target { + temperature = <85000>; + hysteresis = <2000>; + type = "passive"; + }; + + gpu_crit: gpu-crit { + temperature = <115000>; + hysteresis = <2000>; + type = "critical"; + }; + }; + + cooling-maps { + map0 { + trip = <&gpu_target>; + cooling-device = <&gpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + }; + }; }; }; From patchwork Thu Dec 1 20:36:55 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Morgan X-Patchwork-Id: 13061795 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 8673BC47089 for ; Thu, 1 Dec 2022 20:42:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=C0+s2/8oMbujD7x/hdSSkN2Yc4vwE0idmKhQxxhZ4Es=; b=wsIumg6Fc8mczv 22cBRY9gHhVZI28MCdtI8krBMhNDgkHRA+khFRJmiGRpAgsump5qY6qz+YmeeroUO/US4jZcLhqVt NSBGp/CmAP3c6qv4Jpn3HlPdsYfJYfoTEBx1kF9cAaDrmrQLsTtubFmvTTSTASRyNdq6P5R7Z2cct GjlG2QHMiTtevLgGaoxXAkahBxguB5C65rb/dOWoSkcXVlkBCaynos6M1yCBYE1fWLxbv1M9jGrfK qJmVRvgykLtNQP1tjIkqZ1mqKnXYZwTJSw0ECYx8tE6heCChhjS7F+zvFznpUp4HTyAV33F+C9bzW nifLKlW+zCIuQF24BKjw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1p0qOF-00AucM-NB; Thu, 01 Dec 2022 20:42:39 +0000 Received: from mail-oi1-x22f.google.com ([2607:f8b0:4864:20::22f]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1p0qIt-00ArCo-Mf for linux-rockchip@lists.infradead.org; Thu, 01 Dec 2022 20:37:09 +0000 Received: by mail-oi1-x22f.google.com with SMTP id c129so3363263oia.0 for ; Thu, 01 Dec 2022 12:37:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=O9DWfkSi/N1IMySUHdlxHV43RaSOxsmartbv0wgiizw=; b=W/1EJx6UGea0iXmce0+SKrB4wiLm79ah4qyz629fypLwx3BEH8Ihu1Goc6r9CslHeT xi/26q5OEDO28jpODKTjEZtUu8TiWrqiB7o21u7LSg4tTSwSboVIysp6VoansFz8Dl4V zO0EbcYfhzqv/NsETPomS2KsQi7IO6hEzXmBX98f84WRoXTvEQG8sDJyvqMqGJYJm2UX e7kZrnsYyLQrNglGNdUkawe7VtJiIw2Pv7MPNGjYj52V8J9pcdfYd+NMhIyaXqrE4ERZ 6my14xVLyqjSVYkbqkA6nH2OHfEGlqY62QVQWrdbvYSsxwpOJO+qWnLtYz5PcNXft2CZ TaPg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=O9DWfkSi/N1IMySUHdlxHV43RaSOxsmartbv0wgiizw=; b=KNSO/mfM5ubaQWyGYSaH54zyg8s2TByLfNlkuR8/+Ud9COInKYLsx2B//6e2t0E5YN G3daN8nZe69jjPgXVpcoifa1x7WqGsvgQhFAzrVvcX3HqvIVxPiNUtuFdSEO26F1yNk9 Eoxe0jYhwwszrvmajo0wadKesyflcdxdpaS81qp+aIQyy2o9nyiudVs5VLcvOKV+2i8s 8is/xfPEe8rwxh1kN3lnRi85hzuAkMpzQ/C3b6sH+FO3BZFyR9W56k0MVoyFSz2lf+71 1vqURCNfURPVyBY6ahZVsec73okIeC3gX4eMkSefB1bXaJzyMtRvBzLjUIiI5CC8+HSw 3Urw== X-Gm-Message-State: ANoB5pn1epCVK5QQQtnsew7DmzKKAolgV2Qqwn5RR7jOBDCjke8ve0AN M+0SS+Uno5bMtk121M25GiJPbkCusQM= X-Google-Smtp-Source: AA0mqf7WpouCg2PO2wK0kyOSGdZ0Z5PBu5YT2P8YxXt8TBxZ9MHxyySfq2AARIXSCneqTJFgTb23cg== X-Received: by 2002:a05:6808:b26:b0:35b:9b00:b4fc with SMTP id t6-20020a0568080b2600b0035b9b00b4fcmr14938401oij.91.1669927024469; Thu, 01 Dec 2022 12:37:04 -0800 (PST) Received: from localhost.localdomain ([76.244.6.13]) by smtp.gmail.com with ESMTPSA id r81-20020a4a3754000000b0049fd73ccf72sm2142142oor.42.2022.12.01.12.37.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Dec 2022 12:37:03 -0800 (PST) From: Chris Morgan To: linux-rockchip@lists.infradead.org Cc: devicetree@vger.kernel.org, maccraft123mc@gmail.com, heiko@sntech.de, krzysztof.kozlowski+dt@linaro.org, robh+dt@kernel.org, Chris Morgan Subject: [PATCH 4/4] arm64: dts: rockchip: Update leds for Odroid Go Advance Date: Thu, 1 Dec 2022 14:36:55 -0600 Message-Id: <20221201203655.1245-5-macroalpha82@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221201203655.1245-1-macroalpha82@gmail.com> References: <20221201203655.1245-1-macroalpha82@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221201_123707_759957_111BA4A1 X-CRM114-Status: GOOD ( 12.46 ) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org From: Chris Morgan Update the blue LED to be controlled via pwm to enable control of LED brightness. Add red LED as a GPIO controlled LED. The documentation stated "label" was depreciated so function and color was used instead. The LED names (led-2 and led-3) are given because that is what they are numbered on the board itself; LED 1 is wired directly into an always on regulator and is not controllable. LED 2 is labelled "alive" on the board and documentation recommends we set the function as status over other miscellaneous functions. LED 3 is labelled "chg" on the board. Signed-off-by: Chris Morgan --- .../boot/dts/rockchip/rk3326-odroid-go.dtsi | 33 +++++++++++++++---- 1 file changed, 26 insertions(+), 7 deletions(-) diff --git a/arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi b/arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi index 802be64626d6..8ea2af72a7bc 100644 --- a/arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3326-odroid-go.dtsi @@ -8,6 +8,7 @@ /dts-v1/; #include #include +#include #include #include "rk3326.dtsi" @@ -113,15 +114,29 @@ button-sw16 { }; }; - leds: gpio-leds { +/* led-1 is wired directly to output of always-on regulator */ + + gpio_led: gpio-leds { compatible = "gpio-leds"; pinctrl-names = "default"; - pinctrl-0 = <&blue_led_pin>; + pinctrl-0 = <&red_led_pin>; + + red_led: led-3 { + color = ; + gpios = <&gpio0 RK_PB5 GPIO_ACTIVE_HIGH>; + function = LED_FUNCTION_CHARGING; + }; + }; - blue_led: led-0 { - label = "blue:heartbeat"; - gpios = <&gpio0 RK_PC1 GPIO_ACTIVE_HIGH>; + pwm_led: led-controller { + compatible = "pwm-leds"; + + blue_led: led-2 { + color = ; + function = LED_FUNCTION_STATUS; linux,default-trigger = "heartbeat"; + max-brightness = <255>; + pwms = <&pwm3 0 25000 0>; }; }; @@ -465,6 +480,10 @@ &pwm1 { status = "okay"; }; +&pwm3 { + status = "okay"; +}; + &saradc { vref-supply = <&vcc_1v8>; status = "okay"; @@ -569,8 +588,8 @@ hp_det: hp-det { }; leds { - blue_led_pin: blue-led-pin { - rockchip,pins = <0 RK_PC1 RK_FUNC_GPIO &pcfg_pull_none>; + red_led_pin: red-led-pin { + rockchip,pins = <0 RK_PB5 RK_FUNC_GPIO &pcfg_pull_none>; }; };