From: Bjørn Mork <bj...@mork.no> Date: Mon, 7 Mar 2016 21:15:36 +0100
> usbnet_link_change will call schedule_work and should be > avoided if bind is failing. Otherwise we will end up with > scheduled work referring to a netdev which has gone away. > > Instead of making the call conditional, we can just defer > it to usbnet_probe, using the driver_info flag made for > this purpose. > > Fixes: 8a34b0ae8778 ("usbnet: cdc_ncm: apply usbnet_link_change") > Reported-by: Andrey Konovalov <andreyk...@gmail.com> > Suggested-by: Linus Torvalds <torva...@linux-foundation.org> > Signed-off-by: Bjørn Mork <bj...@mork.no> ... > Even with Oliver's generic fix we should still fix the inconsistency > in cdc_ncm, as pointed out by Linus. > > This is a slightly different approach than the patch proposed by Linus. > When I started looking at this I couldn't figure out why we were doing > this differently in this driver from all the other usbnet drivers > disabling the link at probe time. So let's make it consistent. Then at > least we get consistent bugs :) Fair enough, applied and queued up for -stable. Thanks.