Received: by 2002:a05:6a10:7420:0:0:0:0 with SMTP id hk32csp3612001pxb; Mon, 21 Feb 2022 01:48:25 -0800 (PST) X-Google-Smtp-Source: ABdhPJxiP3+w2P5s+AR+y9/A7eSa9z012BkK/pTitdSILYY0huyS3BZiM2pctzdTDgJq2ylW2v2B X-Received: by 2002:a63:114:0:b0:34d:efd0:762a with SMTP id 20-20020a630114000000b0034defd0762amr15447145pgb.71.1645436905510; Mon, 21 Feb 2022 01:48:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645436905; cv=none; d=google.com; s=arc-20160816; b=EeTzcH1lHrsdVdvGIa8/CkOGJ/1NtS+QFwtvtndxLqClWFQqcnYJDNMidmUHdSsBnW 0dcXavrXiZcNiAkVbK2dEn6MqzqiL4tj2jg8RziG/fiqSqSGh/jnRlQtoQCp7DEV+pAf dJUnJ+/DRiaUmMH0zVxck2Bo9kIh40IuZx/yW5bj7Md69Z1u1huCMDRb+dFegSMooKP2 mLJi5vD0P53TgVBE6SczcBvBhSJ4hav0YvEgTbEy49HXHpZrz++A6ykogBnZO7NKUa5l zEn3VuNyUwYFJQhKJw80rLBfiSiRRcaxgAqesVudkhHhTnvRtFmA/BZLluTzPpCNxwgo U6/A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=2mw5+wg/8SgXeM4VvshXa1o49gOrGhQhuJH3OANET98=; b=dT/tEgkjKpx1ljGphzv78l9czZITP0xYOh9tUzR5HtN6ZtqRWgZmW+ENt7ChKG0n2Q 0sJ1d5PgI9cV3d19YzLYqRAtu+iNLtRqcsmAzzUYThQnlBZPbpzYxI7S0UkJrmoaVQSG IXmMNSuk1bOWKJ5tcptHmVX/kIm/zC47BEW9EvJylryDVOnwUh1LOvu3Z7k89P88AtFa UEE7epNemPuUBSl9WV7+EUjlFmif7v4caSyFgd0VfJan6sw7d4R0hhcRok2gh2PHdPFC ZDd9HZNW2boxQVhUCkFYoXyD0W9y1S899wTQStM7woF0nD6IRawAvU/RcdgZ35/xCSgk 5h8Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@z3ntu.xyz header.s=z3ntu header.b=VrmjH+NW; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=z3ntu.xyz Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id d9si16550557pgd.804.2022.02.21.01.48.08; Mon, 21 Feb 2022 01:48:25 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=fail header.i=@z3ntu.xyz header.s=z3ntu header.b=VrmjH+NW; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=z3ntu.xyz Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S245156AbiBTWbH (ORCPT + 99 others); Sun, 20 Feb 2022 17:31:07 -0500 Received: from mxb-00190b01.gslb.pphosted.com ([23.128.96.19]:52884 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244570AbiBTWbF (ORCPT ); Sun, 20 Feb 2022 17:31:05 -0500 Received: from mail.z3ntu.xyz (mail.z3ntu.xyz [128.199.32.197]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 027F84B873; Sun, 20 Feb 2022 14:30:44 -0800 (PST) Received: from localhost.localdomain (ip-213-127-118-180.ip.prioritytelecom.net [213.127.118.180]) by mail.z3ntu.xyz (Postfix) with ESMTPSA id 84A4FC83D5; Sun, 20 Feb 2022 22:30:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=z3ntu.xyz; s=z3ntu; t=1645396242; bh=Z5QyXYJWluQNgIrdnzlQ4wsGTvrvV8OZI8S3n9fVWDc=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=VrmjH+NWxb72osI6sMg+QGUlxa27NpwFsjA5gZCKFfTGFa0FNAo3IqPFzzBL05Hct BrXvSzIyIqo9or+3qIcmSvw9Q2ffcuvIVyqVAOwWfqpWKDKSoG72CvFVXYYLYm+lDu CF0T3GKlGsS6LPjFpN/8wueE/HKEd+K36dbi2Y1o= From: Luca Weiss To: linux-arm-msm@vger.kernel.org Cc: ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, Luca Weiss , Andy Gross , Bjorn Andersson , linux-kernel@vger.kernel.org Subject: [PATCH 2/3] soc: qcom: rpmpd: Add MSM8226 support Date: Sun, 20 Feb 2022 23:30:02 +0100 Message-Id: <20220220223004.507739-2-luca@z3ntu.xyz> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220220223004.507739-1-luca@z3ntu.xyz> References: <20220220223004.507739-1-luca@z3ntu.xyz> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=0.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FROM_SUSPICIOUS_NTLD, PDS_OTHER_BAD_TLD,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add the power domains preset in MSM8226. Signed-off-by: Luca Weiss --- drivers/soc/qcom/rpmpd.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c index 0a8d8d24bfb7..95a2b4a64801 100644 --- a/drivers/soc/qcom/rpmpd.c +++ b/drivers/soc/qcom/rpmpd.c @@ -138,6 +138,22 @@ static const struct rpmpd_desc mdm9607_desc = { .max_state = RPM_SMD_LEVEL_TURBO, }; +/* msm8226 RPM Power Domains */ +DEFINE_RPMPD_PAIR(msm8226, vddcx, vddcx_ao, SMPA, CORNER, 1); +DEFINE_RPMPD_VFC(msm8226, vddcx_vfc, SMPA, 1); + +static struct rpmpd *msm8226_rpmpds[] = { + [MSM8226_VDDCX] = &msm8226_vddcx, + [MSM8226_VDDCX_AO] = &msm8226_vddcx_ao, + [MSM8226_VDDCX_VFC] = &msm8226_vddcx_vfc, +}; + +static const struct rpmpd_desc msm8226_desc = { + .rpmpds = msm8226_rpmpds, + .num_pds = ARRAY_SIZE(msm8226_rpmpds), + .max_state = MAX_CORNER_RPMPD_STATE, +}; + /* msm8939 RPM Power Domains */ DEFINE_RPMPD_PAIR(msm8939, vddmd, vddmd_ao, SMPA, CORNER, 1); DEFINE_RPMPD_VFC(msm8939, vddmd_vfc, SMPA, 1); @@ -436,6 +452,7 @@ static const struct rpmpd_desc qcm2290_desc = { static const struct of_device_id rpmpd_match_table[] = { { .compatible = "qcom,mdm9607-rpmpd", .data = &mdm9607_desc }, + { .compatible = "qcom,msm8226-rpmpd", .data = &msm8226_desc }, { .compatible = "qcom,msm8916-rpmpd", .data = &msm8916_desc }, { .compatible = "qcom,msm8939-rpmpd", .data = &msm8939_desc }, { .compatible = "qcom,msm8953-rpmpd", .data = &msm8953_desc }, -- 2.35.1