From: David Ahern <dsahern@gmail.com>
To: Alexander Aring <aring@mojatatu.com>, jhs@mojatatu.com
Cc: xiyou.wangcong@gmail.com, jiri@resnulli.us, davem@davemloft.net,
netdev@vger.kernel.org, kernel@mojatatu.com,
David Ahern <dsahern@gmail.com>
Subject: Re: [PATCHv2 net-next 10/15] net: sch: api: add extack support in tcf_block_get
Date: Thu, 14 Dec 2017 13:08:09 -0700 [thread overview]
Message-ID: <d8983cae-a97f-2616-249b-e8bbfe4dcb7a@gmail.com> (raw)
In-Reply-To: <20171214183905.23066-11-aring@mojatatu.com>
On 12/14/17 11:39 AM, Alexander Aring wrote:
> diff --git a/net/sched/cls_api.c b/net/sched/cls_api.c
> index 446ef956a79c..173107ed3726 100644
> --- a/net/sched/cls_api.c
> +++ b/net/sched/cls_api.c
> @@ -282,20 +282,24 @@ static void tcf_block_offload_unbind(struct tcf_block *block, struct Qdisc *q,
> }
>
> int tcf_block_get_ext(struct tcf_block **p_block, struct Qdisc *q,
> - struct tcf_block_ext_info *ei)
> + struct tcf_block_ext_info *ei,
> + struct netlink_ext_ack *extack)
> {
> struct tcf_block *block = kzalloc(sizeof(*block), GFP_KERNEL);
> struct tcf_chain *chain;
> int err;
>
> - if (!block)
> + if (!block) {
> + NL_SET_ERR_MSG(extack, "No tcf block given");
Wrong message for the failure. !block means kzalloc failed.
> return -ENOMEM;
> + }
> INIT_LIST_HEAD(&block->chain_list);
> INIT_LIST_HEAD(&block->cb_list);
>
> /* Create chain 0 by default, it has to be always present. */
> chain = tcf_chain_create(block, 0);
> if (!chain) {
> + NL_SET_ERR_MSG(extack, "Failed to create new tcf chain");
> err = -ENOMEM;
> goto err_chain_create;
> }
next prev parent reply other threads:[~2017-12-14 20:08 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-14 18:38 [PATCHv2 net-next 00/15] net: sched: sch: introduce extack support Alexander Aring
2017-12-14 18:38 ` [PATCHv2 net-next 01/15] net: sched: fix coding style issues Alexander Aring
2017-12-14 18:38 ` [PATCHv2 net-next 02/15] lib: nlattr: set extack msg if validate_nla fails Alexander Aring
2017-12-14 19:45 ` David Ahern
2017-12-14 18:38 ` [PATCHv2 net-next 03/15] net: sched: sch_api: handle generic qdisc errors Alexander Aring
2017-12-14 18:52 ` Alexander Aring
2017-12-14 19:56 ` David Ahern
2017-12-14 18:38 ` [PATCHv2 net-next 04/15] net: sched: sch: add extack for init callback Alexander Aring
2017-12-16 19:08 ` kbuild test robot
2017-12-16 19:37 ` kbuild test robot
2017-12-16 19:55 ` kbuild test robot
2017-12-14 18:38 ` [PATCHv2 net-next 05/15] net: sched: sch: add extack for change qdisc ops Alexander Aring
2017-12-14 18:38 ` [PATCHv2 net-next 06/15] net: sched: sch: add extack to change class Alexander Aring
2017-12-14 18:38 ` [PATCHv2 net-next 07/15] net: sched: sch: add extack for block callback Alexander Aring
2017-12-14 18:38 ` [PATCHv2 net-next 08/15] net: sched: sch: add extack for graft callback Alexander Aring
2017-12-14 18:38 ` [PATCHv2 net-next 09/15] net: sch: api: add extack support in qdisc_get_rtab Alexander Aring
2017-12-14 20:02 ` David Ahern
2017-12-14 18:39 ` [PATCHv2 net-next 10/15] net: sch: api: add extack support in tcf_block_get Alexander Aring
2017-12-14 20:08 ` David Ahern [this message]
2017-12-16 18:27 ` kbuild test robot
2017-12-14 18:39 ` [PATCHv2 net-next 11/15] net: sch: api: add extack support in qdisc_alloc Alexander Aring
2017-12-14 18:39 ` [PATCHv2 net-next 12/15] net: sch: api: add extack support in qdisc_create_dflt Alexander Aring
2017-12-16 19:06 ` kbuild test robot
2017-12-14 18:39 ` [PATCHv2 net-next 13/15] net: sch: sch_cbq: add extack support Alexander Aring
2017-12-14 18:39 ` [PATCHv2 net-next 14/15] net: sch: sch_cbs: " Alexander Aring
2017-12-14 20:11 ` David Ahern
2017-12-14 18:39 ` [PATCHv2 net-next 15/15] net: sch: sch_drr: " Alexander Aring
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=d8983cae-a97f-2616-249b-e8bbfe4dcb7a@gmail.com \
--to=dsahern@gmail.com \
--cc=aring@mojatatu.com \
--cc=davem@davemloft.net \
--cc=jhs@mojatatu.com \
--cc=jiri@resnulli.us \
--cc=kernel@mojatatu.com \
--cc=netdev@vger.kernel.org \
--cc=xiyou.wangcong@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).