From: Jerin Jacob <jerinjacobk@gmail.com>
To: Matan Azrad <matan@mellanox.com>
Cc: "jerinj@marvell.com" <jerinj@marvell.com>,
"dev@dpdk.org" <dev@dpdk.org>,
Thomas Monjalon <thomas@monjalon.net>,
"david.marchand@6wind.com" <david.marchand@6wind.com>
Subject: Re: [dpdk-dev] [PATCH v2 1/3] eal: introduce structure marker typedefs
Date: Thu, 2 Jan 2020 11:57:06 +0530 [thread overview]
Message-ID: <CALBAE1PHytdjPOv8MPaP_d+0djBB0Up4U+xv2QETOH6UuGhgSQ@mail.gmail.com> (raw)
In-Reply-To: <AM0PR0502MB4019AE0608D89C011E759111D22B0@AM0PR0502MB4019.eurprd05.prod.outlook.com>
On Thu, Dec 26, 2019 at 1:45 PM Matan Azrad <matan@mellanox.com> wrote:
>
> Hi
>
> From: Jerin Jacob
> > From: Jerin Jacob <jerinj@marvell.com>
> >
> > Introduce EAL typedef for structure 1B, 2B, 4B, 8B alignment marking and a
> > generic marker for a point in a structure.
> >
> > Signed-off-by: Jerin Jacob <jerinj@marvell.com>
> > ---
> >
> > v2:
> > - Changed __extension__ to RTE_STD_C11 (Thomas)
> > - Change "a point" to "any place" of RTE_MARKER comment(Thomas)
> >
> > lib/librte_eal/common/include/rte_common.h | 12 ++++++++++++
> > 1 file changed, 12 insertions(+)
> >
> > diff --git a/lib/librte_eal/common/include/rte_common.h
> > b/lib/librte_eal/common/include/rte_common.h
> > index 459d082d1..00c8b8434 100644
> > --- a/lib/librte_eal/common/include/rte_common.h
> > +++ b/lib/librte_eal/common/include/rte_common.h
> > @@ -335,6 +335,18 @@ typedef uint64_t phys_addr_t; typedef uint64_t
> > rte_iova_t; #define RTE_BAD_IOVA ((rte_iova_t)-1)
> >
> > +/*********** Structure alignment markers ********/
> > +
> > +/** Generic marker for any place in a structure. */
> > +RTE_STD_C11 typedef void *RTE_MARKER[0];
> > +/** Marker for 1B alignment in a structure. */
> > +RTE_STD_C11 typedef uint8_t RTE_MARKER8[0];
> > +/** Marker for 2B alignment in a structure. */
> > +RTE_STD_C11 typedef uint16_t RTE_MARKER16[0];
> > +/** Marker for 4B alignment in a structure. */
> > +RTE_STD_C11 typedef uint16_t RTE_MARKER32[0];
> > +/** Marker for 8B alignment in a structure. */
> > +RTE_STD_C11 typedef uint64_t RTE_MARKER64[0];
>
> I saw there are similar definitions in mbuf library.
> What do you think about moving all libraries to use the same define from EAL?
It is already done in 2/3 and 3/3 patches in the series.
>
> > /**
> > * Combines 32b inputs most significant set bits into the least
> > --
> > 2.24.1
>
next prev parent reply other threads:[~2020-01-02 6:27 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-08 11:34 [dpdk-dev] [PATCH " jerinj
2019-12-08 11:34 ` [dpdk-dev] [PATCH 2/3] drivers: use structure marker typedef in eal jerinj
2019-12-08 11:34 ` [dpdk-dev] [PATCH 3/3] mbuf: " jerinj
2019-12-10 22:46 ` [dpdk-dev] [PATCH 1/3] eal: introduce structure marker typedefs Thomas Monjalon
2019-12-19 10:34 ` Jerin Jacob
2019-12-19 11:25 ` [dpdk-dev] [PATCH v2 " jerinj
2019-12-19 11:25 ` [dpdk-dev] [PATCH v2 2/3] drivers: use structure marker typedef in eal jerinj
2019-12-19 11:25 ` [dpdk-dev] [PATCH v2 3/3] mbuf: " jerinj
2019-12-26 16:24 ` Olivier Matz
2020-01-20 21:55 ` Thomas Monjalon
2019-12-20 4:21 ` [dpdk-dev] [PATCH v2 1/3] eal: introduce structure marker typedefs Gavin Hu
2019-12-26 8:15 ` Matan Azrad
2020-01-02 6:27 ` Jerin Jacob [this message]
2020-01-02 9:48 ` Matan Azrad
2020-01-16 13:09 ` Jerin Jacob
2020-01-20 20:11 ` Thomas Monjalon
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=CALBAE1PHytdjPOv8MPaP_d+0djBB0Up4U+xv2QETOH6UuGhgSQ@mail.gmail.com \
--to=jerinjacobk@gmail.com \
--cc=david.marchand@6wind.com \
--cc=dev@dpdk.org \
--cc=jerinj@marvell.com \
--cc=matan@mellanox.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).