From: Cong Wang <xiyou.wangc...@gmail.com> Date: Tue, 9 Jul 2019 23:24:54 -0700
> Switching from ->priv_destructor to dellink() has an unexpected > consequence: existing RCU readers, that is, hsr_port_get_hsr() > callers, may still be able to read the port list. > > Instead of checking the return value of each hsr_port_get_hsr(), > we can just move it to ->ndo_uninit() which is called after > device unregister and synchronize_net(), and we still have RTNL > lock there. > > Fixes: b9a1e627405d ("hsr: implement dellink to clean up resources") > Fixes: edf070a0fb45 ("hsr: fix a NULL pointer deref in hsr_dev_xmit()") > Reported-by: syzbot+097ef84cdc95843fb...@syzkaller.appspotmail.com > Cc: Arvid Brodin <arvid.bro...@alten.se> > Signed-off-by: Cong Wang <xiyou.wangc...@gmail.com> Applied and queued up for -stable, thanks.