[PATCH v2 1/2] fib: implement RCU rule reclamation

Doug Foster Doug.Foster at arm.com
Wed Oct 9 21:12:03 CEST 2024


The check for NULL is not necessary before calling rte_rcu_qsbr_dq_delete. Similar to other free routines, an error will not occur when the dq pointer is NULL.
However, it will give a debug log statement to indicate an invalid parameter and return 0 to indicate success.

-----Original Message-----
From: Stephen Hemminger <stephen at networkplumber.org>
Sent: Tuesday, October 8, 2024 1:18 PM
To: Vladimir Medvedkin <vladimir.medvedkin at intel.com>
Cc: dev at dpdk.org; rjarry at redhat.com; Ruifeng Wang <Ruifeng.Wang at arm.com>; Honnappa Nagarahalli <Honnappa.Nagarahalli at arm.com>; david.marchand at redhat.com
Subject: Re: [PATCH v2 1/2] fib: implement RCU rule reclamation

On Tue,  8 Oct 2024 17:55:23 +0000
Vladimir Medvedkin <vladimir.medvedkin at intel.com> wrote:

> @@ -569,7 +600,60 @@ dir24_8_free(void *p)  {
>       struct dir24_8_tbl *dp = (struct dir24_8_tbl *)p;
>
> +     if (dp->dq != NULL)
> +             rte_rcu_qsbr_dq_delete(dp->dq);
> +

Side note:
rte_rcu_qsbr_dq_delete should be changed to accept NULL as nop.
Like all the other free routines
IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.


More information about the dev mailing list