Searched hist:"5 c25f65fd1e42685f7ccd80e0621829c105785d9" (Results 1 – 1 of 1) sorted by relevance
/openbmc/linux/drivers/net/ |
H A D | tun.c | diff 5c25f65fd1e42685f7ccd80e0621829c105785d9 Wed Oct 25 13:50:50 CDT 2017 Julien Gomes <julien@arista.com> tun: allow positive return values on dev_get_valid_name() call
If the name argument of dev_get_valid_name() contains "%d", it will try to assign it a unit number in __dev__alloc_name() and return either the unit number (>= 0) or an error code (< 0). Considering positive values as error values prevent tun device creations relying this mechanism, therefor we should only consider negative values as errors here.
Signed-off-by: Julien Gomes <julien@arista.com> Acked-by: Cong Wang <xiyou.wangcong@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
|