Home
last modified time | relevance | path

Searched refs:kobj (Results 1 – 25 of 49) sorted by relevance

12

/freebsd/sys/compat/linuxkpi/common/src/
H A Dlinux_kobject.c33 static void kset_join(struct kobject *kobj);
34 static void kset_leave(struct kobject *kobj);
35 static void kset_kfree(struct kobject *kobj);
40 struct kobject *kobj; in kobject_create() local
42 kobj = kzalloc(sizeof(*kobj), GFP_KERNEL); in kobject_create()
43 if (kobj == NULL) in kobject_create()
45 kobject_init(kobj, &linux_kfree_type); in kobject_create()
47 return (kobj); in kobject_create()
52 kobject_set_name_vargs(struct kobject *kobj, const char *fmt, va_list args) in kobject_set_name_vargs() argument
60 old = kobj->name; in kobject_set_name_vargs()
[all …]
H A Dlinux_compat.c187 linux_class_show(struct kobject *kobj, struct attribute *attr, char *buf) in linux_class_show() argument
195 error = dattr->show(container_of(kobj, struct class, kobj), in linux_class_show()
201 linux_class_store(struct kobject *kobj, struct attribute *attr, const char *buf, in linux_class_store() argument
210 error = dattr->store(container_of(kobj, struct class, kobj), in linux_class_store()
216 linux_class_release(struct kobject *kobj) in linux_class_release() argument
220 class = container_of(kobj, struct class, kobj); in linux_class_release()
236 linux_dev_release(struct kobject *kobj) in linux_dev_release() argument
240 dev = container_of(kobj, struct device, kobj); in linux_dev_release()
249 linux_dev_show(struct kobject *kobj, struct attribute *attr, char *buf) in linux_dev_show() argument
257 error = dattr->show(container_of(kobj, struct device, kobj), in linux_dev_show()
[all …]
/freebsd/sys/compat/linuxkpi/common/include/linux/
H A Dkobject.h49 void (*release)(struct kobject *kobj);
79 ssize_t (*show)(struct kobject *kobj, struct kobj_attribute *attr,
81 ssize_t (*store)(struct kobject *kobj, struct kobj_attribute *attr,
92 struct kobject kobj; member
97 kobject_init(struct kobject *kobj, const struct kobj_type *ktype) in kobject_init() argument
100 kref_init(&kobj->kref); in kobject_init()
101 INIT_LIST_HEAD(&kobj->entry); in kobject_init()
102 kobj->ktype = ktype; in kobject_init()
103 kobj->oidp = NULL; in kobject_init()
109 kobject_put(struct kobject *kobj) in kobject_put() argument
[all …]
H A Dsysfs.h85 struct kobject *kobj; in sysctl_handle_attr() local
92 kobj = arg1; in sysctl_handle_attr()
94 if (kobj->ktype == NULL || kobj->ktype->sysfs_ops == NULL) in sysctl_handle_attr()
99 ops = kobj->ktype->sysfs_ops; in sysctl_handle_attr()
101 len = ops->show(kobj, attr, buf); in sysctl_handle_attr()
126 len = ops->store(kobj, attr, buf, len); in sysctl_handle_attr()
136 sysfs_create_file(struct kobject *kobj, const struct attribute *attr) in sysfs_create_file() argument
140 oid = SYSCTL_ADD_OID(NULL, SYSCTL_CHILDREN(kobj->oidp), OID_AUTO, in sysfs_create_file()
141 attr->name, CTLTYPE_STRING|CTLFLAG_RW|CTLFLAG_MPSAFE, kobj, in sysfs_create_file()
151 sysfs_remove_file(struct kobject *kobj, const struct attribute *attr) in sysfs_remove_file() argument
[all …]
H A Ddevice.h60 struct kobject kobj; member
116 struct kobject kobj; member
321 kobject_get(&dev->kobj); in get_device()
330 return kobject_name(&dev->kobj); in dev_name()
341 kobject_set_name(&(_dev)->kobj, (_fmt), ##__VA_ARGS__)
348 kobject_put(&dev->kobj); in put_device()
363 kobject_init(&class->kobj, &linux_class_ktype); in class_register()
364 kobject_set_name(&class->kobj, class->name); in class_register()
365 kobject_add(&class->kobj, &linux_class_root, class->name); in class_register()
374 kobject_put(&class->kobj); in class_unregister()
[all …]
H A Dcdev.h49 struct kobject kobj; member
64 kobject_init(&cdev->kobj, &linux_cdev_static_ktype); in cdev_init()
72 kobject_put(&p->kobj); in cdev_put()
95 kobject_name(&cdev->kobj)); in cdev_add()
99 kobject_get(cdev->kobj.parent); in cdev_add()
120 kobject_name(&cdev->kobj), MINOR(dev)); in cdev_add_ext()
124 kobject_get(cdev->kobj.parent); in cdev_add_ext()
131 kobject_put(&cdev->kobj); in cdev_del()
H A Dmiscdevice.h59 kobject_set_name(&misc->cdev->kobj, misc->name); in misc_register()
/freebsd/sys/ofed/drivers/infiniband/core/
H A Dib_sysfs.c54 struct kobject kobj; member
59 struct kobject kobj; member
92 ssize_t (*show)(struct kobject *kobj,
94 ssize_t (*store)(struct kobject *kobj,
102 static ssize_t port_attr_show(struct kobject *kobj, in port_attr_show() argument
107 struct ib_port *p = container_of(kobj, struct ib_port, kobj); in port_attr_show()
115 static ssize_t port_attr_store(struct kobject *kobj, in port_attr_store() argument
121 struct ib_port *p = container_of(kobj, struct ib_port, kobj); in port_attr_store()
133 static ssize_t gid_attr_show(struct kobject *kobj, in gid_attr_show() argument
138 struct ib_port *p = container_of(kobj, struct gid_attr_group, in gid_attr_show()
[all …]
H A Dib_user_mad.c104 struct kobject kobj; member
140 static void ib_umad_release_dev(struct kobject *kobj) in ib_umad_release_dev() argument
143 container_of(kobj, struct ib_umad_device, kobj); in ib_umad_release_dev()
970 kobject_get(&port->umad_dev->kobj); in ib_umad_open()
1009 kobject_put(&dev->kobj); in ib_umad_close()
1060 kobject_get(&port->umad_dev->kobj); in ib_umad_sm_open()
1090 kobject_put(&port->umad_dev->kobj); in ib_umad_sm_close()
1192 port->cdev.kobj.parent = &umad_dev->kobj; in ib_umad_init_port()
1193 kobject_set_name(&port->cdev.kobj, "umad%d", port->dev_num); in ib_umad_init_port()
1211 port->sm_cdev.kobj.parent = &umad_dev->kobj; in ib_umad_init_port()
[all …]
H A Dcore_priv.h144 struct kobject *kobj, struct kobj_type *ktype,
146 void ib_port_unregister_module_stat(struct kobject *kobj);
/freebsd/sys/dev/mlx4/mlx4_ib/
H A Dmlx4_ib_sysfs.c159 sysfs_remove_file((_dentry)->kobj, &(_dentry)->dentry.attr); \
181 vdentry->kobj = _kobj; in create_sysfs_entry()
190 ret = sysfs_create_file(vdentry->kobj, &vdentry->dentry.attr); in create_sysfs_entry()
368 struct kobject kobj; member
379 static void mlx4_port_release(struct kobject *kobj) in mlx4_port_release() argument
381 struct mlx4_port *p = container_of(kobj, struct mlx4_port, kobj); in mlx4_port_release()
401 static ssize_t port_attr_show(struct kobject *kobj, in port_attr_show() argument
406 struct mlx4_port *p = container_of(kobj, struct mlx4_port, kobj); in port_attr_show()
413 static ssize_t port_attr_store(struct kobject *kobj, in port_attr_store() argument
419 struct mlx4_port *p = container_of(kobj, struct mlx4_port, kobj); in port_attr_store()
[all …]
/freebsd/sys/contrib/openzfs/module/os/linux/zfs/
H A Dzfs_sysfs.c118 zfs_kobj_release(struct kobject *kobj) in zfs_kobj_release() argument
120 zfs_mod_kobj_t *zkobj = container_of(kobj, zfs_mod_kobj_t, zko_kobj); in zfs_kobj_release()
329 dataset_property_show(struct kobject *kobj, struct attribute *attr, char *buf) in dataset_property_show() argument
331 zfs_prop_t prop = zfs_name_to_prop(kobject_name(kobj)); in dataset_property_show()
343 vdev_property_show(struct kobject *kobj, struct attribute *attr, char *buf) in vdev_property_show() argument
345 vdev_prop_t prop = vdev_name_to_prop(kobject_name(kobj)); in vdev_property_show()
357 pool_property_show(struct kobject *kobj, struct attribute *attr, char *buf) in pool_property_show() argument
359 zpool_prop_t prop = zpool_name_to_prop(kobject_name(kobj)); in pool_property_show()
389 kernel_feature_show(struct kobject *kobj, struct attribute *attr, char *buf) in kernel_feature_show() argument
463 pool_feature_show(struct kobject *kobj, struct attribute *attr, char *buf) in pool_feature_show() argument
[all …]
/freebsd/lib/librpcsec_gss/
H A Drpcsec_gss_conf.c54 char *kobj; member
182 char *name, *oid, *lib, *kobj; in _rpc_gss_load_mech() local
205 kobj = strsep(&p, "\t\n "); in _rpc_gss_load_mech()
206 if (!name || !oid || !lib || !kobj) in _rpc_gss_load_mech()
219 info->kobj = strdup(kobj); in _rpc_gss_load_mech()
/freebsd/sys/dev/drm2/ttm/
H A Dttm_page_alloc_dma.c175 struct kobject kobj; member
200 static void ttm_pool_kobj_release(struct kobject *kobj) in ttm_pool_kobj_release() argument
203 container_of(kobj, struct ttm_pool_manager, kobj); in ttm_pool_kobj_release()
207 static ssize_t ttm_pool_store(struct kobject *kobj, struct attribute *attr, in ttm_pool_store() argument
211 container_of(kobj, struct ttm_pool_manager, kobj); in ttm_pool_store()
241 static ssize_t ttm_pool_show(struct kobject *kobj, struct attribute *attr, in ttm_pool_show() argument
245 container_of(kobj, struct ttm_pool_manager, kobj); in ttm_pool_show()
1074 ret = kobject_init_and_add(&_manager->kobj, &ttm_pool_kobj_type, in ttm_dma_page_alloc_init()
1075 &glob->kobj, "dma_pool"); in ttm_dma_page_alloc_init()
1077 kobject_put(&_manager->kobj); in ttm_dma_page_alloc_init()
[all …]
/freebsd/sys/contrib/dev/athk/ath10k/
H A Dthermal.c172 ret = sysfs_create_link(&ar->dev->kobj, &cdev->device.kobj, in ath10k_thermal_register()
206 sysfs_remove_link(&ar->dev->kobj, "cooling_device"); in ath10k_thermal_register()
217 sysfs_remove_link(&ar->dev->kobj, "cooling_device"); in ath10k_thermal_unregister()
/freebsd/sys/dev/sound/pci/
H A Dmaestro3.c320 m3_initcd(kobj_t kobj, void *devinfo) in m3_initcd() argument
334 m3_rdcd(kobj_t kobj, void *devinfo, int regno) in m3_rdcd() argument
354 m3_wrcd(kobj_t kobj, void *devinfo, int regno, u_int32_t data) in m3_wrcd() argument
374 m3_pchan_init(kobj_t kobj, void *devinfo, struct snd_dbuf *b, struct pcm_channel *c, int dir) in m3_pchan_init() argument
516 m3_pchan_free(kobj_t kobj, void *chdata) in m3_pchan_free() argument
540 m3_pchan_setformat(kobj_t kobj, void *chdata, u_int32_t format) in m3_pchan_setformat() argument
568 m3_pchan_setspeed(kobj_t kobj, void *chdata, u_int32_t speed) in m3_pchan_setspeed() argument
591 m3_pchan_setblocksize(kobj_t kobj, void *chdata, u_int32_t blocksize) in m3_pchan_setblocksize() argument
602 m3_pchan_trigger(kobj_t kobj, void *chdata, int go) in m3_pchan_trigger() argument
612 ret = m3_pchan_trigger_locked(kobj, chdata, go); in m3_pchan_trigger()
[all …]
/freebsd/sys/contrib/dev/athk/ath11k/
H A Dthermal.c183 ret = sysfs_create_link(&ar->hw->wiphy->dev.kobj, &cdev->device.kobj, in ath11k_thermal_register()
223 sysfs_remove_link(&ar->hw->wiphy->dev.kobj, "cooling_device"); in ath11k_thermal_unregister()
/freebsd/lib/libgssapi/
H A Dgss_mech_switch.c189 char *name, *oid, *lib, *kobj; in _gss_load_mech() local
218 kobj = strsep(&p, "\t\n "); in _gss_load_mech()
219 if (!name || !oid || !lib || !kobj) in _gss_load_mech()
/freebsd/sys/contrib/openzfs/rpm/generic/
H A Dzfs-kmod.spec.in18 %if !%{defined kobj}
20 %define kobj ${kernel_version##*___}
22 %define kobj "$( \
142 --with-linux-obj=%{kobj} \
/freebsd/sys/sys/
H A Dkobj.h35 typedef struct kobj *kobj_t;
72 struct kobj { struct
/freebsd/crypto/heimdal/lib/gssapi/mech/
H A Dgss_mech_switch.c235 char *name, *oid, *lib, *kobj; in _gss_load_mech() local
280 kobj = strsep(&p, "\t\n "); in _gss_load_mech()
281 if (!name || !oid || !lib || !kobj) in _gss_load_mech()
/freebsd/sys/contrib/openzfs/rpm/redhat/
H A Dzfs-kmod.spec.in35 %define kobj %{ksrc}
67 --with-linux-obj=%{kobj} \
/freebsd/usr.sbin/gssd/
H A Dgssd.c224 char *name, *oid, *lib, *kobj; in gssd_load_mech() local
240 kobj = strsep(&p, "\t\n "); in gssd_load_mech()
241 if (!name || !oid || !lib || !kobj) in gssd_load_mech()
244 if (strcmp(kobj, "-")) { in gssd_load_mech()
249 if (modfind(kobj) < 0) { in gssd_load_mech()
250 if (kldload(kobj) < 0) { in gssd_load_mech()
253 getprogname(), kobj, name); in gssd_load_mech()
/freebsd/sys/dev/sound/pcm/
H A Dac97.h86 #define AC97_DECLARE(name) static DEFINE_CLASS(name, name ## _methods, sizeof(struct kobj))
/freebsd/sys/libkern/
H A Diconv_xlat.c74 kobj_delete((struct kobj*)data, M_ICONV); in iconv_xlat_close()

12