patches for DPDK stable branches
 help / color / mirror / Atom feed
* [dpdk-stable] [PATCH] net/af_xdp: change return value from Rx to unsigned
@ 2020-08-07  9:32 Ciara Loftus
  2020-08-07 10:07 ` Ferruh Yigit
  0 siblings, 1 reply; 3+ messages in thread
From: Ciara Loftus @ 2020-08-07  9:32 UTC (permalink / raw)
  To: dev; +Cc: Ciara Loftus, stable

The af_xdp rx function was returning a negative value on error, when an
unsigned value is expected. Fix this.

Fixes: d8a210774e1d ("net/af_xdp: support unaligned umem chunks")
Cc: stable@dpdk.org

Signed-off-by: Ciara Loftus <ciara.loftus@intel.com>
---
 drivers/net/af_xdp/rte_eth_af_xdp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/af_xdp/rte_eth_af_xdp.c b/drivers/net/af_xdp/rte_eth_af_xdp.c
index 936d4a7d5f..7ce4ad04af 100644
--- a/drivers/net/af_xdp/rte_eth_af_xdp.c
+++ b/drivers/net/af_xdp/rte_eth_af_xdp.c
@@ -236,7 +236,7 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
 	if (rte_pktmbuf_alloc_bulk(umem->mb_pool, fq_bufs, nb_pkts)) {
 		AF_XDP_LOG(DEBUG,
 			"Failed to get enough buffers for fq.\n");
-		return -1;
+		return 0;
 	}
 
 	rcvd = xsk_ring_cons__peek(rx, nb_pkts, &idx_rx);
-- 
2.17.1


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

* Re: [dpdk-stable] [PATCH] net/af_xdp: change return value from Rx to unsigned
  2020-08-07  9:32 [dpdk-stable] [PATCH] net/af_xdp: change return value from Rx to unsigned Ciara Loftus
@ 2020-08-07 10:07 ` Ferruh Yigit
  2020-09-01 15:10   ` Ferruh Yigit
  0 siblings, 1 reply; 3+ messages in thread
From: Ferruh Yigit @ 2020-08-07 10:07 UTC (permalink / raw)
  To: Ciara Loftus, dev; +Cc: stable

On 8/7/2020 10:32 AM, Ciara Loftus wrote:
> The af_xdp rx function was returning a negative value on error, when an
> unsigned value is expected. Fix this.
> 
> Fixes: d8a210774e1d ("net/af_xdp: support unaligned umem chunks")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Ciara Loftus <ciara.loftus@intel.com>
> ---
>  drivers/net/af_xdp/rte_eth_af_xdp.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/af_xdp/rte_eth_af_xdp.c b/drivers/net/af_xdp/rte_eth_af_xdp.c
> index 936d4a7d5f..7ce4ad04af 100644
> --- a/drivers/net/af_xdp/rte_eth_af_xdp.c
> +++ b/drivers/net/af_xdp/rte_eth_af_xdp.c
> @@ -236,7 +236,7 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
>  	if (rte_pktmbuf_alloc_bulk(umem->mb_pool, fq_bufs, nb_pkts)) {
>  		AF_XDP_LOG(DEBUG,
>  			"Failed to get enough buffers for fq.\n");
> -		return -1;
> +		return 0;
>  	}
>  
>  	rcvd = xsk_ring_cons__peek(rx, nb_pkts, &idx_rx);
> 

Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>

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

* Re: [dpdk-stable] [PATCH] net/af_xdp: change return value from Rx to unsigned
  2020-08-07 10:07 ` Ferruh Yigit
@ 2020-09-01 15:10   ` Ferruh Yigit
  0 siblings, 0 replies; 3+ messages in thread
From: Ferruh Yigit @ 2020-09-01 15:10 UTC (permalink / raw)
  To: Ciara Loftus, dev; +Cc: stable

On 8/7/2020 11:07 AM, Ferruh Yigit wrote:
> On 8/7/2020 10:32 AM, Ciara Loftus wrote:
>> The af_xdp rx function was returning a negative value on error, when an
>> unsigned value is expected. Fix this.
>>
>> Fixes: d8a210774e1d ("net/af_xdp: support unaligned umem chunks")
>> Cc: stable@dpdk.org
>>
>> Signed-off-by: Ciara Loftus <ciara.loftus@intel.com>
>> ---
>>  drivers/net/af_xdp/rte_eth_af_xdp.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/net/af_xdp/rte_eth_af_xdp.c b/drivers/net/af_xdp/rte_eth_af_xdp.c
>> index 936d4a7d5f..7ce4ad04af 100644
>> --- a/drivers/net/af_xdp/rte_eth_af_xdp.c
>> +++ b/drivers/net/af_xdp/rte_eth_af_xdp.c
>> @@ -236,7 +236,7 @@ af_xdp_rx_zc(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts)
>>  	if (rte_pktmbuf_alloc_bulk(umem->mb_pool, fq_bufs, nb_pkts)) {
>>  		AF_XDP_LOG(DEBUG,
>>  			"Failed to get enough buffers for fq.\n");
>> -		return -1;
>> +		return 0;
>>  	}
>>  
>>  	rcvd = xsk_ring_cons__peek(rx, nb_pkts, &idx_rx);
>>
> 
> Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
> 

Applied to dpdk-next-net/main, thanks.

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

end of thread, other threads:[~2020-09-01 15:10 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-07  9:32 [dpdk-stable] [PATCH] net/af_xdp: change return value from Rx to unsigned Ciara Loftus
2020-08-07 10:07 ` Ferruh Yigit
2020-09-01 15:10   ` Ferruh Yigit

patches for DPDK stable branches

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://inbox.dpdk.org/stable/0 stable/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 stable stable/ http://inbox.dpdk.org/stable \
		stable@dpdk.org
	public-inbox-index stable

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.stable


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git