Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp5062736yba; Mon, 13 May 2019 04:52:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqxd/nxgnzGW05Ih0Mdi7fIzc5E1Lw9utaSOOB72M6tsRDvCuHZymdeNwmuhwMypnGfMSyCr X-Received: by 2002:a63:7d18:: with SMTP id y24mr15814230pgc.101.1557748365879; Mon, 13 May 2019 04:52:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557748365; cv=none; d=google.com; s=arc-20160816; b=Su+HvCWlZ19szlBhiIANmsntnOFL0pujObgeAOb9QhSplksoRPRH5C3RTIG9xiLT+p gaelZRobp+2VRIFFR88qI5FajnRJufc4o+xJQJdmw0YvIjE+YC85/DTxD3lTmOResL0Z cUXX9kZIwllZpXBnr5tIV8W+0Sv9PmgWUkz3Wtz0SETuK6ALCoe8OPY0XJO5XkmjJowN KFXMlSIE/SnKVblWcuOhu+r0BuNg91xUYzBtWXDssVb9vzhPMfXqQZSa2sEpDU4Vjzjt nn5YeUrxYLvXMlDSunrsowL0/TuifSmRS+7vtJOI31mgc+y6OFeMNWO23SjDbCscUa1G pD1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dmarc-filter:dkim-signature:dkim-signature; bh=OjVM92kA4BUte1l50S0XbU6RyzerNRRtNSNc+BsExdA=; b=dL025yDI8p1tTrfU+sjvV2mKIcli3jStv4VPDgwGLX7AmBdyqu7zG+CoR2fJJwx19k ix46X3PgJFeQOwHy/WRNzvxrNYRjY7zFwS5GuwGKIZ6YtKDyWmCIWwvKoMxeNARARb+Q x+GyVfzAoYUpI/F/CfZHaMMVbx6M5qLC8uN6W/gcmOm4bd2PgtuR9ElQMJrHc9vCi1rQ WiqMNkC0MW72dSdq6Z6LyqyJ9etKx3xxXh0ppLTqVip9EJOa5VVW+g2J2EHUUeKqUm3f wNlg7M+QCFP9Y+8TP6xSMBTcM7Erml7mgAG20g+FjI3+UAXmuHpoSeDM6zSIdLE1Gc6g YU8Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=D7nZeUWx; dkim=pass header.i=@codeaurora.org header.s=default header.b=D7nZeUWx; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i4si18394406pfc.26.2019.05.13.04.52.30; Mon, 13 May 2019 04:52:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=D7nZeUWx; dkim=pass header.i=@codeaurora.org header.s=default header.b=D7nZeUWx; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728943AbfEMKUj (ORCPT + 99 others); Mon, 13 May 2019 06:20:39 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:55764 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728852AbfEMKUi (ORCPT ); Mon, 13 May 2019 06:20:38 -0400 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id B9A2660AA8; Mon, 13 May 2019 10:20:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1557742837; bh=gv7cZOA40miXv3BP7BEyZB/2v7GNv3dIS+X+E9LBQ48=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=D7nZeUWxzg+XiGuMd3cl2M201OgzHR/mJX62SXBM6L2svpIy+zXbAVoZRhCGKxipq rXQK9epk8mWjQiUIyERdDGG+Zft7p9egONnD/wgWcWAB65N7tiY5diwUF/f3dirVzg Tld4+TZuvrLe5x+ChjV0MgfVdBMkPiOVgjPZSWDQ= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.7 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_INVALID,DKIM_SIGNED autolearn=no autolearn_force=no version=3.4.0 Received: from blr-ubuntu-87.qualcomm.com (blr-bdr-fw-01_globalnat_allzones-outside.qualcomm.com [103.229.18.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: sibis@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 2B3B660A0A; Mon, 13 May 2019 10:20:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1557742837; bh=gv7cZOA40miXv3BP7BEyZB/2v7GNv3dIS+X+E9LBQ48=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=D7nZeUWxzg+XiGuMd3cl2M201OgzHR/mJX62SXBM6L2svpIy+zXbAVoZRhCGKxipq rXQK9epk8mWjQiUIyERdDGG+Zft7p9egONnD/wgWcWAB65N7tiY5diwUF/f3dirVzg Tld4+TZuvrLe5x+ChjV0MgfVdBMkPiOVgjPZSWDQ= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 2B3B660A0A Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=sibis@codeaurora.org From: Sibi Sankar To: bjorn.andersson@linaro.org, robh+dt@kernel.org, agross@kernel.org Cc: david.brown@linaro.org, mark.rutland@arm.com, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, rnayak@codeaurora.org, marc.w.gonzalez@free.fr, Sibi Sankar Subject: [PATCH v4 1/9] soc: qcom: rpmpd: fixup rpmpd set performance state Date: Mon, 13 May 2019 15:50:07 +0530 Message-Id: <20190513102015.26551-2-sibis@codeaurora.org> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190513102015.26551-1-sibis@codeaurora.org> References: <20190513102015.26551-1-sibis@codeaurora.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Remoteproc q6v5-mss calls set_performace_state with INT_MAX on rpmpd. This is currently ignored since it is greater than the max supported state. Fixup rpmpd state to max if the required state is greater than all the supported states. Fixes: 075d3db8d10d ("soc: qcom: rpmpd: Add support for get/set performance state") Reviewed-by: Marc Gonzalez Signed-off-by: Sibi Sankar --- drivers/soc/qcom/rpmpd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/soc/qcom/rpmpd.c b/drivers/soc/qcom/rpmpd.c index 005326050c23..235d01870dd8 100644 --- a/drivers/soc/qcom/rpmpd.c +++ b/drivers/soc/qcom/rpmpd.c @@ -226,7 +226,7 @@ static int rpmpd_set_performance(struct generic_pm_domain *domain, struct rpmpd *pd = domain_to_rpmpd(domain); if (state > MAX_RPMPD_STATE) - goto out; + state = MAX_RPMPD_STATE; mutex_lock(&rpmpd_lock); -- The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project