Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp3172310rwd; Mon, 22 May 2023 09:34:56 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6U5mq1H2+ptNXIrB0L5FdPOVzcusKYcYsA78o7SAlHR5u+4DMR3JuT+QvQ9sUYcXQbwozy X-Received: by 2002:a17:902:d34b:b0:1ad:e198:c4fc with SMTP id l11-20020a170902d34b00b001ade198c4fcmr10881712plk.54.1684773296651; Mon, 22 May 2023 09:34:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684773296; cv=none; d=google.com; s=arc-20160816; b=SyJj5cyreB/zztD8O4dqBYeux+0gKQwVEov08nDS0hMBXxInFCwD4SqxuFVn5QFS36 1Z/fUQdd2h88rTS4vigKPtsxRMxlVk1AynYygKzQCO7BME5sO+7VKe2riT6prcZlROyT lAcoeQOBt06g6i6zP1fqZSFryf6OWBjNiQu2jlIGZeI4bFi2S0N9Q4e/wW3PXc+8aH/k ry/GbhAuEkE2rKmTcD9xZhWdK8HeSTsKoEboC/A3amK/4mQ2/UZsJm2f0eKLIXbez1bj BqdWt6SfoHpha/Pmdy6z5/yqjhk6xr6GxX+vkcTsv/kUr3ex8YlsQPDvNNCYnqDcNeIt gdzw== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=OeP+B1gScMLY21VO6JStum8TjH65rS3eZqbyyJSsz8M=; b=mP2bblJ5i8u99MdkGTGYl4apr9FOip3/YAkxjRc+c91y01rrm1VhPLe+Hsq7cxx0Q0 aFE/8JfCty738XP1EkgQMjV6xNDZrWWDSC+iKwIYn/pUMlK8ToYZWY/MeQZj+S7ugcoL 4bIkEyU/xy8Uc3CtpQWU2jzOZ23NEIdmuwAdnxbtZp6FpHoku5FNxz3sVIaUxTOe1oFo nhSsoCj1yPDddmzaAa9V91uVv1TFBelLwd2IWLFm28GLod3iEZ+RnlNcWYKeeLDgYKny kmn6XaH6ja9PP+gTLQKiTY6R7CFZhsK/r/uuz8UO55GNviRWr7e8FSRYFdNXAv+etN7c QOuw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=LzyczJMt; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f4-20020a17090274c400b001ab147e4543si4800537plt.418.2023.05.22.09.34.43; Mon, 22 May 2023 09:34:56 -0700 (PDT) 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=20221208 header.b=LzyczJMt; 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 S233450AbjEVQIE (ORCPT + 99 others); Mon, 22 May 2023 12:08:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54476 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231147AbjEVQID (ORCPT ); Mon, 22 May 2023 12:08:03 -0400 Received: from mail-pf1-x432.google.com (mail-pf1-x432.google.com [IPv6:2607:f8b0:4864:20::432]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B3BFAB6; Mon, 22 May 2023 09:08:02 -0700 (PDT) Received: by mail-pf1-x432.google.com with SMTP id d2e1a72fcca58-64d5b4c3ffeso1259815b3a.2; Mon, 22 May 2023 09:08:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1684771682; x=1687363682; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=OeP+B1gScMLY21VO6JStum8TjH65rS3eZqbyyJSsz8M=; b=LzyczJMt4H4N9i8we+GVkc/5i6X6cfp1h0iEctL4SKrhZ+c2YYrJQm0M1doX6uKxFK za3EW81MsgrK7Gyqw5JA/gzK8Xrq6611Gpe8z+/TAOUmnTLP0sgJLJY2/GaA+qGSKE5L nwfIuebnsPQR9vaBun1w1Afec9MCi8xLwhaPRznvr0ef+qUJx6F1jJihvGCsUoIrANI7 gyOtxNdjAV+g1BG7aBDVD4uLhFK1QLg70YlPO2KLAQof9bBQuZOVtl/m24MwBZRIFezH bIK92z3a2brCS/7eYP7X45lP6UPUw3yBy4l3FDbbc4zNMExafyoaOpMxRtVXorRh+gID Molw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684771682; x=1687363682; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=OeP+B1gScMLY21VO6JStum8TjH65rS3eZqbyyJSsz8M=; b=YabSMmpUPmKvVOfi3HGgsmlsXnh4JP3ab8o8xjHcjSZSQVC0v4Wljue5C2QTqSTTG8 IY7IpPglKRBhLciDFVURNYmwq6PZ2IJEbC8ZdlLTKWqltXgLsvsVAkGoY6292Lfl9w3y Fdoa1378RZFLYhBNxsywDTQxaD1fmT3o+9UOmoZxzpW8AkVEnfabe4Ux+aGaOJOLEzdp t2y6nhW5QWEmRLQmrqxv/BV3AunlI4oe6LMeCzgorswWCunYpuDtlwsVE1GQ12+l43pX AeQ0fHbfguErNtzXGV51SdngmHnQCV7DkHsKrMHLUqqrR+E8OvABkgxLHWqVyMdmGPdd xe9w== X-Gm-Message-State: AC+VfDzR+0GfExkBYqZhpNm19Eb2sXuORN9XXjAqgJOS3RsopHh5REr8 k4u2bCaned1r0EVoXMWn51o= X-Received: by 2002:a05:6a21:99a8:b0:10c:3557:399a with SMTP id ve40-20020a056a2199a800b0010c3557399amr896261pzb.49.1684771682082; Mon, 22 May 2023 09:08:02 -0700 (PDT) Received: from ubuntu777.domain.name (36-228-81-153.dynamic-ip.hinet.net. [36.228.81.153]) by smtp.gmail.com with ESMTPSA id 21-20020aa79215000000b0064858e255d1sm4345017pfo.65.2023.05.22.09.08.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 22 May 2023 09:08:01 -0700 (PDT) From: Min-Hua Chen To: Andy Gross , Bjorn Andersson , Konrad Dybcio Cc: Min-Hua Chen , linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] soc: qcom: rpmpd: use correct __le32 type Date: Tue, 23 May 2023 00:07:56 +0800 Message-Id: <20230522160757.284165-1-minhuadotchen@gmail.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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,T_SCC_BODY_TEXT_LINE 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 Use cpu_to_le32 to cast constants to __le32 before comparing them with __le32 type pd->key. This fixes the following sparse warnings: drivers/soc/qcom/rpmpd.c:895:31: sparse: warning: restricted __le32 degrades to integer drivers/soc/qcom/rpmpd.c:896:15: sparse: warning: restricted __le32 degrades to integer Signed-off-by: Min-Hua Chen --- drivers/soc/qcom/rpmpd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c index f8397dcb146c..99b017fd76b7 100644 --- a/drivers/soc/qcom/rpmpd.c +++ b/drivers/soc/qcom/rpmpd.c @@ -892,8 +892,8 @@ static int rpmpd_set_performance(struct generic_pm_domain *domain, pd->corner = state; /* Always send updates for vfc and vfl */ - if (!pd->enabled && pd->key != KEY_FLOOR_CORNER && - pd->key != KEY_FLOOR_LEVEL) + if (!pd->enabled && pd->key != cpu_to_le32(KEY_FLOOR_CORNER) && + pd->key != cpu_to_le32(KEY_FLOOR_LEVEL)) goto out; ret = rpmpd_aggregate_corner(pd); -- 2.34.1