]> git.baikalelectronics.ru Git - kernel.git/commit
netvsc: use refcount_t for keeping track of sub channels
authorstephen hemminger <stephen@networkplumber.org>
Wed, 22 Mar 2017 21:51:02 +0000 (14:51 -0700)
committerDavid S. Miller <davem@davemloft.net>
Thu, 23 Mar 2017 02:38:56 +0000 (19:38 -0700)
commita801bedfe1c6acd790a4750b9eb955c2fb43f955
treec2102c18cbeb22c0abadece9a602a6ad73bc06ae
parent8128404ebfab33edb21b20182dcede17625cb8dd
netvsc: use refcount_t for keeping track of sub channels

Rather than a lock and variable, use a refcount_t to keep track
of the number of sub channels.  Don't need to wait for subchannels
on device removal since wait was already done in device_add.

Also fix the error handling; don't wait forever in case of
an error on request to create sub channels.

Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/hyperv/hyperv_net.h
drivers/net/hyperv/rndis_filter.c