Re: [PATCH RESEND] ipconfig : Fix null reference to the freed dev_addr

From: David Miller
Date: Sun Jun 26 2016 - 15:44:58 EST


From: Chanho Min <chanho.min@xxxxxxx>
Date: Wed, 22 Jun 2016 19:08:13 +0900

> To fix this, I suggested patch that checks if device is available
> before the DHCP packet is sended.

The bug is more fundamental than this.

The code is not taking a reference to the netdevice, and that's
the only reason it is able to disappear like this.

It is illegal to reference a netdevice after dropping the rtnl
mutex unless you take a proper reference to it.