Re: [PATCH 4/5] staging: vt6656: remove bool from vnt_radio_power_on ret

2020-01-03 Thread Dan Carpenter
On Fri, Dec 20, 2019 at 09:15:33PM +, Malcolm Priestley wrote:
> The driver uses logical only error checking a bool true would flag error.
> 

This commit message is too vague.  This is a bugfix and needs to go to
stable.  Add a Fixes tag.  Here is a suggested wording:

The caller expects this function to return zero or negative error codes
but it instead returns true so it's totally broken.



> Signed-off-by: Malcolm Priestley 
> ---
>  drivers/staging/vt6656/card.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/vt6656/card.c b/drivers/staging/vt6656/card.c
> index 56cd77fd9ea0..7958fc165462 100644
> --- a/drivers/staging/vt6656/card.c
> +++ b/drivers/staging/vt6656/card.c
> @@ -719,7 +719,7 @@ int vnt_radio_power_off(struct vnt_private *priv)
>   */
>  int vnt_radio_power_on(struct vnt_private *priv)
>  {
> - int ret = true;
> + int ret = 0;
>  

Get rid of the "ret" variable and return 0 directly.

regards,
dan carpenter

___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


[PATCH 4/5] staging: vt6656: remove bool from vnt_radio_power_on ret

2019-12-20 Thread Malcolm Priestley
The driver uses logical only error checking a bool true would flag error.

Signed-off-by: Malcolm Priestley 
---
 drivers/staging/vt6656/card.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/vt6656/card.c b/drivers/staging/vt6656/card.c
index 56cd77fd9ea0..7958fc165462 100644
--- a/drivers/staging/vt6656/card.c
+++ b/drivers/staging/vt6656/card.c
@@ -719,7 +719,7 @@ int vnt_radio_power_off(struct vnt_private *priv)
  */
 int vnt_radio_power_on(struct vnt_private *priv)
 {
-   int ret = true;
+   int ret = 0;
 
vnt_exit_deep_sleep(priv);
 
-- 
2.24.0
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel