[ovs-dev] [PATCH] dpif-netdev: Mention SMC in 2 pmd_thread comments
Kevin Traynor
ktraynor at redhat.com
Thu Sep 9 13:39:15 UTC 2021
pmd_thread seems like it is referencing a struct so better to just use a
natural description (also, style is usually to have summary in sentence
case including ".")
How about:
dpif-netdev: Fix pmd thread comments to include SMC.
On 27/08/2021 16:52, Cian Ferriter wrote:
> These comments are relevant to SMC too.
>
Fixes: 60d8ccae135f ("dpif-netdev: Add SMC cache after EMC cache")
(though it's not worth backporting they have moved files)
Very minor comments, so i'll add ack:
Acked-by: Kevin Traynor <ktraynor at redhat.com>
> Signed-off-by: Cian Ferriter <cian.ferriter at intel.com>
> ---
> lib/dpif-netdev-private-dfc.h | 3 ++-
> lib/dpif-netdev-private-thread.h | 8 ++++----
> 2 files changed, 6 insertions(+), 5 deletions(-)
>
> diff --git a/lib/dpif-netdev-private-dfc.h b/lib/dpif-netdev-private-dfc.h
> index 92092ebec..3dfc91f0f 100644
> --- a/lib/dpif-netdev-private-dfc.h
> +++ b/lib/dpif-netdev-private-dfc.h
> @@ -59,7 +59,8 @@ extern "C" {
> * Thread-safety
> * =============
> *
> - * Each pmd_thread has its own private exact match cache.
> + * Each pmd_thread has its own private exact match cache and signature match
> + * cache.
> * If dp_netdev_input is not called from a pmd thread, a mutex is used.
> */
>
> diff --git a/lib/dpif-netdev-private-thread.h b/lib/dpif-netdev-private-thread.h
> index a782d9678..ac4885538 100644
> --- a/lib/dpif-netdev-private-thread.h
> +++ b/lib/dpif-netdev-private-thread.h
> @@ -78,10 +78,10 @@ struct dp_netdev_pmd_thread {
> struct ovs_refcount ref_cnt; /* Every reference must be refcount'ed. */
> struct cmap_node node; /* In 'dp->poll_threads'. */
>
> - /* Per thread exact-match cache. Note, the instance for cpu core
> - * NON_PMD_CORE_ID can be accessed by multiple threads, and thusly
> - * need to be protected by 'non_pmd_mutex'. Every other instance
> - * will only be accessed by its own pmd thread. */
> + /* Per thread exact match cache and signature match cache. Note, the
> + * instance for cpu core NON_PMD_CORE_ID can be accessed by multiple
> + * threads, and thusly need to be protected by 'non_pmd_mutex'. Every
> + * other instance will only be accessed by its own pmd thread. */
> OVS_ALIGNED_VAR(CACHE_LINE_SIZE) struct dfc_cache flow_cache;
>
> /* Flow-Table and classifiers
>
More information about the dev
mailing list