Lines Matching refs:k
836 void kset_init(struct kset *k) in kset_init() argument
838 kobject_init_internal(&k->kobj); in kset_init()
839 INIT_LIST_HEAD(&k->list); in kset_init()
840 spin_lock_init(&k->list_lock); in kset_init()
878 int kset_register(struct kset *k) in kset_register() argument
882 if (!k) in kset_register()
885 if (!k->kobj.ktype) { in kset_register()
890 kset_init(k); in kset_register()
891 err = kobject_add_internal(&k->kobj); in kset_register()
894 kobject_uevent(&k->kobj, KOBJ_ADD); in kset_register()
903 void kset_unregister(struct kset *k) in kset_unregister() argument
905 if (!k) in kset_unregister()
907 kobject_del(&k->kobj); in kset_unregister()
908 kobject_put(&k->kobj); in kset_unregister()
923 struct kobject *k; in kset_find_obj() local
928 list_for_each_entry(k, &kset->list, entry) { in kset_find_obj()
929 if (kobject_name(k) && !strcmp(kobject_name(k), name)) { in kset_find_obj()
930 ret = kobject_get_unless_zero(k); in kset_find_obj()