DPDK patches and discussions
 help / color / mirror / Atom feed
From: Pavan Nikhilesh Bhagavatula <pbhagavatula@marvell.com>
To: Bruce Richardson <bruce.richardson@intel.com>
Cc: Jerin Jacob Kollanukkaran <jerinj@marvell.com>,
	"thomas@monjalon.net" <thomas@monjalon.net>,
	"dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] [EXT] Re: [PATCH] app/testpmd: fix ether header size calculation
Date: Mon, 8 Apr 2019 12:28:59 +0000	[thread overview]
Message-ID: <CY4PR1801MB1863146DA7866E0C942C84AFDE2C0@CY4PR1801MB1863.namprd18.prod.outlook.com> (raw)
Message-ID: <20190408122859.k5LvJzclYDbxIzWnQuCSsQ2ki923tIFXjZr-7weOHi0@z> (raw)
In-Reply-To: <20190408115759.GB1742@bricha3-MOBL.ger.corp.intel.com>



>-----Original Message-----
>From: Bruce Richardson <bruce.richardson@intel.com>
>Sent: Monday, April 8, 2019 5:28 PM
>To: Pavan Nikhilesh Bhagavatula <pbhagavatula@marvell.com>
>Cc: Jerin Jacob Kollanukkaran <jerinj@marvell.com>; thomas@monjalon.net;
>dev@dpdk.org
>Subject: [EXT] Re: [dpdk-dev] [PATCH] app/testpmd: fix ether header size
>calculation
>
>External Email
>
>----------------------------------------------------------------------
>On Mon, Apr 08, 2019 at 10:13:04AM +0000, Pavan Nikhilesh Bhagavatula wrote:
>> From: Pavan Nikhilesh <pbhagavatula@marvell.com>
>>
>> Fix ether header size calculation in Tx only mode.
>>
>> Coverity issue: 337684
>> Fixes: 01b645dcff7f ("app/testpmd: move txonly prepare in separate
>> function")
>>
>> Signed-off-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
>> ---
>>  app/test-pmd/txonly.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/app/test-pmd/txonly.c b/app/test-pmd/txonly.c index
>> 66e63788a..a9c27be3e 100644
>> --- a/app/test-pmd/txonly.c
>> +++ b/app/test-pmd/txonly.c
>> @@ -189,7 +189,7 @@ pkt_burst_prepare(struct rte_mbuf *pkt, struct
>rte_mempool *mbp,
>>  	/*
>>  	 * Copy headers in first packet segment(s).
>>  	 */
>> -	copy_buf_to_pkt(eth_hdr, sizeof(eth_hdr), pkt, 0);
>> +	copy_buf_to_pkt(eth_hdr, sizeof(struct ether_hdr), pkt, 0);
>
>Would a simpler fix not be to change "sizeof(eth_hdr)" to "sizeof(*eth_hdr)"? It
>would keep the logical connection between the destination and destination size,
>and make future refactoring easier.
>
Ack, will send v2. 
>/Bruce

  parent reply	other threads:[~2019-04-08 12:29 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-08 10:13 [dpdk-dev] " Pavan Nikhilesh Bhagavatula
2019-04-08 10:13 ` Pavan Nikhilesh Bhagavatula
2019-04-08 11:57 ` Bruce Richardson
2019-04-08 11:57   ` Bruce Richardson
2019-04-08 12:28   ` Pavan Nikhilesh Bhagavatula [this message]
2019-04-08 12:28     ` [dpdk-dev] [EXT] " Pavan Nikhilesh Bhagavatula
2019-04-09  9:45 ` [dpdk-dev] [PATCH v2] " Pavan Nikhilesh Bhagavatula
2019-04-09  9:45   ` Pavan Nikhilesh Bhagavatula
2019-04-09 20:59   ` Ferruh Yigit
2019-04-09 20:59     ` Ferruh Yigit
2019-04-10  1:23     ` Yao, Lei A
2019-04-10  1:23       ` Yao, Lei A

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CY4PR1801MB1863146DA7866E0C942C84AFDE2C0@CY4PR1801MB1863.namprd18.prod.outlook.com \
    --to=pbhagavatula@marvell.com \
    --cc=bruce.richardson@intel.com \
    --cc=dev@dpdk.org \
    --cc=jerinj@marvell.com \
    --cc=thomas@monjalon.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).