All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2][next] phy: samsung-ufs: Fix IS_ERR argument
@ 2020-07-20 13:27 ` Gustavo A. R. Silva
  2020-07-21  0:46   ` Alim Akhtar
  2020-07-21 10:39   ` Vinod Koul
  0 siblings, 2 replies; 4+ messages in thread
From: Gustavo A. R. Silva @ 2020-07-20 13:27 UTC (permalink / raw)
  To: Kishon Vijay Abraham I, Vinod Koul, Seungwon Jeon, Alim Akhtar,
	Kiwoong Kim
  Cc: linux-kernel, Gustavo A. R. Silva

Fix IS_ERR argument in samsung_ufs_phy_symbol_clk_init(). The proper
argument to be passed to IS_ERR() is phy->rx1_symbol_clk.

This bug was detected with the help of Coccinelle.

Fixes: bca21e930451 ("phy: samsung-ufs: add UFS PHY driver for samsung SoC")
Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org>
---
Changes in v2:
 - Update subject line and changelog text.

 drivers/phy/samsung/phy-samsung-ufs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/phy/samsung/phy-samsung-ufs.c b/drivers/phy/samsung/phy-samsung-ufs.c
index 43ef77d1d96c..9832599a0283 100644
--- a/drivers/phy/samsung/phy-samsung-ufs.c
+++ b/drivers/phy/samsung/phy-samsung-ufs.c
@@ -147,7 +147,7 @@ static int samsung_ufs_phy_symbol_clk_init(struct samsung_ufs_phy *phy)
 	}
 
 	phy->rx1_symbol_clk = devm_clk_get(phy->dev, "rx1_symbol_clk");
-	if (IS_ERR(phy->rx0_symbol_clk)) {
+	if (IS_ERR(phy->rx1_symbol_clk)) {
 		dev_err(phy->dev, "failed to get rx1_symbol_clk clock\n");
 		return PTR_ERR(phy->rx1_symbol_clk);
 	}
-- 
2.27.0


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

* RE: [PATCH v2][next] phy: samsung-ufs: Fix IS_ERR argument
  2020-07-20 13:27 ` [PATCH v2][next] phy: samsung-ufs: Fix IS_ERR argument Gustavo A. R. Silva
@ 2020-07-21  0:46   ` Alim Akhtar
  2020-07-21  0:58     ` Gustavo A. R. Silva
  2020-07-21 10:39   ` Vinod Koul
  1 sibling, 1 reply; 4+ messages in thread
From: Alim Akhtar @ 2020-07-21  0:46 UTC (permalink / raw)
  To: 'Gustavo A. R. Silva', 'Kishon Vijay Abraham I',
	'Vinod Koul', 'Seungwon Jeon',
	'Kiwoong Kim'
  Cc: linux-kernel

Hi Gustavo,

> -----Original Message-----
> From: Gustavo A. R. Silva <gustavoars@kernel.org>
> Sent: 20 July 2020 18:57
> To: Kishon Vijay Abraham I <kishon@ti.com>; Vinod Koul <vkoul@kernel.org>;
> Seungwon Jeon <essuuj@gmail.com>; Alim Akhtar
> <alim.akhtar@samsung.com>; Kiwoong Kim <kwmad.kim@samsung.com>
> Cc: linux-kernel@vger.kernel.org; Gustavo A. R. Silva
<gustavoars@kernel.org>
> Subject: [PATCH v2][next] phy: samsung-ufs: Fix IS_ERR argument
> 
> Fix IS_ERR argument in samsung_ufs_phy_symbol_clk_init(). The proper
> argument to be passed to IS_ERR() is phy->rx1_symbol_clk.
> 
> This bug was detected with the help of Coccinelle.
> 
> Fixes: bca21e930451 ("phy: samsung-ufs: add UFS PHY driver for samsung
SoC")
> Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org>
> ---
Reviewed-by: Alim Akhtar <alim.akhtar@samsung.com>

> Changes in v2:
>  - Update subject line and changelog text.
> 
>  drivers/phy/samsung/phy-samsung-ufs.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/phy/samsung/phy-samsung-ufs.c
> b/drivers/phy/samsung/phy-samsung-ufs.c
> index 43ef77d1d96c..9832599a0283 100644
> --- a/drivers/phy/samsung/phy-samsung-ufs.c
> +++ b/drivers/phy/samsung/phy-samsung-ufs.c
> @@ -147,7 +147,7 @@ static int samsung_ufs_phy_symbol_clk_init(struct
> samsung_ufs_phy *phy)
>  	}
> 
>  	phy->rx1_symbol_clk = devm_clk_get(phy->dev, "rx1_symbol_clk");
> -	if (IS_ERR(phy->rx0_symbol_clk)) {
> +	if (IS_ERR(phy->rx1_symbol_clk)) {
>  		dev_err(phy->dev, "failed to get rx1_symbol_clk clock\n");
>  		return PTR_ERR(phy->rx1_symbol_clk);
>  	}
> --
> 2.27.0



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

* Re: [PATCH v2][next] phy: samsung-ufs: Fix IS_ERR argument
  2020-07-21  0:46   ` Alim Akhtar
