diff mbox

[RESEND] linux-generic: pktio: remove unwanted initialisation

Message ID 1453487429-5348-1-git-send-email-stuart.haslam@linaro.org
State Accepted
Commit 5b7969d7fd940da64f67b905c5a4b1053de9013d
Headers show

Commit Message

Stuart Haslam Jan. 22, 2016, 6:30 p.m. UTC
Remove an unwanted initialisation and fix a bad indentation which
crept in during a merge.

Signed-off-by: Stuart Haslam <stuart.haslam@linaro.org>
Reviewed-by: Ivan Khoronzhuk <ivan.khoronzhuk@linaro.org>
---
Added missing s-o-b.

 platform/linux-generic/pktio/loop.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

Comments

Maxim Uvarov Jan. 25, 2016, 11:24 a.m. UTC | #1
Merged,
Maxim.

On 01/22/2016 21:30, Stuart Haslam wrote:
> Remove an unwanted initialisation and fix a bad indentation which
> crept in during a merge.
>
> Signed-off-by: Stuart Haslam <stuart.haslam@linaro.org>
> Reviewed-by: Ivan Khoronzhuk <ivan.khoronzhuk@linaro.org>
> ---
> Added missing s-o-b.
>
>   platform/linux-generic/pktio/loop.c | 3 +--
>   1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/platform/linux-generic/pktio/loop.c b/platform/linux-generic/pktio/loop.c
> index 47745ad..95644c4 100644
> --- a/platform/linux-generic/pktio/loop.c
> +++ b/platform/linux-generic/pktio/loop.c
> @@ -57,7 +57,6 @@ static int loopback_recv(pktio_entry_t *pktio_entry, odp_packet_t pkts[],
>   	odp_packet_hdr_t *pkt_hdr;
>   	odp_packet_t pkt;
>   
> -	nbr = 0;
>   	qentry = queue_to_qentry(pktio_entry->s.pkt_loop.loopq);
>   	nbr = queue_deq_multi(qentry, hdr_tbl, len);
>   
> @@ -71,7 +70,7 @@ static int loopback_recv(pktio_entry_t *pktio_entry, odp_packet_t pkts[],
>   			if (0 > _odp_packet_classifier(pktio_entry, pkt))
>   				pkts[j++] = pkt;
>   		}
> -	nbr = j;
> +		nbr = j;
>   	} else {
>   		for (i = 0; i < nbr; ++i) {
>   			pkts[i] = _odp_packet_from_buffer(odp_hdr_to_buf
diff mbox

Patch

diff --git a/platform/linux-generic/pktio/loop.c b/platform/linux-generic/pktio/loop.c
index 47745ad..95644c4 100644
--- a/platform/linux-generic/pktio/loop.c
+++ b/platform/linux-generic/pktio/loop.c
@@ -57,7 +57,6 @@  static int loopback_recv(pktio_entry_t *pktio_entry, odp_packet_t pkts[],
 	odp_packet_hdr_t *pkt_hdr;
 	odp_packet_t pkt;
 
-	nbr = 0;
 	qentry = queue_to_qentry(pktio_entry->s.pkt_loop.loopq);
 	nbr = queue_deq_multi(qentry, hdr_tbl, len);
 
@@ -71,7 +70,7 @@  static int loopback_recv(pktio_entry_t *pktio_entry, odp_packet_t pkts[],
 			if (0 > _odp_packet_classifier(pktio_entry, pkt))
 				pkts[j++] = pkt;
 		}
-	nbr = j;
+		nbr = j;
 	} else {
 		for (i = 0; i < nbr; ++i) {
 			pkts[i] = _odp_packet_from_buffer(odp_hdr_to_buf