• Patrick McHardy's avatar
    [VLAN]: Convert name-based configuration functions to struct netdevice * · c17d8874
    Patrick McHardy authored
    Move the device lookup and checks to the ioctl handler under the RTNL and
    change all name-based interfaces to take a struct net_device * instead.
    This allows to use them from a netlink interface, which identifies devices
    based on ifindex not name. It also avoids races between the ioctl interface
    and the (upcoming) netlink interface since now all changes happen under the
    As a nice side effect this greatly simplifies error handling in the helper
    functions and fixes a number of incorrect error codes like -EINVAL for
    device not found.
    Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>