Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1644670

Re: [PATCH net-next 3/6] net: bridge: break if __br_mdb_del fails

From Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Newsgroups linux.kernel
Subject Re: [PATCH net-next 3/6] net: bridge: break if __br_mdb_del fails
Date 2017-05-18 17:20 +0200
Message-ID <tIvnz-4vr-11@gated-at.bofh.it> (permalink)
References <tIePL-8wt-5@gated-at.bofh.it> <tIePL-8wt-9@gated-at.bofh.it> <tItYu-3le-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hi Nikolay,

Nikolay Aleksandrov <nikolay@cumulusnetworks.com> writes:

>>   			err = __br_mdb_del(br, entry);
>> -			if (!err)
>> -				__br_mdb_notify(dev, p, entry, RTM_DELMDB);
>> +			if (err)
>> +				break;
>> +			__br_mdb_notify(dev, p, entry, RTM_DELMDB);
>>   		}
>>   	} else {
>>   		err = __br_mdb_del(br, entry);
>> 
>
> This can potentially break user-space scripts that rely on the best-effort
> behaviour, this is the normal "delete without vid & enabled vlan filtering".
> You can check the fdb delete code which does the same, this was intentional.
>
> You can add an mdb entry without a vid to all vlans, add a vlan and then try
> to remove it from all vlans where it is present - with this patch obviously
> that will fail at the new vlan.

OK good to know. That intention wasn't obvious. I can make __br_mdb_del
return void instead? What about the rest of the patchset if I do so?

Thanks,

        Vivien

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH net-next 3/6] net: bridge: break if __br_mdb_del fails Vivien Didelot <vivien.didelot@savoirfairelinux.com> - 2017-05-17 23:40 +0200
  Re: [PATCH net-next 3/6] net: bridge: break if __br_mdb_del fails Nikolay Aleksandrov <nikolay@cumulusnetworks.com> - 2017-05-18 15:50 +0200
    Re: [PATCH net-next 3/6] net: bridge: break if __br_mdb_del    fails Vivien Didelot <vivien.didelot@savoirfairelinux.com> - 2017-05-18 17:20 +0200
      Re: [PATCH net-next 3/6] net: bridge: break if __br_mdb_del fails Nikolay Aleksandrov <nikolay@cumulusnetworks.com> - 2017-05-18 17:30 +0200
        Re: [PATCH net-next 3/6] net: bridge: break if __br_mdb_del    fails Vivien Didelot <vivien.didelot@savoirfairelinux.com> - 2017-05-18 17:50 +0200

csiph-web