]> git.baikalelectronics.ru Git - kernel.git/commit
tun: set the flags before registering the netdevice
authorSabrina Dubroca <sd@queasysnail.net>
Tue, 10 Apr 2018 14:28:55 +0000 (16:28 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 11 Apr 2018 18:48:05 +0000 (14:48 -0400)
commitd797aefe944c2d94b82f5eecf62af433710a20b7
tree4fa9368ac79ecd4e3aac22df21d968d6cfd5d8a1
parentb1f7f00199a51b7b16d8dc1470347bfd984b9e50
tun: set the flags before registering the netdevice

Otherwise, register_netdevice advertises the creation of the device with
the default flags, instead of what the user requested.

Reported-by: Thomas Haller <thaller@redhat.com>
Fixes: 631b92c16587 ("tun: export flags, uid, gid, queue information over netlink")
Signed-off-by: Sabrina Dubroca <sd@queasysnail.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/tun.c