netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Du Cheng <ducheng2@gmail.com>
To: Cong Wang <xiyou.wangcong@gmail.com>
Cc: Jamal Hadi Salim <jhs@mojatatu.com>,
	Jiri Pirko <jiri@resnulli.us>,
	Linux Kernel Network Developers <netdev@vger.kernel.org>,
	Shuah Khan <skhan@linuxfoundation.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Eric Dumazet <eric.dumazet@gmail.com>,
	syzbot+d50710fd0873a9c6b40c@syzkaller.appspotmail.com
Subject: Re: [PATCH v3] net: sched: tapr: prevent cycle_time == 0 in parse_taprio_schedule
Date: Sat, 17 Apr 2021 07:31:45 +0800	[thread overview]
Message-ID: <YHoeYVPhsgLZ6gA1@nuc> (raw)
In-Reply-To: <CAM_iQpWs3Z55=y0-=PJT6xZMv+Hw9JGPLFXmbr+35+70DAYsOQ@mail.gmail.com>

Le Fri, Apr 16, 2021 at 10:14:52AM -0700, Cong Wang a écrit :
> On Thu, Apr 15, 2021 at 4:17 PM Du Cheng <ducheng2@gmail.com> wrote:
> > diff --git a/net/sched/sch_taprio.c b/net/sched/sch_taprio.c
> > index 8287894541e3..abd6b176383c 100644
> > --- a/net/sched/sch_taprio.c
> > +++ b/net/sched/sch_taprio.c
> > @@ -901,6 +901,10 @@ static int parse_taprio_schedule(struct taprio_sched *q, struct nlattr **tb,
> >
> >                 list_for_each_entry(entry, &new->entries, list)
> >                         cycle = ktime_add_ns(cycle, entry->interval);
> > +
> > +               if (!cycle)
> > +                       return -EINVAL;
> 
> Just a nit: please add an extack to explain why we return EINVAL here.
> 
> Thanks.

Hi Cong,

Thanks!

I added extack and submitted v4. Please help me review.

Regards,
Du Cheng

      reply	other threads:[~2021-04-16 23:31 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-15 23:17 [PATCH v3] net: sched: tapr: prevent cycle_time == 0 in parse_taprio_schedule Du Cheng
2021-04-16 17:14 ` Cong Wang
2021-04-16 23:31   ` Du Cheng [this message]

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=YHoeYVPhsgLZ6gA1@nuc \
    --to=ducheng2@gmail.com \
    --cc=eric.dumazet@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=jhs@mojatatu.com \
    --cc=jiri@resnulli.us \
    --cc=netdev@vger.kernel.org \
    --cc=skhan@linuxfoundation.org \
    --cc=syzbot+d50710fd0873a9c6b40c@syzkaller.appspotmail.com \
    --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).