lkml.org 
[lkml]   [2026]   [May]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH net-next v3 2/2] net: openvswitch: decouple flow_table from ovs_mutex
On Thu, 7 May 2026 13:31:24 +0200
Paolo Abeni <pabeni@redhat.com> wrote:

> On 5/5/26 10:42 AM, Adrian Moreno wrote:
..
> > +/* Must be called with flow_table->lock held. */
> > int ovs_flow_tbl_flush(struct flow_table *flow_table)
> > {
> > struct table_instance *old_ti, *new_ti;
> > struct table_instance *old_ufid_ti, *new_ufid_ti;
> >
> > + ASSERT_OVS_TBL(flow_table);
>
> Minor nit: adding the assert and the comment is redundant. I think the
> assert alone would be better. There are other similar later occurrences.

There is no point adding an ASSERT() for a pointer being NULL.
The NULL pointer dereference does the same job and can be easier to
debug because all the registers are still live.

-- David

>
> /P
>
>


\
 
 \ /
  Last update: 2026-05-07 16:43    [W:0.111 / U:28.402 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and my Meterkast|Read the blog