diff mbox series

[-next] crypto: chelsio - remove set but not used variable 'adap'

Message ID 20200314104441.79953-1-yuehaibing@huawei.com (mailing list archive)
State Accepted
Delegated to: Herbert Xu
Headers show
Series [-next] crypto: chelsio - remove set but not used variable 'adap' | expand

Commit Message

Yue Haibing March 14, 2020, 10:44 a.m. UTC
drivers/crypto/chelsio/chcr_algo.c: In function 'chcr_device_init':
drivers/crypto/chelsio/chcr_algo.c:1440:18: warning:
 variable 'adap' set but not used [-Wunused-but-set-variable]
 
commit 567be3a5d227 ("crypto: chelsio - Use multiple txq/rxq per tfm
to process the requests") involved this unused variable.

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 drivers/crypto/chelsio/chcr_algo.c | 2 --
 1 file changed, 2 deletions(-)

Comments

Rohit Maheshwari March 15, 2020, 4:10 p.m. UTC | #1
On 14/03/20 4:14 PM, YueHaibing wrote:
> drivers/crypto/chelsio/chcr_algo.c: In function 'chcr_device_init':
> drivers/crypto/chelsio/chcr_algo.c:1440:18: warning:
>   variable 'adap' set but not used [-Wunused-but-set-variable]
>   
> commit 567be3a5d227 ("crypto: chelsio - Use multiple txq/rxq per tfm
> to process the requests") involved this unused variable.
>
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
> ---
>   drivers/crypto/chelsio/chcr_algo.c | 2 --
>   1 file changed, 2 deletions(-)
>
> diff --git a/drivers/crypto/chelsio/chcr_algo.c b/drivers/crypto/chelsio/chcr_algo.c
> index 8952732c0b7d..c29b80dd30d8 100644
> --- a/drivers/crypto/chelsio/chcr_algo.c
> +++ b/drivers/crypto/chelsio/chcr_algo.c
> @@ -1437,7 +1437,6 @@ static int chcr_aes_decrypt(struct skcipher_request *req)
>   static int chcr_device_init(struct chcr_context *ctx)
>   {
>   	struct uld_ctx *u_ctx = NULL;
> -	struct adapter *adap;
>   	int txq_perchan, ntxq;
>   	int err = 0, rxq_perchan;
>   
> @@ -1448,7 +1447,6 @@ static int chcr_device_init(struct chcr_context *ctx)
>   			goto out;
>   		}
>   		ctx->dev = &u_ctx->dev;
> -		adap = padap(ctx->dev);
>   		ntxq = u_ctx->lldi.ntxq;
>   		rxq_perchan = u_ctx->lldi.nrxq / u_ctx->lldi.nchan;
>   		txq_perchan = ntxq / u_ctx->lldi.nchan;
>
Thanks for fixing it. Looks good to me.
>
Herbert Xu March 20, 2020, 3:51 a.m. UTC | #2
On Sat, Mar 14, 2020 at 10:44:41AM +0000, YueHaibing wrote:
> drivers/crypto/chelsio/chcr_algo.c: In function 'chcr_device_init':
> drivers/crypto/chelsio/chcr_algo.c:1440:18: warning:
>  variable 'adap' set but not used [-Wunused-but-set-variable]
>  
> commit 567be3a5d227 ("crypto: chelsio - Use multiple txq/rxq per tfm
> to process the requests") involved this unused variable.
> 
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
> ---
>  drivers/crypto/chelsio/chcr_algo.c | 2 --
>  1 file changed, 2 deletions(-)

Patch applied.  Thanks.
diff mbox series

Patch

diff --git a/drivers/crypto/chelsio/chcr_algo.c b/drivers/crypto/chelsio/chcr_algo.c
index 8952732c0b7d..c29b80dd30d8 100644
--- a/drivers/crypto/chelsio/chcr_algo.c
+++ b/drivers/crypto/chelsio/chcr_algo.c
@@ -1437,7 +1437,6 @@  static int chcr_aes_decrypt(struct skcipher_request *req)
 static int chcr_device_init(struct chcr_context *ctx)
 {
 	struct uld_ctx *u_ctx = NULL;
-	struct adapter *adap;
 	int txq_perchan, ntxq;
 	int err = 0, rxq_perchan;
 
@@ -1448,7 +1447,6 @@  static int chcr_device_init(struct chcr_context *ctx)
 			goto out;
 		}
 		ctx->dev = &u_ctx->dev;
-		adap = padap(ctx->dev);
 		ntxq = u_ctx->lldi.ntxq;
 		rxq_perchan = u_ctx->lldi.nrxq / u_ctx->lldi.nchan;
 		txq_perchan = ntxq / u_ctx->lldi.nchan;