diff mbox

RDMA/ocrdma: fix a type issue in ocrdma_put_pd_num()

Message ID 20170223104016.GA27526@mwanda (mailing list archive)
State Accepted
Headers show

Commit Message

Dan Carpenter Feb. 23, 2017, 10:40 a.m. UTC
We want to return zero on success or negative error codes.  The type
should be int and not u8.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

Yuval Shaia Feb. 26, 2017, 2:26 p.m. UTC | #1
On Thu, Feb 23, 2017 at 01:40:16PM +0300, Dan Carpenter wrote:
> We want to return zero on success or negative error codes.  The type
> should be int and not u8.
> 
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
> 
> diff --git a/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c b/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c
> index e06ad7250963..b1b075763eaa 100644
> --- a/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c
> +++ b/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c
> @@ -371,7 +371,7 @@ static int _ocrdma_pd_mgr_put_bitmap(struct ocrdma_dev *dev, u16 pd_id,
>  	return 0;
>  }
>  
> -static u8 ocrdma_put_pd_num(struct ocrdma_dev *dev, u16 pd_id,
> +static int ocrdma_put_pd_num(struct ocrdma_dev *dev, u16 pd_id,
>  				   bool dpp_pool)
>  {
>  	int status;
> --

Reviewed-by: Yuval Shaia <yuval.shaia@oracle.com>

> To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Doug Ledford March 25, 2017, 1:11 a.m. UTC | #2
On Thu, 2017-02-23 at 13:40 +0300, Dan Carpenter wrote:
> We want to return zero on success or negative error codes.  The type
> should be int and not u8.
> 
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
> 
> diff --git a/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c
> b/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c
> index e06ad7250963..b1b075763eaa 100644
> --- a/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c
> +++ b/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c
> @@ -371,7 +371,7 @@ static int _ocrdma_pd_mgr_put_bitmap(struct
> ocrdma_dev *dev, u16 pd_id,
>  	return 0;
>  }
>  
> -static u8 ocrdma_put_pd_num(struct ocrdma_dev *dev, u16 pd_id,
> +static int ocrdma_put_pd_num(struct ocrdma_dev *dev, u16 pd_id,
>  				   bool dpp_pool)
>  {
>  	int status;

Thanks, applied for -rc.
diff mbox

Patch

diff --git a/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c b/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c
index e06ad7250963..b1b075763eaa 100644
--- a/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c
+++ b/drivers/infiniband/hw/ocrdma/ocrdma_verbs.c
@@ -371,7 +371,7 @@  static int _ocrdma_pd_mgr_put_bitmap(struct ocrdma_dev *dev, u16 pd_id,
 	return 0;
 }
 
-static u8 ocrdma_put_pd_num(struct ocrdma_dev *dev, u16 pd_id,
+static int ocrdma_put_pd_num(struct ocrdma_dev *dev, u16 pd_id,
 				   bool dpp_pool)
 {
 	int status;