lkml.org 
[lkml]   [2022]   [Jul]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2,net-next] net/sched: remove return value of unregister_tcf_proto_ops
On Mon, 11 Jul 2022 16:09:10 +0800 Zhengchao Shao wrote:
> Return value of unregister_tcf_proto_ops is unused, remove it.

> -int unregister_tcf_proto_ops(struct tcf_proto_ops *ops)
> +void unregister_tcf_proto_ops(struct tcf_proto_ops *ops)
> {
> struct tcf_proto_ops *t;
> int rc = -ENOENT;
> @@ -214,7 +214,10 @@ int unregister_tcf_proto_ops(struct tcf_proto_ops *ops)
> }
> }
> write_unlock(&cls_mod_lock);
> - return rc;
> +

> + if (rc)
> + pr_warn("unregister tc filter kind(%s) failed\n", ops->kind);

I was saying WARN, by which I meant:

WARN(rc, "unregister tc filter kind(%s) failed %d\n", ops->kind, rc);

\
 
 \ /
  Last update: 2022-07-13 03:09    [W:0.085 / U:0.420 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site