* [PATCH iproute2] bridge: Assume master at FDB modification
@ 2017-07-26 15:36 Arkadi Sharshevsky
2017-07-26 16:08 ` Stephen Hemminger
0 siblings, 1 reply; 3+ messages in thread
From: Arkadi Sharshevsky @ 2017-07-26 15:36 UTC (permalink / raw)
To: netdev; +Cc: davem, stephen, nikolay, vivien.didelot, mlxsw, Arkadi Sharshevsky
According to the man page the master flag should be the default, yet, the
current code assumes otherwise.
Signed-off-by: Arkadi Sharshevsky <arkadis@mellanox.com>
---
bridge/fdb.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/bridge/fdb.c b/bridge/fdb.c
index e5cebf9..7c77157 100644
--- a/bridge/fdb.c
+++ b/bridge/fdb.c
@@ -496,9 +496,9 @@ static int fdb_modify(int cmd, int flags, int argc, char **argv)
return -1;
}
- /* Assume self */
+ /* Assume master */
if (!(req.ndm.ndm_flags&(NTF_SELF|NTF_MASTER)))
- req.ndm.ndm_flags |= NTF_SELF;
+ req.ndm.ndm_flags |= NTF_MASTER;
/* Assume permanent */
if (!(req.ndm.ndm_state&(NUD_PERMANENT|NUD_REACHABLE)))
--
2.4.11
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH iproute2] bridge: Assume master at FDB modification
2017-07-26 15:36 [PATCH iproute2] bridge: Assume master at FDB modification Arkadi Sharshevsky
@ 2017-07-26 16:08 ` Stephen Hemminger
2017-07-26 16:21 ` Arkadi Sharshevsky
0 siblings, 1 reply; 3+ messages in thread
From: Stephen Hemminger @ 2017-07-26 16:08 UTC (permalink / raw)
To: Arkadi Sharshevsky; +Cc: netdev, davem, nikolay, vivien.didelot, mlxsw
On Wed, 26 Jul 2017 18:36:34 +0300
Arkadi Sharshevsky <arkadis@mellanox.com> wrote:
> According to the man page the master flag should be the default, yet, the
> current code assumes otherwise.
>
> Signed-off-by: Arkadi Sharshevsky <arkadis@mellanox.com>
Agree that the documentation and code don't match.
But your change could break users with existing scripts by changing behavior.
It would be safer to change the man page not the code.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH iproute2] bridge: Assume master at FDB modification
2017-07-26 16:08 ` Stephen Hemminger
@ 2017-07-26 16:21 ` Arkadi Sharshevsky
0 siblings, 0 replies; 3+ messages in thread
From: Arkadi Sharshevsky @ 2017-07-26 16:21 UTC (permalink / raw)
To: Stephen Hemminger; +Cc: netdev, davem, nikolay, vivien.didelot, mlxsw
On 07/26/2017 07:08 PM, Stephen Hemminger wrote:
> On Wed, 26 Jul 2017 18:36:34 +0300
> Arkadi Sharshevsky <arkadis@mellanox.com> wrote:
>
>> According to the man page the master flag should be the default, yet, the
>> current code assumes otherwise.
>>
>> Signed-off-by: Arkadi Sharshevsky <arkadis@mellanox.com>
>
> Agree that the documentation and code don't match.
> But your change could break users with existing scripts by changing behavior.
>
> It would be safer to change the man page not the code.
>
Can we maybe set master and self by default. It doesn't make
sense by default to not include the bridge, it will not cause
regression in this case.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-07-26 16:21 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-26 15:36 [PATCH iproute2] bridge: Assume master at FDB modification Arkadi Sharshevsky
2017-07-26 16:08 ` Stephen Hemminger
2017-07-26 16:21 ` Arkadi Sharshevsky
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.