@ 2020-07-21  0:58     ` Gustavo A. R. Silva
  0 siblings, 0 replies; 4+ messages in thread
From: Gustavo A. R. Silva @ 2020-07-21  0:58 UTC (permalink / raw)
  To: Alim Akhtar, 'Gustavo A. R. Silva',
	'Kishon Vijay Abraham I', 'Vinod Koul',
	'Seungwon Jeon', 'Kiwoong Kim'
  Cc: linux-kernel



On 7/20/20 19:46, Alim Akhtar wrote:
> Hi Gustavo,
> 
>> -----Original Message-----
>> From: Gustavo A. R. Silva <gustavoars@kernel.org>
>> Sent: 20 July 2020 18:57
>> To: Kishon Vijay Abraham I <kishon@ti.com>; Vinod Koul <vkoul@kernel.org>;
>> Seungwon Jeon <essuuj@gmail.com>; Alim Akhtar
>> <alim.akhtar@samsung.com>; Kiwoong Kim <kwmad.kim@samsung.com>
>> Cc: linux-kernel@vger.kernel.org; Gustavo A. R. Silva
> <gustavoars@kernel.org>
>> Subject: [PATCH v2][next] phy: samsung-ufs: Fix IS_ERR argument
>>
>> Fix IS_ERR argument in samsung_ufs_phy_symbol_clk_init(). The proper
>> argument to be passed to IS_ERR() is phy->rx1_symbol_clk.
>>
>> This bug was detected with the help of Coccinelle.
>>
>> Fixes: bca21e930451 ("phy: samsung-ufs: add UFS PHY driver for samsung
> SoC")
>> Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org>
>> ---
> Reviewed-by: Alim Akhtar <alim.akhtar@samsung.com>
> 

Thanks, Alim.

--
Gustavo

>> Changes in v2:
>>  - Update subject line and changelog text.
>>
>>  drivers/phy/samsung/phy-samsung-ufs.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/phy/samsung/phy-samsung-ufs.c
>> b/drivers/phy/samsung/phy-samsung-ufs.c
>> index 43ef77d1d96c..9832599a0283 100644
>> --- a/drivers/phy/samsung/phy-samsung-ufs.c
>> +++ b/drivers/phy/samsung/phy-samsung-ufs.c
>> @@ -147,7 +147,7 @@ static int samsung_ufs_phy_symbol_clk_init(struct
>> samsung_ufs_phy *phy)
>>  	}
>>
>>  	phy->rx1_symbol_clk = devm_clk_get(phy->dev, "rx1_symbol_clk");
>> -	if (IS_ERR(phy->rx0_symbol_clk)) {
>> +	if (IS_ERR(phy->rx1_symbol_clk)) {
>>  		dev_err(phy->dev, "failed to get rx1_symbol_clk clock\n");
>>  		return PTR_ERR(phy->rx1_symbol_clk);
>>  	}
>> --
>> 2.27.0
> 
> 

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

* Re: [PATCH v2][next] phy: samsung-ufs: Fix IS_ERR argument
  2020-07-20 13:27 ` [PATCH v2][next] phy: samsung-ufs: Fix IS_ERR argument Gustavo A. R. Silva
  2020-07-21  0:46   ` Alim Akhtar
@ 2020-07-21 10:39   ` Vinod Koul
  1 sibling, 0 replies; 4+ messages in thread
From: Vinod Koul @ 2020-07-21 10:39 UTC (permalink / raw)
  To: Gustavo A. R. Silva
  Cc: Kishon Vijay Abraham I, Seungwon Jeon, Alim Akhtar, Kiwoong Kim,
	linux-kernel

On 20-07-20, 08:27, Gustavo A. R. Silva wrote:
> Fix IS_ERR argument in samsung_ufs_phy_symbol_clk_init(). The proper
> argument to be passed to IS_ERR() is phy->rx1_symbol_clk.
> 
> This bug was detected with the help of Coccinelle.

Applied, thanks

-- 
~Vinod

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

end of thread, other threads:[~2020-07-21 10:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CGME20200720132147epcas5p14aba715032bcda00fad2147cac8b354b@epcas5p1.samsung.com>
2020-07-20 13:27 ` [PATCH v2][next] phy: samsung-ufs: Fix IS_ERR argument Gustavo A. R. Silva
2020-07-21  0:46   ` Alim Akhtar
2020-07-21  0:58     ` Gustavo A. R. Silva
2020-07-21 10:39   ` Vinod Koul

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.