Lines Matching refs:err
155 int err; in register_vlan_dev() local
157 err = vlan_vid_add(real_dev, vlan->vlan_proto, vlan_id); in register_vlan_dev()
158 if (err) in register_vlan_dev()
159 return err; in register_vlan_dev()
167 err = vlan_gvrp_init_applicant(real_dev); in register_vlan_dev()
168 if (err < 0) in register_vlan_dev()
170 err = vlan_mvrp_init_applicant(real_dev); in register_vlan_dev()
171 if (err < 0) in register_vlan_dev()
175 err = vlan_group_prealloc_vid(grp, vlan->vlan_proto, vlan_id); in register_vlan_dev()
176 if (err < 0) in register_vlan_dev()
179 err = register_netdevice(dev); in register_vlan_dev()
180 if (err < 0) in register_vlan_dev()
183 err = netdev_upper_dev_link(real_dev, dev, extack); in register_vlan_dev()
184 if (err) in register_vlan_dev()
208 return err; in register_vlan_dev()
221 int err; in register_vlan_device() local
226 err = vlan_check_real_dev(real_dev, htons(ETH_P_8021Q), vlan_id, in register_vlan_device()
228 if (err < 0) in register_vlan_device()
229 return err; in register_vlan_device()
277 err = register_vlan_dev(new_dev, NULL); in register_vlan_device()
278 if (err < 0) in register_vlan_device()
285 return err; in register_vlan_device()
342 int err = 0; in __vlan_device_event() local
347 err = vlan_proc_add_dev(dev); in __vlan_device_event()
350 err = vlan_proc_add_dev(dev); in __vlan_device_event()
357 return err; in __vlan_device_event()
372 int err; in vlan_device_event() local
375 int err = __vlan_device_event(dev, event); in vlan_device_event() local
377 if (err) in vlan_device_event()
378 return notifier_from_errno(err); in vlan_device_event()
507 err = vlan_filter_push_vids(vlan_info, htons(ETH_P_8021Q)); in vlan_device_event()
508 if (err) in vlan_device_event()
509 return notifier_from_errno(err); in vlan_device_event()
517 err = vlan_filter_push_vids(vlan_info, htons(ETH_P_8021AD)); in vlan_device_event()
518 if (err) in vlan_device_event()
519 return notifier_from_errno(err); in vlan_device_event()
542 int err; in vlan_ioctl_handler() local
563 err = -ENODEV; in vlan_ioctl_handler()
568 err = -EINVAL; in vlan_ioctl_handler()
575 err = -EPERM; in vlan_ioctl_handler()
581 err = 0; in vlan_ioctl_handler()
585 err = -EPERM; in vlan_ioctl_handler()
588 err = vlan_dev_set_egress_priority(dev, in vlan_ioctl_handler()
594 err = -EPERM; in vlan_ioctl_handler()
597 err = vlan_dev_change_flags(dev, in vlan_ioctl_handler()
603 err = -EPERM; in vlan_ioctl_handler()
611 err = 0; in vlan_ioctl_handler()
613 err = -EINVAL; in vlan_ioctl_handler()
618 err = -EPERM; in vlan_ioctl_handler()
621 err = register_vlan_device(dev, args.u.VID); in vlan_ioctl_handler()
625 err = -EPERM; in vlan_ioctl_handler()
629 err = 0; in vlan_ioctl_handler()
633 err = 0; in vlan_ioctl_handler()
638 err = -EFAULT; in vlan_ioctl_handler()
642 err = 0; in vlan_ioctl_handler()
646 err = -EFAULT; in vlan_ioctl_handler()
650 err = -EOPNOTSUPP; in vlan_ioctl_handler()
655 return err; in vlan_ioctl_handler()
661 int err; in vlan_init_net() local
665 err = vlan_proc_init(net); in vlan_init_net()
667 return err; in vlan_init_net()
684 int err; in vlan_proto_init() local
688 err = register_pernet_subsys(&vlan_net_ops); in vlan_proto_init()
689 if (err < 0) in vlan_proto_init()
692 err = register_netdevice_notifier(&vlan_notifier_block); in vlan_proto_init()
693 if (err < 0) in vlan_proto_init()
696 err = vlan_gvrp_init(); in vlan_proto_init()
697 if (err < 0) in vlan_proto_init()
700 err = vlan_mvrp_init(); in vlan_proto_init()
701 if (err < 0) in vlan_proto_init()
704 err = vlan_netlink_init(); in vlan_proto_init()
705 if (err < 0) in vlan_proto_init()
720 return err; in vlan_proto_init()