All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] soc: qcom: smd-rpm: Correct the active vs sleep state flagging
@ 2015-10-13 20:57 ` Bjorn Andersson
  0 siblings, 0 replies; 4+ messages in thread
From: Bjorn Andersson @ 2015-10-13 20:57 UTC (permalink / raw)
  To: Andy Gross, Georgi Djakov; +Cc: linux-arm-msm, linux-soc, linux-kernel

The BIT() was incorrectly inherited from family A and should not be used
on family B where the state is denoted by an enum.

Reported-by: Georgi Djakov <georgi.djakov@linaro.org>
Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com>
---
 drivers/soc/qcom/smd-rpm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/soc/qcom/smd-rpm.c b/drivers/soc/qcom/smd-rpm.c
index b5feb58dbd9f..2969321e1b09 100644
--- a/drivers/soc/qcom/smd-rpm.c
+++ b/drivers/soc/qcom/smd-rpm.c
@@ -126,7 +126,7 @@ int qcom_rpm_smd_write(struct qcom_smd_rpm *rpm,
 	pkt->hdr.length = cpu_to_le32(sizeof(struct qcom_rpm_request) + count);
 
 	pkt->req.msg_id = cpu_to_le32(msg_id++);
-	pkt->req.flags = cpu_to_le32(BIT(state));
+	pkt->req.flags = cpu_to_le32(state);
 	pkt->req.type = cpu_to_le32(type);
 	pkt->req.id = cpu_to_le32(id);
 	pkt->req.data_len = cpu_to_le32(count);
-- 
2.4.2

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH] soc: qcom: smd-rpm: Correct the active vs sleep state flagging
@ 2015-10-13 20:57 ` Bjorn Andersson
  0 siblings, 0 replies; 4+ messages in thread
From: Bjorn Andersson @ 2015-10-13 20:57 UTC (permalink / raw)
  To: Andy Gross, Georgi Djakov; +Cc: linux-arm-msm, linux-soc, linux-kernel

The BIT() was incorrectly inherited from family A and should not be used
on family B where the state is denoted by an enum.

Reported-by: Georgi Djakov <georgi.djakov@linaro.org>
Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com>
---
 drivers/soc/qcom/smd-rpm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/soc/qcom/smd-rpm.c b/drivers/soc/qcom/smd-rpm.c
index b5feb58dbd9f..2969321e1b09 100644
--- a/drivers/soc/qcom/smd-rpm.c
+++ b/drivers/soc/qcom/smd-rpm.c
@@ -126,7 +126,7 @@ int qcom_rpm_smd_write(struct qcom_smd_rpm *rpm,
 	pkt->hdr.length = cpu_to_le32(sizeof(struct qcom_rpm_request) + count);
 
 	pkt->req.msg_id = cpu_to_le32(msg_id++);
-	pkt->req.flags = cpu_to_le32(BIT(state));
+	pkt->req.flags = cpu_to_le32(state);
 	pkt->req.type = cpu_to_le32(type);
 	pkt->req.id = cpu_to_le32(id);
 	pkt->req.data_len = cpu_to_le32(count);
-- 
2.4.2


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] soc: qcom: smd-rpm: Correct the active vs sleep state flagging
  2015-10-13 20:57 ` Bjorn Andersson
  (?)
@ 2015-10-14  2:15 ` Andy Gross
  -1 siblings, 0 replies; 4+ messages in thread
From: Andy Gross @ 2015-10-14  2:15 UTC (permalink / raw)
  To: Bjorn Andersson; +Cc: Georgi Djakov, linux-arm-msm, linux-soc, linux-kernel

On Tue, Oct 13, 2015 at 01:57:43PM -0700, Bjorn Andersson wrote:
> The BIT() was incorrectly inherited from family A and should not be used
> on family B where the state is denoted by an enum.
> 
> Reported-by: Georgi Djakov <georgi.djakov@linaro.org>
> Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com>
> ---
>  drivers/soc/qcom/smd-rpm.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/soc/qcom/smd-rpm.c b/drivers/soc/qcom/smd-rpm.c
> index b5feb58dbd9f..2969321e1b09 100644
> --- a/drivers/soc/qcom/smd-rpm.c
> +++ b/drivers/soc/qcom/smd-rpm.c
> @@ -126,7 +126,7 @@ int qcom_rpm_smd_write(struct qcom_smd_rpm *rpm,
>  	pkt->hdr.length = cpu_to_le32(sizeof(struct qcom_rpm_request) + count);
>  
>  	pkt->req.msg_id = cpu_to_le32(msg_id++);
> -	pkt->req.flags = cpu_to_le32(BIT(state));
> +	pkt->req.flags = cpu_to_le32(state);

Right, nice catch.  I'll queue it up.


-- 
Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] soc: qcom: smd-rpm: Correct the active vs sleep state flagging
  2015-10-13 20:57 ` Bjorn Andersson
  (?)
  (?)
@ 2015-10-14  7:27 ` Georgi Djakov
  -1 siblings, 0 replies; 4+ messages in thread
From: Georgi Djakov @ 2015-10-14  7:27 UTC (permalink / raw)
  To: Bjorn Andersson, Andy Gross; +Cc: linux-arm-msm, linux-soc, linux-kernel

On 10/13/2015 11:57 PM, Bjorn Andersson wrote:
> The BIT() was incorrectly inherited from family A and should not be used
> on family B where the state is denoted by an enum.
> 
> Reported-by: Georgi Djakov <georgi.djakov@linaro.org>
> Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com>

Tested-by: Georgi Djakov <georgi.djakov@linaro.org>

> ---
>  drivers/soc/qcom/smd-rpm.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/soc/qcom/smd-rpm.c b/drivers/soc/qcom/smd-rpm.c
> index b5feb58dbd9f..2969321e1b09 100644
> --- a/drivers/soc/qcom/smd-rpm.c
> +++ b/drivers/soc/qcom/smd-rpm.c
> @@ -126,7 +126,7 @@ int qcom_rpm_smd_write(struct qcom_smd_rpm *rpm,
>  	pkt->hdr.length = cpu_to_le32(sizeof(struct qcom_rpm_request) + count);
>  
>  	pkt->req.msg_id = cpu_to_le32(msg_id++);
> -	pkt->req.flags = cpu_to_le32(BIT(state));
> +	pkt->req.flags = cpu_to_le32(state);
>  	pkt->req.type = cpu_to_le32(type);
>  	pkt->req.id = cpu_to_le32(id);
>  	pkt->req.data_len = cpu_to_le32(count);
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-10-14  7:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-13 20:57 [PATCH] soc: qcom: smd-rpm: Correct the active vs sleep state flagging Bjorn Andersson
2015-10-13 20:57 ` Bjorn Andersson
2015-10-14  2:15 ` Andy Gross
2015-10-14  7:27 ` Georgi Djakov

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.