DPDK patches and discussions
 help / color / mirror / Atom feed
From: Amit Prakash Shukla <amitprakashs@marvell.com>
To: Jerin Jacob <jerinjacobk@gmail.com>
Cc: Jerin Jacob Kollanukkaran <jerinj@marvell.com>,
	Kiran Kumar Kokkilagadda <kirankumark@marvell.com>,
	Nithin Kumar Dabilpuram <ndabilpuram@marvell.com>,
	"dev@dpdk.org" <dev@dpdk.org>
Subject: RE: [EXT] Re: [PATCH v3 2/3] graph: pcap capture for graph nodes
Date: Thu, 19 Jan 2023 14:21:27 +0000	[thread overview]
Message-ID: <PH0PR18MB5167AB661DD7FA13D60C902BC8C49@PH0PR18MB5167.namprd18.prod.outlook.com> (raw)
In-Reply-To: <CALBAE1MRHJGDU3tb-sxOL_G9UhVZQBq6ti6k+6x-LzZgXpyYCg@mail.gmail.com>

Thanks Jerin for the code review and feedback. I will make the suggested changes in next version of the patch.

> -----Original Message-----
> From: Jerin Jacob <jerinjacobk@gmail.com>
> Sent: Thursday, January 12, 2023 5:48 PM
> To: Amit Prakash Shukla <amitprakashs@marvell.com>
> Cc: Jerin Jacob Kollanukkaran <jerinj@marvell.com>; Kiran Kumar
> Kokkilagadda <kirankumark@marvell.com>; Nithin Kumar Dabilpuram
> <ndabilpuram@marvell.com>; dev@dpdk.org
> Subject: [EXT] Re: [PATCH v3 2/3] graph: pcap capture for graph nodes
> 
> External Email
> 
> ----------------------------------------------------------------------
> On Thu, Jan 12, 2023 at 3:31 PM Amit Prakash Shukla
> <amitprakashs@marvell.com> wrote:
> >
> > Implementation adds support to capture packets at each node with
> > packet metadata and node name.
> >
> > Signed-off-by: Amit Prakash Shukla <amitprakashs@marvell.com>
> > ---
> > v2:
> >  - Fixed code style issue
> >  - Fixed CI compilation issue on github-robot
> >
> >
> > diff --git a/lib/graph/graph_pcap_trace.c
> > b/lib/graph/graph_pcap_trace.c new file mode 100644 index
> > 0000000000..f7b81a7ad1
> > --- /dev/null
> > +++ b/lib/graph/graph_pcap_trace.c
> > @@ -0,0 +1,155 @@
> > +/* SPDX-License-Identifier: BSD-3-Clause
> > + * Copyright(C) 2022 Marvell International Ltd.
> 
> 2023
> 
> > +
> > +#define GRAPH_PCAP_BUF_SZ      128
> > +#define GRAPH_PCAP_NUM_PACKETS 1024
> > +#define GRAPH_PCAP_FILE_NAME_SZ        128
> > +#define GRAPH_PCAP_FILE_NAME   "/tmp/graph_pcap_capture.pcapng"
> 
> Expecting the filename from application. So no need to define here.
> 
> > +
> > +static char file_name[GRAPH_PCAP_FILE_NAME_SZ];
> > +static uint32_t pkt_buf_sz = RTE_MBUF_DEFAULT_BUF_SIZE; static
> > +uint64_t packet_to_capture = GRAPH_PCAP_NUM_PACKETS; static
> > +rte_pcapng_t *pcapng_fd; static struct rte_mempool *mp; static
> > +uint16_t port_id; static uint64_t packet_captured[RTE_MAX_LCORE];
> > +static int pcap_trace_enable;
> 
> See what it takes for multiprocess. If anything needs to be available in graph
> walk(which runs on secondary process) needs to be part of huge page. i.e
> part of rte_graph structure.
> 
> >
> > +       rte_node_process_t original_process; /**< Pcap enabled node
> > + callback */
> 
> Add comment like, "Used to store the original process when pcap is enabled"
> or so
> 
> > +
> >         /* Fast path area  */
> >  #define RTE_NODE_CTX_SZ 16
> >         uint8_t ctx[RTE_NODE_CTX_SZ] __rte_cache_aligned; /**< Node
> > Context. */ diff --git a/lib/graph/version.map b/lib/graph/version.map
> > index 13b838752d..36153a75b2 100644
> > --- a/lib/graph/version.map
> > +++ b/lib/graph/version.map
> > @@ -43,5 +43,12 @@ EXPERIMENTAL {
> >         rte_node_next_stream_put;
> >         rte_node_next_stream_move;
> >
> > +       rte_pcap_trace_is_enable;
> > +       rte_pcap_trace_enable;
> > +       rte_graph_pcap_trace_init;
> > +       rte_num_pkt_to_capture;
> > +       rte_filename_to_capture_pkt;
> > +       rte_graph_pcap_trace_exit;
> 
> All of these public APIs are not needed. Since rte_graph is still experimental
> to make it clean, please add file name and number of packet to capture in
> struct rte_graph_param and update
> doc/guides/rel_notes/release_23_03.rst.
> 
> See following example in doc/guides/rel_notes/release_22_07.rst
> 
> API Changes
> -----------
> 
> * Experimental structures ``struct rte_mtr_params``
>   and ``struct rte_mtr_capabilities`` were updated to support
>   protocol based input color for meter.
> 
> > +
> >         local: *;
> >  };
> > --
> > 2.25.1
> >

  reply	other threads:[~2023-01-19 14:21 UTC|newest]

