Lines Matching refs:opts
588 struct f_phonet_opts *opts = to_f_phonet_opts(item); in phonet_attr_release() local
590 usb_put_function_instance(&opts->func_inst); in phonet_attr_release()
617 struct f_phonet_opts *opts; in phonet_free_inst() local
619 opts = container_of(f, struct f_phonet_opts, func_inst); in phonet_free_inst()
620 if (opts->bound) in phonet_free_inst()
621 gphonet_cleanup(opts->net); in phonet_free_inst()
623 free_netdev(opts->net); in phonet_free_inst()
624 kfree(opts); in phonet_free_inst()
629 struct f_phonet_opts *opts; in phonet_alloc_inst() local
631 opts = kzalloc(sizeof(*opts), GFP_KERNEL); in phonet_alloc_inst()
632 if (!opts) in phonet_alloc_inst()
635 opts->func_inst.free_func_inst = phonet_free_inst; in phonet_alloc_inst()
636 opts->net = gphonet_setup_default(); in phonet_alloc_inst()
637 if (IS_ERR(opts->net)) { in phonet_alloc_inst()
638 struct net_device *net = opts->net; in phonet_alloc_inst()
639 kfree(opts); in phonet_alloc_inst()
643 config_group_init_type_name(&opts->func_inst.group, "", in phonet_alloc_inst()
646 return &opts->func_inst; in phonet_alloc_inst()
675 struct f_phonet_opts *opts; in phonet_alloc() local
683 opts = container_of(fi, struct f_phonet_opts, func_inst); in phonet_alloc()
685 fp->dev = opts->net; in phonet_alloc()