From: Ferruh Yigit <ferruh.yigit@intel.com>
To: Weiguo Li <liwg06@foxmail.com>
Cc: <dev@dpdk.org>
Subject: Re: [PATCH v3 1/4] kni: add define guards to avoid multi-inclusion
Date: Wed, 9 Feb 2022 13:52:37 +0000 [thread overview]
Message-ID: <552086d6-dfa9-de92-8e97-92543ac0e722@intel.com> (raw)
In-Reply-To: <tencent_73F6A73E11363A87DFB62372225531733C08@qq.com>
On 2/9/2022 7:24 AM, Weiguo Li wrote:
> Supplement define guards to prevent multiple inclusion.
>
It is kind of private header and only 'rte_kni.c' includes it,
that is why missing guards doesn't cause trouble but no harm/objection
to have them.
> Signed-off-by: Weiguo Li <liwg06@foxmail.com>
Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
> ---
> lib/kni/rte_kni_fifo.h | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/lib/kni/rte_kni_fifo.h b/lib/kni/rte_kni_fifo.h
> index d2ec82fe87..2ff71554c0 100644
> --- a/lib/kni/rte_kni_fifo.h
> +++ b/lib/kni/rte_kni_fifo.h
> @@ -2,7 +2,8 @@
> * Copyright(c) 2010-2014 Intel Corporation
> */
>
> -
> +#ifndef RTE_KNI_FIFO_H
> +#define RTE_KNI_FIFO_H
It doesn't really differ much but other kni header guards wrapped with '_',
I don't now why.
If there will be a new version can you please apply the same here to have
consistency, like:
#ifndef _RTE_KNI_FIFO_H_
>
> /**
> * @internal when c11 memory model enabled use c11 atomic memory barrier.
> @@ -115,3 +116,5 @@ kni_fifo_free_count(struct rte_kni_fifo *fifo)
> uint32_t fifo_read = __KNI_LOAD_ACQUIRE(&fifo->read);
> return (fifo_read - fifo_write - 1) & (fifo->len - 1);
> }
> +
> +#endif /* RTE_KNI_FIFO_H */
next prev parent reply other threads:[~2022-02-09 13:52 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <cover.1644390801.git.liwg06@foxmail.com>
2022-02-09 7:24 ` Weiguo Li
2022-02-09 13:52 ` Ferruh Yigit [this message]
2022-02-22 14:48 ` Thomas Monjalon
2022-02-09 7:24 ` [PATCH v3 2/4] eal: " Weiguo Li
2024-10-03 23:58 ` Stephen Hemminger
2022-02-09 7:24 ` [PATCH v3 3/4] efd: " Weiguo Li
2024-10-03 23:59 ` Stephen Hemminger
2022-02-09 7:24 ` [PATCH v3 4/4] hash: " Weiguo Li
2024-10-03 23:57 ` Stephen Hemminger
2024-10-15 22:56 ` Stephen Hemminger
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=552086d6-dfa9-de92-8e97-92543ac0e722@intel.com \
--to=ferruh.yigit@intel.com \
--cc=dev@dpdk.org \
--cc=liwg06@foxmail.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).