diff mbox series

Provider/rxe: Remove printf()

Message ID 20210929214214.18767-1-rpearsonhpe@gmail.com (mailing list archive)
State Changes Requested
Headers show
Series Provider/rxe: Remove printf() | expand

Commit Message

Bob Pearson Sept. 29, 2021, 9:42 p.m. UTC
Currently the rxe provider issues a print statement if it detects
an invalid work request and also returns an error. A recently
added python test case triggers such a message which is expected
since the test is deliberately constructing invalid work requests.

This patch removes the print statement which has no practical use.

Signed-off-by: Bob Pearson <rpearsonhpe@gmail.com>
---
 providers/rxe/rxe.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

Comments

Leon Romanovsky Sept. 30, 2021, 5:18 a.m. UTC | #1
On Wed, Sep 29, 2021 at 04:42:15PM -0500, Bob Pearson wrote:
> Currently the rxe provider issues a print statement if it detects
> an invalid work request and also returns an error. A recently
> added python test case triggers such a message which is expected
> since the test is deliberately constructing invalid work requests.
> 
> This patch removes the print statement which has no practical use.
> 
> Signed-off-by: Bob Pearson <rpearsonhpe@gmail.com>
> ---
>  providers/rxe/rxe.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)

Please remove this "fprintf(stderr, "rxe: Failed to query sgid.\n");"
line too.

Thanks

> 
> diff --git a/providers/rxe/rxe.c b/providers/rxe/rxe.c
> index 3533a325..42fc447c 100644
> --- a/providers/rxe/rxe.c
> +++ b/providers/rxe/rxe.c
> @@ -1513,10 +1513,8 @@ static int post_one_send(struct rxe_qp *qp, struct rxe_wq *sq,
>  		length += ibwr->sg_list[i].length;
>  
>  	err = validate_send_wr(qp, ibwr, length);
> -	if (err) {
> -		printf("validate send failed\n");
> +	if (err)
>  		return err;
> -	}
>  
>  	wqe = (struct rxe_send_wqe *)producer_addr(sq->queue);
>  
> -- 
> 2.30.2
>
Bob Pearson Sept. 30, 2021, 8:05 p.m. UTC | #2
On 9/30/21 12:18 AM, Leon Romanovsky wrote:
> On Wed, Sep 29, 2021 at 04:42:15PM -0500, Bob Pearson wrote:
>> Currently the rxe provider issues a print statement if it detects
>> an invalid work request and also returns an error. A recently
>> added python test case triggers such a message which is expected
>> since the test is deliberately constructing invalid work requests.
>>
>> This patch removes the print statement which has no practical use.
>>
>> Signed-off-by: Bob Pearson <rpearsonhpe@gmail.com>
>> ---
>>  providers/rxe/rxe.c | 4 +---
>>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> Please remove this "fprintf(stderr, "rxe: Failed to query sgid.\n");"
> line too.
> 
> Thanks
> 
NP
>>
>> diff --git a/providers/rxe/rxe.c b/providers/rxe/rxe.c
>> index 3533a325..42fc447c 100644
>> --- a/providers/rxe/rxe.c
>> +++ b/providers/rxe/rxe.c
>> @@ -1513,10 +1513,8 @@ static int post_one_send(struct rxe_qp *qp, struct rxe_wq *sq,
>>  		length += ibwr->sg_list[i].length;
>>  
>>  	err = validate_send_wr(qp, ibwr, length);
>> -	if (err) {
>> -		printf("validate send failed\n");
>> +	if (err)
>>  		return err;
>> -	}
>>  
>>  	wqe = (struct rxe_send_wqe *)producer_addr(sq->queue);
>>  
>> -- 
>> 2.30.2
>>
diff mbox series

Patch

diff --git a/providers/rxe/rxe.c b/providers/rxe/rxe.c
index 3533a325..42fc447c 100644
--- a/providers/rxe/rxe.c
+++ b/providers/rxe/rxe.c
@@ -1513,10 +1513,8 @@  static int post_one_send(struct rxe_qp *qp, struct rxe_wq *sq,
 		length += ibwr->sg_list[i].length;
 
 	err = validate_send_wr(qp, ibwr, length);
-	if (err) {
-		printf("validate send failed\n");
+	if (err)
 		return err;
-	}
 
 	wqe = (struct rxe_send_wqe *)producer_addr(sq->queue);