openwrt/target/linux
Rafał Miłecki 981f5f7e40 kernel: fix refcnt leak in LED netdev trigger on interface rename
Renaming a netdev-trigger-tracked interface was resulting in an
unbalanced dev_hold().

Example:
> iw phy phy0 interface add foo type __ap
> echo netdev > trigger
> echo foo > device_name
> ip link set foo name bar
> iw dev bar del
[  237.355366] unregister_netdevice: waiting for bar to become free. Usage count = 1
[  247.435362] unregister_netdevice: waiting for bar to become free. Usage count = 1
[  257.545366] unregister_netdevice: waiting for bar to become free. Usage count = 1

Above problem was caused by trigger checking a dev->name which obviously
changes after renaming an interface. It meant missing all further events
including the NETDEV_UNREGISTER which is required for calling dev_put().

This change fixes that by:
1) Comparing device struct *address* for notification-filtering purposes
2) Dropping unneeded NETDEV_CHANGENAME code (no behavior change)

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
(cherry picked from commit eea538204b)
2019-03-06 06:12:39 +01:00
..
adm5120 Mark targets using kernel 3.18 as source-only 2017-02-17 06:58:33 +01:00
adm8668 Mark targets using kernel 3.18 as source-only 2017-02-17 06:58:33 +01:00
apm821xx apm821xx: switch MX60(W)'s recovery images to multi-image method 2019-01-01 18:53:06 +01:00
ar7 ar7: add NULL clock fix send upstream 2017-07-29 09:24:47 +02:00
ar71xx kernel: bump 4.4 to 4.4.167 2018-12-18 15:14:39 +01:00
arc770 arc770: only calculate entry point address when necessary 2017-03-01 20:37:37 +01:00
archs38 archs38: only calculate entry point address when necessary 2017-03-01 20:37:37 +01:00
arm64 kernel: bump kernel 4.4 to version 4.4.137 2018-06-15 19:20:56 +02:00
armvirt armvirt: add kernel config change missing from 0d44f0cb 2017-01-13 11:05:32 +01:00
at91 kernel: bump kernel 4.4 to version 4.4.137 2018-06-15 19:20:56 +02:00
ath25 kernel: bump kernel 4.4 to version 4.4.137 2018-06-15 19:20:56 +02:00
au1000 Mark targets using kernel 3.18 as source-only 2017-02-17 06:58:33 +01:00
bcm53xx kernel: bump 4.4 to 4.4.167 2018-12-18 15:14:39 +01:00
brcm47xx kernel: bump 4.4 to 4.4.167 2018-12-18 15:14:39 +01:00
brcm63xx kernel: bump 4.4 to 4.4.167 2018-12-18 15:14:39 +01:00
brcm2708 kernel: bump 4.4 to 4.4.167 2018-12-18 15:14:39 +01:00
cns3xxx kernel: bump kernel 4.4 to version 4.4.153 2018-08-30 13:07:40 +02:00
gemini kernel: bump kernel 4.4 to version 4.4.137 2018-06-15 19:20:56 +02:00
generic kernel: fix refcnt leak in LED netdev trigger on interface rename 2019-03-06 06:12:39 +01:00
imx6 kernel: bump 4.4 to 4.4.167 2018-12-18 15:14:39 +01:00
ipq806x kernel: bump kernel 4.4 to version 4.4.147 2018-08-09 23:17:09 +02:00
ixp4xx kernel: bump kernel 4.4 to version 4.4.147 2018-08-09 23:17:09 +02:00
kirkwood kirkwood: fix include in etc/board.d/02_network 2017-03-01 20:37:37 +01:00
lantiq kernel: bump kernel 4.4 to 4.4.129 for 17.01 2018-04-30 08:00:27 +02:00
layerscape kernel: bump 4.4 to 4.4.167 2018-12-18 15:14:39 +01:00
malta kernel: bump kernel 4.4 to version 4.4.137 2018-06-15 19:20:56 +02:00
mcs814x Mark targets using kernel 3.18 as source-only 2017-02-17 06:58:33 +01:00
mediatek kernel: bump 4.4 to 4.4.167 2018-12-18 15:14:39 +01:00
mpc85xx WDR4900v1 remove dt node for absent hw crypto. 2018-07-22 01:06:10 +00:00
mvebu kernel: bump 4.4 to 4.4.167 2018-12-18 15:14:39 +01:00
mxs kernel: bump 4.4 to 4.4.167 2018-12-18 15:14:39 +01:00
octeon kernel: bump kernel 4.4 to version 4.4.137 2018-06-15 19:20:56 +02:00
omap omap: build various core drivers into the kernel instead of packaging them 2017-01-10 13:44:26 +01:00
omap24xx kernel: clean up usb gadget support 2016-09-15 13:11:21 +02:00
orion kernel: remove DEVMEM/DEVKMEM platform overrides 2017-01-10 13:48:53 +01:00
oxnas kernel: bump 4.4 to 4.4.167 2018-12-18 15:14:39 +01:00
ppc40x build: fix subtarget descriptions 2016-09-04 13:35:11 +02:00
ppc44x ppc44x: mark as broken 2017-01-10 12:49:34 +01:00
ramips kernel: bump 4.4 to 4.4.167 2018-12-18 15:14:39 +01:00
rb532 kernel: bump kernel 4.4 to version 4.4.137 2018-06-15 19:20:56 +02:00
sunxi sunxi: disable LPAE to allow kernel to run on A13 2018-02-27 19:38:12 +01:00
uml uml: mark as source-only 2017-01-24 13:35:47 +01:00
x86 kernel: bump kernel 4.4 to version 4.4.147 2018-08-09 23:17:09 +02:00
xburst xburst: enable high-res timers, refresh kernel config 2017-12-13 15:55:45 +01:00
zynq kernel: bump kernel 4.4 to version 4.4.137 2018-06-15 19:20:56 +02:00
Makefile