Re: [PATCH 2/7] mark root hnode explicitly

2018-09-06 Thread Cong Wang
On Thu, Sep 6, 2018 at 8:50 PM Al Viro wrote: > > On Thu, Sep 06, 2018 at 08:23:36PM -0700, Cong Wang wrote: > > > Pretty sure there is a 'tp' in u32_set_parms() parameter list. > > > > Are you saying it is not what you want? If so, why? > > > > More importantly, why this information is again

Re: [PATCH 2/7] mark root hnode explicitly

2018-09-06 Thread Al Viro
On Thu, Sep 06, 2018 at 08:23:36PM -0700, Cong Wang wrote: > Pretty sure there is a 'tp' in u32_set_parms() parameter list. > > Are you saying it is not what you want? If so, why? > > More importantly, why this information is again missing in your > changelog? This patch is definitely not

Re: [PATCH 2/7] mark root hnode explicitly

2018-09-06 Thread Cong Wang
On Thu, Sep 6, 2018 at 8:04 PM Al Viro wrote: > > On Thu, Sep 06, 2018 at 07:57:25PM -0700, Cong Wang wrote: > > > > - if (root_ht == ht) { > > > + if (ht->is_root) { > > > > > > What's wrong with comparing pointers with root ht? > > The fact that there may be more than one tcf_proto

Re: [PATCH 2/7] mark root hnode explicitly

2018-09-06 Thread Al Viro
On Thu, Sep 06, 2018 at 07:57:25PM -0700, Cong Wang wrote: > > - if (root_ht == ht) { > > + if (ht->is_root) { > > > What's wrong with comparing pointers with root ht? The fact that there may be more than one tcf_proto sharing tp->data. > >

Re: [PATCH 2/7] mark root hnode explicitly

2018-09-06 Thread Cong Wang
On Thu, Sep 6, 2018 at 3:59 AM Al Viro wrote: > > diff --git a/net/sched/cls_u32.c b/net/sched/cls_u32.c > index 3f985f29ef30..d14048e38b5c 100644 > --- a/net/sched/cls_u32.c > +++ b/net/sched/cls_u32.c > @@ -84,6 +84,7 @@ struct tc_u_hnode { > int refcnt; >

Re: [PATCH 2/7] mark root hnode explicitly

2018-09-06 Thread Jamal Hadi Salim
On 2018-09-06 6:59 a.m., Al Viro wrote: On Thu, Sep 06, 2018 at 06:34:00AM -0400, Jamal Hadi Salim wrote: On 2018-09-06 6:28 a.m., Jamal Hadi Salim wrote: [..] Point, and that one is IMO enough to give up on using ->flags for that. How about simply diff --git a/net/sched/cls_u32.c

Re: [PATCH 2/7] mark root hnode explicitly

2018-09-06 Thread Al Viro
On Thu, Sep 06, 2018 at 06:34:00AM -0400, Jamal Hadi Salim wrote: > On 2018-09-06 6:28 a.m., Jamal Hadi Salim wrote: > > On 2018-09-05 3:04 p.m., Al Viro wrote: > > > From: Al Viro > > > > > > ... and disallow deleting or linking to such > > > > > > Signed-off-by: Al Viro > > > > Same comment

Re: [PATCH 2/7] mark root hnode explicitly

2018-09-06 Thread Jamal Hadi Salim
And a bunch of indentations... cheers, jamal diff --git a/net/sched/cls_u32.c b/net/sched/cls_u32.c index 6d45ec4c218c..cb3bee12af78 100644 --- a/net/sched/cls_u32.c +++ b/net/sched/cls_u32.c @@ -485,7 +485,8 @@ static void u32_clear_hw_hnode(struct tcf_proto *tp, struct tc_u_hnode *h, struct

Re: [PATCH 2/7] mark root hnode explicitly

2018-09-06 Thread Jamal Hadi Salim
On 2018-09-06 6:28 a.m., Jamal Hadi Salim wrote: On 2018-09-05 3:04 p.m., Al Viro wrote: From: Al Viro ... and disallow deleting or linking to such Signed-off-by: Al Viro Same comment as other one in regards to subject Since the flag space is coming from htnode which is exposed via uapi

Re: [PATCH 2/7] mark root hnode explicitly

2018-09-06 Thread Jamal Hadi Salim
On 2018-09-05 3:04 p.m., Al Viro wrote: From: Al Viro ... and disallow deleting or linking to such Signed-off-by: Al Viro Same comment as other one in regards to subject Since the flag space is coming from htnode which is exposed via uapi it makes sense to keep this one here because it is

[PATCH 2/7] mark root hnode explicitly

2018-09-05 Thread Al Viro
From: Al Viro ... and disallow deleting or linking to such Signed-off-by: Al Viro --- net/sched/cls_u32.c | 14 +++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/net/sched/cls_u32.c b/net/sched/cls_u32.c index 3f985f29ef30..9ea5f2be907b 100644 ---