diff --git a/drivers/net/tun.c b/drivers/net/tun.c index 5f516687be48..e92e86c7748e 100644 --- a/drivers/net/tun.c +++ b/drivers/net/tun.c @@ -1570,6 +1570,8 @@ static void tun_setup(struct net_device *dev) */ static int tun_validate(struct nlattr *tb[], struct nlattr *data[]) { + if (!data) + return 0; return -EINVAL; }