Re: [syzbot ci] Re: net: move netdev_compute_master_upper_features to ndo_set_features
From: Sabrina Dubroca <sd@queasysnail.net>
Date: 2026-03-12 17:07:57
Also in:
bridge, lkml, syzbot
2026-03-12, 17:47:45 +0100, Paolo Abeni wrote:
On 3/12/26 4:58 PM, Sabrina Dubroca wrote:quoted
2026-03-12, 14:34:44 +0000, Hangbin Liu wrote:quoted
On Thu, Mar 12, 2026 at 12:13:52PM +0100, Sabrina Dubroca wrote:quoted
Proper fix (so that the notification we're sending during upper_dev_link has full linkinfo) would be to move netdev_upper_dev_link() to after macsec_changelink_common() and fix up the error handling. I don't see anything in macsec_add_dev or macsec_changelink_common that needs the device to be linked. ButIf we move the netdev_upper_dev_link() after macsec_changelink_common(), we will not goto nla_put_failure via default, right?Yes.quoted
quoted
anyway it doesn't make sense for macsec_fill_info to return -EMSGSIZE on invalid data, so the "bandaid" should be included as well. Should this be part of this series (either just the "bandaid" or the "proper fix"+bandaid), since we never saw a problem before?Since macsec need the "bandaid" fix either way. How about you post the "bandaid" fix to net. And I include the "proper fix" in this series for net-next?But I don't think it's needed in net. Am I missing a codepath (before your series) where macsec_fill_info could be called for the new device before macsec_newlink returns? If not, it doesn't really qualify as a fix, that's why I was asking Paolo.FWIW, I don't see a codepath calling into rtmsg_ifinfo_build_skb() before device initialization, so I would be fine targeting net-next with the EMSGSIZE-related change. Side note, it looks like that the WARN() in the rnnetlink code here helped identifying a real problem and correctly returning 0 when the key_len is not yet initialized will silence it forever, what about preserving a warning for this kind of race? something alike:
Right, I was thinking about putting a DEBUG_NET_WARN_ON_ONCE there. -- Sabrina