From: Jiri Pirko <jiri@resnulli.us>
To: Cong Wang <xiyou.wangcong@gmail.com>
Cc: Linux Kernel Network Developers <netdev@vger.kernel.org>,
Jiri Pirko <jiri@mellanox.com>,
Jamal Hadi Salim <jhs@mojatatu.com>
Subject: Re: [Patch net-next] act_mirred: use tcfm_dev in tcf_mirred_get_dev()
Date: Sun, 3 Dec 2017 07:39:04 +0100 [thread overview]
Message-ID: <20171203063903.GA1903@nanopsycho> (raw)
In-Reply-To: <CAM_iQpUz6WYod0Q1E=XhX7yXxz0ieyrGT1hSBuEdq7MfUEXRPg@mail.gmail.com>
Sat, Dec 02, 2017 at 08:53:20PM CET, xiyou.wangcong@gmail.com wrote:
>On Sat, Dec 2, 2017 at 11:47 AM, Cong Wang <xiyou.wangcong@gmail.com> wrote:
>> On Sat, Dec 2, 2017 at 12:57 AM, Jiri Pirko <jiri@resnulli.us> wrote:
>>> Good. Please also use m->tcfm_dev->ifindex in tcf_mirred_dump and
>>> tcf_mirred_ifindex. Then you can remove tcfm_ifindex completely.
>>
>> Sounds good. Will send v2.
>
>Hold on, m->tcfm_dev could be NULL, so we can't just def it here.
>
>I think we can just use 0 when it is NULL:
>
>.ifindex = m->tcfm_dev ? m->tcfm_dev->ifindex : 0,
>
>This also "fixes" the garbage ifindex dump when the target device is gone.
Sounds fine.
prev parent reply other threads:[~2017-12-03 6:39 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-30 22:53 [Patch net-next] act_mirred: use tcfm_dev in tcf_mirred_get_dev() Cong Wang
2017-11-30 22:53 ` [Patch net-next] act_mirred: get rid of mirred_list_lock spinlock Cong Wang
2017-11-30 23:12 ` Eric Dumazet
2017-12-01 1:02 ` Cong Wang
2017-12-01 17:56 ` [Patch net-next] act_mirred: use tcfm_dev in tcf_mirred_get_dev() Jiri Pirko
2017-12-01 21:46 ` Cong Wang
2017-12-02 6:56 ` Jiri Pirko
2017-12-02 8:57 ` Jiri Pirko
2017-12-02 19:47 ` Cong Wang
2017-12-02 19:53 ` Cong Wang
2017-12-03 6:39 ` Jiri Pirko [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=20171203063903.GA1903@nanopsycho \
--to=jiri@resnulli.us \
--cc=jhs@mojatatu.com \
--cc=jiri@mellanox.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.