Home
last modified time | relevance | path

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

123

/arch/powerpc/platforms/powernv/
Dopal-elog.c25 struct kobject kobj; member
32 #define to_elog_obj(x) container_of(x, struct elog_obj, kobj)
80 sysfs_remove_file_self(&elog_obj->kobj, &attr->attr); in elog_ack_store()
81 kobject_put(&elog_obj->kobj); in elog_ack_store()
94 static ssize_t elog_attr_show(struct kobject *kobj, in elog_attr_show() argument
102 elog = to_elog_obj(kobj); in elog_attr_show()
110 static ssize_t elog_attr_store(struct kobject *kobj, in elog_attr_store() argument
118 elog = to_elog_obj(kobj); in elog_attr_store()
131 static void elog_release(struct kobject *kobj) in elog_release() argument
135 elog = to_elog_obj(kobj); in elog_release()
[all …]
Dopal-dump.c25 struct kobject kobj; member
32 #define to_dump_obj(x) container_of(x, struct dump_obj, kobj)
96 sysfs_remove_file_self(&dump_obj->kobj, &attr->attr); in dump_ack_store()
97 kobject_put(&dump_obj->kobj); in dump_ack_store()
158 static ssize_t dump_attr_show(struct kobject *kobj, in dump_attr_show() argument
166 dump = to_dump_obj(kobj); in dump_attr_show()
174 static ssize_t dump_attr_store(struct kobject *kobj, in dump_attr_store() argument
182 dump = to_dump_obj(kobj); in dump_attr_store()
195 static void dump_release(struct kobject *kobj) in dump_release() argument
199 dump = to_dump_obj(kobj); in dump_release()
[all …]
Dopal-flash.c154 static ssize_t validate_show(struct kobject *kobj, in validate_show() argument
194 static ssize_t validate_store(struct kobject *kobj, in validate_store() argument
239 static ssize_t manage_show(struct kobject *kobj, in manage_show() argument
256 static ssize_t manage_store(struct kobject *kobj, in manage_store() argument
350 static ssize_t update_show(struct kobject *kobj, in update_show() argument
362 static ssize_t update_store(struct kobject *kobj, in update_store() argument
464 static ssize_t image_data_write(struct file *filp, struct kobject *kobj, in image_data_write() argument
/arch/x86/kernel/
Dksysfs.c23 static ssize_t version_show(struct kobject *kobj, in version_show() argument
31 static ssize_t boot_params_data_read(struct file *fp, struct kobject *kobj, in boot_params_data_read() argument
63 static int kobj_to_setup_data_nr(struct kobject *kobj, int *nr) in kobj_to_setup_data_nr() argument
67 name = kobject_name(kobj); in kobj_to_setup_data_nr()
116 static ssize_t type_show(struct kobject *kobj, in type_show() argument
123 ret = kobj_to_setup_data_nr(kobj, &nr); in type_show()
140 struct kobject *kobj, in setup_data_data_read() argument
150 ret = kobj_to_setup_data_nr(kobj, &nr); in setup_data_data_read()
215 struct kobject *kobj; in create_setup_data_node() local
219 kobj = kobject_create_and_add(name, parent); in create_setup_data_node()
[all …]
Dtopology.c76 kobject_uevent(&dev->kobj, KOBJ_OFFLINE); in _debug_hotplug_cpu()
84 kobject_uevent(&dev->kobj, KOBJ_ONLINE); in _debug_hotplug_cpu()
/arch/ia64/kernel/
Dtopology.c129 struct kobject kobj; member
135 struct kobject kobj; member
273 #define to_object(k) container_of(k, struct cache_info, kobj)
276 static ssize_t ia64_cache_show(struct kobject * kobj, struct attribute * attr, char * buf) in ia64_cache_show() argument
279 struct cache_info *this_leaf = to_object(kobj); in ia64_cache_show()
304 memset(&all_cpu_cache_info[cpu].kobj, 0, sizeof(struct kobject)); in cpu_cache_sysfs_exit()
346 memset(&all_cpu_cache_info[cpu].kobj, 0, sizeof(struct kobject)); in cpu_cache_sysfs_init()
360 if (all_cpu_cache_info[cpu].kobj.parent) in cache_add_dev()
373 retval = kobject_init_and_add(&all_cpu_cache_info[cpu].kobj, in cache_add_dev()
374 &cache_ktype_percpu_entry, &sys_dev->kobj, in cache_add_dev()
[all …]
Derr_inject.c229 return sysfs_create_group(&sys_dev->kobj, &err_inject_attr_group); in err_inject_add_dev()
234 sysfs_remove_group(&sys_dev->kobj, &err_inject_attr_group); in err_inject_remove_dev()
300 sysfs_remove_group(&sys_dev->kobj, &err_inject_attr_group); in err_inject_exit()
/arch/arm64/kernel/
Dcpuinfo.c202 #define kobj_to_cpuinfo(kobj) container_of(kobj, struct cpuinfo_arm64, kobj) argument
204 static ssize_t _name##_show(struct kobject *kobj, \
207 struct cpuinfo_arm64 *info = kobj_to_cpuinfo(kobj); \
241 rc = kobject_add(&info->kobj, &dev->kobj, "regs"); in cpuid_add_regs()
244 rc = sysfs_create_group(&info->kobj, &cpuregs_attr_group); in cpuid_add_regs()
246 kobject_del(&info->kobj); in cpuid_add_regs()
259 if (info->kobj.parent) { in cpuid_remove_regs()
260 sysfs_remove_group(&info->kobj, &cpuregs_attr_group); in cpuid_remove_regs()
261 kobject_del(&info->kobj); in cpuid_remove_regs()
294 kobject_init(&info->kobj, &cpuregs_kobj_type); in cpuinfo_regs_init()
/arch/x86/kernel/cpu/mcheck/
Dmce_amd.c782 #define to_block(k) container_of(k, struct threshold_block, kobj)
785 static ssize_t show(struct kobject *kobj, struct attribute *attr, char *buf) in show() argument
787 struct threshold_block *b = to_block(kobj); in show()
796 static ssize_t store(struct kobject *kobj, struct attribute *attr, in store() argument
799 struct threshold_block *b = to_block(kobj); in store()
898 err = kobject_init_and_add(&b->kobj, &threshold_ktype, in allocate_threshold_blocks()
899 per_cpu(threshold_banks, cpu)[bank]->kobj, in allocate_threshold_blocks()
913 kobject_uevent(&b->kobj, KOBJ_ADD); in allocate_threshold_blocks()
919 kobject_put(&b->kobj); in allocate_threshold_blocks()
933 err = kobject_add(&b->blocks->kobj, b->kobj, b->blocks->kobj.name); in __threshold_add_blocks()
[all …]
Dtherm_throt.c247 err = sysfs_create_group(&dev->kobj, &thermal_attr_group); in thermal_throttle_add_dev()
252 err = sysfs_add_file_to_group(&dev->kobj, in thermal_throttle_add_dev()
256 err = sysfs_add_file_to_group(&dev->kobj, in thermal_throttle_add_dev()
260 err = sysfs_add_file_to_group(&dev->kobj, in thermal_throttle_add_dev()
270 sysfs_remove_group(&dev->kobj, &thermal_attr_group); in thermal_throttle_remove_dev()
/arch/s390/kernel/
Dipl.c194 static ssize_t sys_##_prefix##_##_name##_show(struct kobject *kobj, \
202 static ssize_t sys_##_prefix##_##_name##_store(struct kobject *kobj, \
235 static ssize_t sys_##_prefix##_##_name##_store(struct kobject *kobj, \
252 static ssize_t sys_##_prefix##_##_name##_store(struct kobject *kobj, \
299 static ssize_t ipl_type_show(struct kobject *kobj, struct kobj_attribute *attr, in ipl_type_show() argument
352 static ssize_t ipl_vm_parm_show(struct kobject *kobj, in ipl_vm_parm_show() argument
419 static ssize_t sys_ipl_device_show(struct kobject *kobj, in sys_ipl_device_show() argument
438 static ssize_t ipl_parameter_read(struct file *filp, struct kobject *kobj, in ipl_parameter_read() argument
449 static ssize_t ipl_scp_data_read(struct file *filp, struct kobject *kobj, in ipl_scp_data_read() argument
478 static ssize_t ipl_ccw_loadparm_show(struct kobject *kobj, in ipl_ccw_loadparm_show() argument
[all …]
/arch/powerpc/kernel/
Dcacheinfo.c31 struct kobject *kobj; /* bare (not embedded) kobject for cache member
41 struct kobject kobj; member
135 return container_of(k, struct cache_index_dir, kobj); in kobj_to_cache_index_dir()
482 struct kobject *kobj = NULL; in cacheinfo_create_cache_dir() local
489 kobj = kobject_create_and_add("cache", &dev->kobj); in cacheinfo_create_cache_dir()
490 if (!kobj) in cacheinfo_create_cache_dir()
497 cache_dir->kobj = kobj; in cacheinfo_create_cache_dir()
505 kobject_put(kobj); in cacheinfo_create_cache_dir()
509 static void cache_index_release(struct kobject *kobj) in cache_index_release() argument
513 index = kobj_to_cache_index_dir(kobj); in cache_index_release()
[all …]
/arch/alpha/kernel/
Dpci-sysfs.c63 static int pci_mmap_resource(struct kobject *kobj, in pci_mmap_resource() argument
67 struct pci_dev *pdev = to_pci_dev(container_of(kobj, in pci_mmap_resource()
68 struct device, kobj)); in pci_mmap_resource()
93 static int pci_mmap_resource_sparse(struct file *filp, struct kobject *kobj, in pci_mmap_resource_sparse() argument
97 return pci_mmap_resource(kobj, attr, vma, 1); in pci_mmap_resource_sparse()
100 static int pci_mmap_resource_dense(struct file *filp, struct kobject *kobj, in pci_mmap_resource_dense() argument
104 return pci_mmap_resource(kobj, attr, vma, 0); in pci_mmap_resource_dense()
123 sysfs_remove_bin_file(&pdev->dev.kobj, res_attr); in pci_remove_resource_files()
129 sysfs_remove_bin_file(&pdev->dev.kobj, res_attr); in pci_remove_resource_files()
167 return sysfs_create_bin_file(&pdev->dev.kobj, res_attr); in pci_create_one_attr()
/arch/cris/arch-v32/drivers/
Diop_fw_load.c206 kobject_set_name(&iop_spu_device[0].kobj, "iop-spu0"); in iop_fw_load_init()
207 kobject_add(&iop_spu_device[0].kobj); in iop_fw_load_init()
209 kobject_set_name(&iop_spu_device[1].kobj, "iop-spu1"); in iop_fw_load_init()
210 kobject_add(&iop_spu_device[1].kobj); in iop_fw_load_init()
212 kobject_set_name(&iop_mpu_device.kobj, "iop-mpu"); in iop_fw_load_init()
213 kobject_add(&iop_mpu_device.kobj); in iop_fw_load_init()
/arch/sh/kernel/cpu/sh4/
Dsq.c269 static ssize_t sq_sysfs_show(struct kobject *kobj, struct attribute *attr, in sq_sysfs_show() argument
280 static ssize_t sq_sysfs_store(struct kobject *kobj, struct attribute *attr, in sq_sysfs_store() argument
343 struct kobject *kobj; in sq_dev_add() local
350 kobj = sq_kobject[cpu]; in sq_dev_add()
351 error = kobject_init_and_add(kobj, &ktype_percpu_entry, &dev->kobj, in sq_dev_add()
354 kobject_uevent(kobj, KOBJ_ADD); in sq_dev_add()
361 struct kobject *kobj = sq_kobject[cpu]; in sq_dev_remove() local
363 kobject_put(kobj); in sq_dev_remove()
/arch/s390/pci/
Dpci_sysfs.c70 static ssize_t util_string_read(struct file *filp, struct kobject *kobj, in util_string_read() argument
74 struct device *dev = kobj_to_dev(kobj); in util_string_read()
83 static ssize_t report_error_write(struct file *filp, struct kobject *kobj, in report_error_write() argument
88 struct device *dev = kobj_to_dev(kobj); in report_error_write()
/arch/x86/platform/uv/
Duv_sysfs.c28 static ssize_t partition_id_show(struct kobject *kobj, in partition_id_show() argument
34 static ssize_t coherence_id_show(struct kobject *kobj, in coherence_id_show() argument
/arch/powerpc/platforms/pseries/
Dpower.c34 static ssize_t auto_poweron_show(struct kobject *kobj, in auto_poweron_show() argument
40 static ssize_t auto_poweron_store(struct kobject *kobj, in auto_poweron_store() argument
/arch/powerpc/sysdev/
Dmv64x60_pci.c28 static ssize_t mv64x60_hs_reg_read(struct file *filp, struct kobject *kobj, in mv64x60_hs_reg_read() argument
49 static ssize_t mv64x60_hs_reg_write(struct file *filp, struct kobject *kobj, in mv64x60_hs_reg_write() argument
100 return sysfs_create_bin_file(&pdev->dev.kobj, &mv64x60_hs_reg_attr); in mv64x60_sysfs_init()
Dppc4xx_cpm.c138 static ssize_t cpm_idle_show(struct kobject *kobj, in cpm_idle_show() argument
156 static ssize_t cpm_idle_store(struct kobject *kobj, in cpm_idle_store() argument
187 ret = sysfs_create_file(&dev->kobj, in cpm_idle_config_sysfs()
/arch/x86/include/asm/
Damd_nb.h42 struct kobject kobj; /* sysfs object */ member
50 struct kobject *kobj; member
/arch/sh/drivers/dma/
Ddma-sysfs.c149 return sysfs_create_link(&info->pdev->dev.kobj, &dev->kobj, name); in dma_create_sysfs_files()
164 sysfs_remove_link(&info->pdev->dev.kobj, name); in dma_remove_sysfs_files()
/arch/x86/kernel/cpu/microcode/
Dcore.c533 err = sysfs_create_group(&dev->kobj, &mc_attr_group); in mc_device_add()
552 sysfs_remove_group(&dev->kobj, &mc_attr_group); in mc_device_remove()
588 if (sysfs_create_group(&dev->kobj, &mc_attr_group)) in mc_cpu_online()
599 sysfs_remove_group(&dev->kobj, &mc_attr_group); in mc_cpu_down_prep()
655 error = sysfs_create_group(&cpu_subsys.dev_root->kobj, in microcode_init()
677 sysfs_remove_group(&cpu_subsys.dev_root->kobj, in microcode_init()
/arch/arm/mach-netx/
Dxc.c196 (NETX_PA_XPEC(xcno), XPEC_MEM_SIZE, kobject_name(&dev->kobj))) in request_xc()
200 (NETX_PA_XMAC(xcno), XMAC_MEM_SIZE, kobject_name(&dev->kobj))) in request_xc()
204 (SRAM_INTERNAL_PHYS(xcno), SRAM_MEM_SIZE, kobject_name(&dev->kobj))) in request_xc()
/arch/x86/platform/olpc/
Dolpc-xo15-sci.c168 r = sysfs_create_file(&device->dev.kobj, &lid_wake_on_close_attr.attr); in xo15_sci_add()
195 sysfs_remove_file(&device->dev.kobj, &lid_wake_on_close_attr.attr); in xo15_sci_remove()

123