Thread overview: 47+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-23 12:02 [RFC PATCH] graph: add support for pcap trace for graph Amit Prakash Shukla
2022-12-23 16:47 ` Stephen Hemminger
2023-01-06 10:40   ` [EXT] " Amit Prakash Shukla
2023-01-06 16:41     ` Stephen Hemminger
2023-01-06 18:56     ` Stephen Hemminger
2023-01-10 11:26       ` Amit Prakash Shukla
2023-01-10 11:58 ` [PATCH v1 1/3] pcapng: comment option support for epb Amit Prakash Shukla
2023-01-10 11:58   ` [PATCH v1 2/3] graph: pcap capture for graph nodes Amit Prakash Shukla
2023-01-10 11:58   ` [PATCH v1 3/3] l3fwd-graph: changes to configure pcap capture Amit Prakash Shukla
2023-01-10 17:05   ` [PATCH v1 1/3] pcapng: comment option support for epb Stephen Hemminger
2023-01-11  8:53   ` [PATCH v2 " Amit Prakash Shukla
2023-01-11  8:53     ` [PATCH v2 2/3] graph: pcap capture for graph nodes Amit Prakash Shukla
2023-01-11 16:07       ` Stephen Hemminger
2023-01-12  9:57         ` [EXT] " Amit Prakash Shukla
2023-01-12 16:30           ` Stephen Hemminger
2023-01-19 14:37             ` Amit Prakash Shukla
2023-01-19 16:48               ` Stephen Hemminger
2023-01-11  8:53     ` [PATCH v2 3/3] l3fwd-graph: changes to configure pcap capture Amit Prakash Shukla
2023-01-12 10:01     ` [PATCH v3 1/3] pcapng: comment option support for epb Amit Prakash Shukla
2023-01-12 10:01       ` [PATCH v3 2/3] graph: pcap capture for graph nodes Amit Prakash Shukla
2023-01-12 12:18         ` Jerin Jacob
2023-01-19 14:21           ` Amit Prakash Shukla [this message]
2023-01-12 10:01       ` [PATCH v3 3/3] l3fwd-graph: changes to configure pcap capture Amit Prakash Shukla
2023-01-24 11:21       ` [PATCH v4 1/3] pcapng: comment option support for epb Amit Prakash Shukla
2023-01-24 11:21         ` [PATCH v4 2/3] graph: pcap capture for graph nodes Amit Prakash Shukla
2023-01-31  8:06           ` Jerin Jacob
2023-02-03  8:15             ` [EXT] " Amit Prakash Shukla
2023-01-24 11:21         ` [PATCH v4 3/3] l3fwd-graph: changes to configure pcap capture Amit Prakash Shukla
2023-01-31  8:14           ` Jerin Jacob
2023-02-03  8:16             ` [EXT] " Amit Prakash Shukla
2023-02-03  8:19         ` [PATCH v5 1/3] pcapng: comment option support for epb Amit Prakash Shukla
2023-02-03  8:19           ` [PATCH v5 2/3] graph: pcap capture for graph nodes Amit Prakash Shukla
2023-02-09  9:12             ` David Marchand
2023-02-09  9:29               ` [EXT] " Amit Prakash Shukla
2023-02-03  8:19           ` [PATCH v5 3/3] examples/l3fwd-graph: changes to configure pcap capture Amit Prakash Shukla
2023-02-09  9:13           ` [PATCH v5 1/3] pcapng: comment option support for epb David Marchand
2023-02-09 16:48             ` Stephen Hemminger
2023-02-09  9:56           ` [PATCH v6 1/4] " Amit Prakash Shukla
2023-02-09  9:56             ` [PATCH v6 2/4] graph: pcap capture for graph nodes Amit Prakash Shukla
2023-02-09  9:56             ` [PATCH v6 3/4] examples/l3fwd-graph: changes to configure pcap capture Amit Prakash Shukla
2023-02-09  9:56             ` [PATCH v6 4/4] test/graph: initialize graph param variable Amit Prakash Shukla
2023-02-09 10:03             ` [PATCH v6 1/4] pcapng: comment option support for epb Amit Prakash Shukla
2023-02-09 10:24             ` [PATCH v7 1/3] " Amit Prakash Shukla
2023-02-09 10:24               ` [PATCH v7 2/3] graph: pcap capture for graph nodes Amit Prakash Shukla
2023-02-09 10:24               ` [PATCH v7 3/3] examples/l3fwd-graph: changes to configure pcap capture Amit Prakash Shukla
2023-02-09 17:28                 ` Jerin Jacob
2023-02-10 12:18                   ` David Marchand

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=PH0PR18MB5167AB661DD7FA13D60C902BC8C49@PH0PR18MB5167.namprd18.prod.outlook.com \
    --to=amitprakashs@marvell.com \
    --cc=dev@dpdk.org \
    --cc=jerinj@marvell.com \
    --cc=jerinjacobk@gmail.com \
    --cc=kirankumark@marvell.com \
    --cc=ndabilpuram@marvell.com \
    /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).