From: Cong Wang <xiyou.wangcong@gmail.com>
To: Roman Mashak <mrv@mojatatu.com>
Cc: Jiri Pirko <jiri@resnulli.us>,
Linux Kernel Network Developers <netdev@vger.kernel.org>,
Jiri Pirko <jiri@mellanox.com>,
Jamal Hadi Salim <jhs@mojatatu.com>
Subject: Re: broken behaviour of TC filter delete
Date: Fri, 24 Aug 2018 11:11:07 -0700 [thread overview]
Message-ID: <CAM_iQpXDG4YdiUrqFhn7fxsbTBMBdR4x-ZQQ3U5E_xSPf-PANQ@mail.gmail.com> (raw)
In-Reply-To: <85sh33zqkh.fsf@mojatatu.com>
On Fri, Aug 24, 2018 at 9:21 AM Roman Mashak <mrv@mojatatu.com> wrote:
>
> So _before_ commit f71e0ca4db187af7c44987e9d21e9042c3046070 step 6 would
> return -ENOENT with "Error: Filter with specified priority/protocol not
> found." and _after_ the commit it returns -EINVAL (Error: Cannot find
> specified filter chain.)
>
> ENOENT seems to be more logical to return when there's no more filter to delete.
Yeah, at least we should keep ENOENT for compatibility.
The bug here is chain 0 is gone after the last filter is gone,
so when you delete the filter again, it treats it as you specify
chain 0 which does not exist, so it hits EINVAL before ENOENT.
I am not sure how to fix this properly.
next prev parent reply other threads:[~2018-08-24 21:47 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-23 21:39 broken behaviour of TC filter delete Roman Mashak
2018-08-24 8:17 ` Jiri Pirko
2018-08-24 16:18 ` Roman Mashak
2018-08-24 18:11 ` Cong Wang [this message]
2018-08-25 13:02 ` Jiri Pirko
2018-08-26 17:48 ` Jamal Hadi Salim
2018-08-27 18:30 ` Cong Wang
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=CAM_iQpXDG4YdiUrqFhn7fxsbTBMBdR4x-ZQQ3U5E_xSPf-PANQ@mail.gmail.com \
--to=xiyou.wangcong@gmail.com \
--cc=jhs@mojatatu.com \
--cc=jiri@mellanox.com \
--cc=jiri@resnulli.us \
--cc=mrv@mojatatu.com \
--cc=netdev@vger.kernel.org \
/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).