From patchwork Sat Jan 21 11:29:46 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robert Marko X-Patchwork-Id: 46819 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp680810wrn; Sat, 21 Jan 2023 03:33:27 -0800 (PST) X-Google-Smtp-Source: AMrXdXudIp5X+4MIFR/gTw0V3GP8cBmfJPp6LCtfbZ481gxfEMR7WLuYWtlaRRnOu35csyf6a5wt X-Received: by 2002:aa7:8a04:0:b0:58b:b29c:50c2 with SMTP id m4-20020aa78a04000000b0058bb29c50c2mr17043732pfa.26.1674300806776; Sat, 21 Jan 2023 03:33:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1674300806; cv=none; d=google.com; s=arc-20160816; b=RwXdMLHOulhAsmYCxNJN6g4eo4oOmzdlszlSFiRrFFWkW21aQcLhMHt33I6Cmaw705 K8GeVZTUrf6ZO5gb0LmO6X0oZ2BfhQk56+0pae6jyf6uqWGqizSFWKF3O2vP6Eamr5qh V1n5rW40fjgMzz5KKQ3CMy4v2W+7mxMi7R1BbTn6IK39o6iJIIS/NAFlQc5rQecSRsdc 2eVJrDeaCoIH3a1y5IMQ/fyr9A3dKeizg5SJaBCqYbVCjP+RkRfOZ4EDb0y7F4KDQ3Pg wwZABMA2TL6jfX/GYaJDebwCTEKLG1k2DzlTslkGMY4PTCWVjASJnDc9hqjqtfZ7iBI0 QUVQ== 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=APNLiKmbt8JWMBZWCLrn0Q41j8dsCsL0653AwgPsFDA=; b=admAoDIJVGF+KQtpHW1YqlgBT6l5gWYWs6r51o7JL41VMMtEte38KqIJXUVl7p+IW/ NLDNuHSJ9xUIodxJ+Yt3i2R7EB1W2vFd/sII77lppqtYqnQ5YUzIKp8xz8Q+j1afly98 lOq5s0W5FvpejdrWnJL32+9LE4fWh97rkYUytoP3AgXv+GLhcnUMwrUmC6pbuUddum+V MycT3oyx9tbGo4VzlUlfWzt6jGR4J69pQCxvo/puB2aoZPe71xzY39YWtcNFTXIPGCwC jGcc6lQuOc/zJUkLWLnXyPNzWiROaA18Dob3Lyxuv5HOZrPzBN3K3GjSMQ+2DfdrGtg6 bJZQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=g1UzDz1r; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g7-20020a056a0023c700b0058150179c5bsi18049389pfc.26.2023.01.21.03.33.14; Sat, 21 Jan 2023 03:33:26 -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=pass header.i=@gmail.com header.s=20210112 header.b=g1UzDz1r; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229890AbjAULaE (ORCPT + 99 others); Sat, 21 Jan 2023 06:30:04 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48130 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229686AbjAUL3y (ORCPT ); Sat, 21 Jan 2023 06:29:54 -0500 Received: from mail-ej1-x62b.google.com (mail-ej1-x62b.google.com [IPv6:2a00:1450:4864:20::62b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 455673D91E; Sat, 21 Jan 2023 03:29:53 -0800 (PST) Received: by mail-ej1-x62b.google.com with SMTP id mg12so19934375ejc.5; Sat, 21 Jan 2023 03:29:53 -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=APNLiKmbt8JWMBZWCLrn0Q41j8dsCsL0653AwgPsFDA=; b=g1UzDz1rMz/aM52AgBjc3ucmXLS+TBgaPsQES6XJz7DWT4VKzPfjlknwi4AXGEwbhQ tFX0r02QSxf6CnmsdRQCnAH+Y8xP7FB+b0x7Hj4KXHJWjmgKw/iZCYIcltpw5UhC6CLV TKqS+7TEWZX9x653IPLzRAbNMeW9CLGbl89PfEbHS4w5xiYIWnMHMzDknz3YAupITNZw 3zlIFYRfyGVlexcI8grFSdVKHv/hK481UzVIbV25x7Zm06f8aNq+0kNbc3EruZLc5QkC +YHXcWsLPBeHNl11RjQ89dIsEe3OSJMo8PyjDRvz6aK2B8fv6ON6XG61vUC1Zk/RzoF7 pvhA== 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=APNLiKmbt8JWMBZWCLrn0Q41j8dsCsL0653AwgPsFDA=; b=Y6Y89EvCu4Vo9VZo8Jg6/WZjfGYCSShhAGBLSBLDJ2sTdmsBKs/Zjszl3fCClu6NJC pB0aKTNICkAu8kwbNHFp0QF+9z19eTLr/eyGNaSz5vLie/2ebi7khzWMXDWVT+waObEq L6MELexn75LmLs3+WlbVkCYXq8e5GhiEcmYFF/ArXv3nDnWhR1uWw06IvO/qdhIyrZPz CdqUDbNidMYohZwYTkzG7GfJLoXI8pF+X8BeIcwXx2rIEd25af0LAwheoMjRTkhgN+w6 mdUi8YsKpjOZcajNdsuNJ/g1Ua4AHQTdkQlBlmz6jgUmkOpDhGF3GjUWtqbbwn0Q2N76 LcTw== X-Gm-Message-State: AFqh2kp9fbzIOk7Q5CDQ3S8WoDPFwSFhqZLuaioSHPZ2oCM15hFmd7WC jDBcvzz+dMudD3XMHDxWrs0= X-Received: by 2002:a17:906:78a:b0:86e:7683:4213 with SMTP id l10-20020a170906078a00b0086e76834213mr19743279ejc.42.1674300591806; Sat, 21 Jan 2023 03:29:51 -0800 (PST) Received: from fedora.. ([188.252.220.152]) by smtp.googlemail.com with ESMTPSA id d26-20020a056402401a00b0046c7c3755a7sm5152151eda.17.2023.01.21.03.29.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 21 Jan 2023 03:29:51 -0800 (PST) From: Robert Marko To: ilia.lin@kernel.org, agross@kernel.org, andersson@kernel.org, konrad.dybcio@linaro.org, rafael@kernel.org, viresh.kumar@linaro.org, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, linux-arm-msm@vger.kernel.org Cc: Robert Marko Subject: [PATCH 3/4] cpufreq: qcom-nvmem: use SoC ID-s from bindings Date: Sat, 21 Jan 2023 12:29:46 +0100 Message-Id: <20230121112947.53433-3-robimarko@gmail.com> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230121112947.53433-1-robimarko@gmail.com> References: <20230121112947.53433-1-robimarko@gmail.com> MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=ham 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1755631643006770115?= X-GMAIL-MSGID: =?utf-8?q?1755631643006770115?= SMEM SoC ID-s are now stored in DT bindings so lets use those instead of defining them in the driver again. Signed-off-by: Robert Marko Reviewed-by: Konrad Dybcio Reviewed-by: Bjorn Andersson --- drivers/cpufreq/qcom-cpufreq-nvmem.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/drivers/cpufreq/qcom-cpufreq-nvmem.c b/drivers/cpufreq/qcom-cpufreq-nvmem.c index c0a7841a56c1..da55d2e1925a 100644 --- a/drivers/cpufreq/qcom-cpufreq-nvmem.c +++ b/drivers/cpufreq/qcom-cpufreq-nvmem.c @@ -30,12 +30,7 @@ #include #include -enum _msm_id { - MSM8996V3 = 0xF6ul, - APQ8096V3 = 0x123ul, - MSM8996SG = 0x131ul, - APQ8096SG = 0x138ul, -}; +#include enum _msm8996_version { MSM8996_V3, @@ -150,12 +145,12 @@ static enum _msm8996_version qcom_cpufreq_get_msm_id(void) return NUM_OF_MSM8996_VERSIONS; switch (info->id) { - case MSM8996V3: - case APQ8096V3: + case QCOM_ID_MSM8996: + case QCOM_ID_APQ8096: version = MSM8996_V3; break; - case MSM8996SG: - case APQ8096SG: + case QCOM_ID_MSM8996SG: + case QCOM_ID_APQ8096SG: version = MSM8996_SG; break; default: