/linux/Documentation/translations/zh_CN/core-api/ |
H A D | kobject.rst | 36 - ktype是嵌入一个kobject的对象的类型。每个嵌入kobject的结构体都需要一个 37 相应的ktype。ktype控制着kobject在被创建和销毁时的行为。 39 - 一个kset是一组kobjects。这些kobjects可以是相同的ktype或者属于不同的 40 ktype。kset是kobjects集合的基本容器类型。Ksets包含它们自己的kobjects, 112 void kobject_init(struct kobject *kobj, struct kobj_type *ktype); 114 ktype是正确创建kobject的必要条件,因为每个kobject都必须有一个相关的kobj_type。 143 int kobject_init_and_add(struct kobject *kobj, struct kobj_type *ktype, 255 有趣的是,release()方法并不存储在kobject本身;相反,它与ktype相关。 276 default_groups 指针是一个默认属性的列表,它将为任何用这个 ktype 注册 284 同的ktype,但是如果它们不是相同的,就要非常小心。
|
/linux/lib/ |
H A D | kobject.c | 37 return kobj->ktype->namespace(kobj); in kobject_namespace() 55 if (kobj->ktype->get_ownership) in kobject_get_ownership() 56 kobj->ktype->get_ownership(kobj, uid, gid); in kobject_get_ownership() 69 const struct kobj_type *ktype = get_ktype(kobj); in create_dir() local 77 if (ktype) { in create_dir() 78 error = sysfs_create_groups(kobj, ktype->default_groups); in create_dir() 324 * @ktype: pointer to the ktype for this kobject. 333 void kobject_init(struct kobject *kobj, const struct kobj_type *ktype) in kobject_init() argument 341 if (!ktype) { in kobject_init() 448 kobject_init_and_add(struct kobject * kobj,const struct kobj_type * ktype,struct kobject * parent,const char * fmt,...) kobject_init_and_add() argument 589 const struct kobj_type *ktype; __kobject_del() local [all...] |
H A D | kobject_uevent.c | 243 ns = kobj->ktype->namespace(kobj); in kobj_usermode_filter() 405 if (ops && ops->netlink_ns && kobj->ktype->namespace) in kobject_uevent_net_broadcast() 407 net = kobj->ktype->namespace(kobj); in kobject_uevent_net_broadcast()
|
/linux/security/keys/ |
H A D | key.c | 715 struct key_type *ktype; in key_type_lookup() local 721 list_for_each_entry(ktype, &key_types_list, link) { in key_type_lookup() 722 if (strcmp(ktype->name, type) == 0) in key_type_lookup() 727 ktype = ERR_PTR(-ENOKEY); in key_type_lookup() 730 return ktype; in key_type_lookup() 751 void key_type_put(struct key_type *ktype) in key_type_put() argument 1221 int register_key_type(struct key_type *ktype) in register_key_type() argument 1226 memset(&ktype->lock_class, 0, sizeof(ktype->lock_class)); in register_key_type() 1233 if (strcmp(p->name, ktype->name) == 0) in register_key_type() 1238 list_add(&ktype->link, &key_types_list); in register_key_type() [all …]
|
H A D | keyctl.c | 172 struct key_type *ktype; in SYSCALL_DEFINE4() local 215 ktype = key_type_lookup(type); in SYSCALL_DEFINE4() 216 if (IS_ERR(ktype)) { in SYSCALL_DEFINE4() 217 ret = PTR_ERR(ktype); in SYSCALL_DEFINE4() 222 key = request_key_and_link(ktype, description, NULL, callout_info, in SYSCALL_DEFINE4() 240 key_type_put(ktype); in SYSCALL_DEFINE4() 721 struct key_type *ktype; in keyctl_keyring_search() local 756 ktype = key_type_lookup(type); in keyctl_keyring_search() 757 if (IS_ERR(ktype)) { in keyctl_keyring_search() 758 ret = PTR_ERR(ktype); in keyctl_keyring_search() [all …]
|
H A D | gc.c | 112 void key_gc_keytype(struct key_type *ktype) in key_gc_keytype() argument 114 kenter("%s", ktype->name); in key_gc_keytype() 116 key_gc_dead_keytype = ktype; in key_gc_keytype()
|
H A D | internal.h | 93 extern void key_type_put(struct key_type *ktype); 173 extern void key_gc_keytype(struct key_type *ktype);
|
/linux/include/linux/ |
H A D | kobject.h | 69 const struct kobj_type *ktype; member 92 void kobject_init(struct kobject *kobj, const struct kobj_type *ktype); 97 const struct kobj_type *ktype, 198 return kobj->ktype; in get_ktype()
|
H A D | key-type.h | 167 extern int register_key_type(struct key_type *ktype); 168 extern void unregister_key_type(struct key_type *ktype);
|
/linux/fs/xfs/ |
H A D | xfs_sysfs.h | 31 const struct kobj_type *ktype, in xfs_sysfs_init() argument 40 err = kobject_init_and_add(&kobj->kobject, ktype, parent, "%s", name); in xfs_sysfs_init()
|
/linux/drivers/s390/crypto/ |
H A D | pkey_cca.c | 155 static int cca_apqns4type(enum pkey_key_type ktype, in cca_apqns4type() argument 164 if (ktype == PKEY_TYPE_CCA_DATA || ktype == PKEY_TYPE_CCA_CIPHER) { in cca_apqns4type() 172 if (ktype == PKEY_TYPE_CCA_CIPHER) in cca_apqns4type() 180 } else if (ktype == PKEY_TYPE_CCA_ECC) { in cca_apqns4type() 195 __func__, (int)ktype); in cca_apqns4type()
|
H A D | pkey_ep11.c | 143 static int ep11_apqns4type(enum pkey_key_type ktype, in ep11_apqns4type() argument 152 if (ktype == PKEY_TYPE_EP11 || in ep11_apqns4type() 153 ktype == PKEY_TYPE_EP11_AES || in ep11_apqns4type() 154 ktype == PKEY_TYPE_EP11_ECC) { in ep11_apqns4type() 168 __func__, (int)ktype); in ep11_apqns4type()
|
H A D | pkey_base.h | 182 int (*apqns_for_keytype)(enum pkey_key_type ktype, 222 int pkey_handler_apqns_for_keytype(enum pkey_key_type ktype,
|
/linux/Documentation/core-api/ |
H A D | kobject.rst | 32 - A ktype is the type of object that embeds a kobject. Every structure 33 that embeds a kobject needs a corresponding ktype. The ktype controls 36 - A kset is a group of kobjects. These kobjects can be of the same ktype 121 void kobject_init(struct kobject *kobj, const struct kobj_type *ktype); 123 The ktype is required for a kobject to be created properly, as every kobject 159 int kobject_init_and_add(struct kobject *kobj, const struct kobj_type *ktype, 296 instead, it is associated with the ktype. So let us introduce struct 319 automatically created for any kobject that is registered with this ktype. 326 each other. There is no restriction that they be of the same ktype, but be
|
/linux/drivers/infiniband/ulp/rtrs/ |
H A D | rtrs-srv-sysfs.c | 24 static struct kobj_type ktype = { variable 276 err = kobject_init_and_add(&srv_path->kobj, &ktype, srv->kobj_paths, in rtrs_srv_create_path_files()
|
/linux/drivers/media/rc/ |
H A D | imon.c | 1527 unsigned char *buf, u8 ktype) in imon_parse_press_type() argument 1549 else if (ktype == IMON_KEY_MCE) { in imon_parse_press_type() 1585 u8 ktype; in imon_incoming_packet() local 1594 ktype = IMON_KEY_PANEL; in imon_incoming_packet() 1600 ktype = IMON_KEY_IMON; in imon_incoming_packet() 1602 ktype = IMON_KEY_MCE; in imon_incoming_packet() 1605 ktype = IMON_KEY_IMON; in imon_incoming_packet() 1653 press_type = imon_parse_press_type(ictx, buf, ktype); in imon_incoming_packet() 1657 if (ktype != IMON_KEY_PANEL) { in imon_incoming_packet()
|
/linux/drivers/net/wireless/ath/carl9170/ |
H A D | mac.c | 471 const u8 ktype, const u8 keyidx, const u8 *keydata, in carl9170_upload_key() argument 482 key.type = cpu_to_le16(ktype); in carl9170_upload_key()
|
H A D | main.c | 1165 u8 ktype; in carl9170_op_set_key() local 1194 ktype = AR9170_ENC_ALG_WEP64; in carl9170_op_set_key() 1197 ktype = AR9170_ENC_ALG_WEP128; in carl9170_op_set_key() 1200 ktype = AR9170_ENC_ALG_TKIP; in carl9170_op_set_key() 1203 ktype = AR9170_ENC_ALG_AESCCMP; in carl9170_op_set_key() 1232 ktype, 0, key->key, in carl9170_op_set_key() 1239 NULL, ktype, 1, in carl9170_op_set_key()
|
/linux/include/linux/ceph/ |
H A D | decode.h | 174 #define ceph_decode_skip_map(p, end, ktype, vtype, bad) \ argument 180 ceph_decode_skip_##ktype(p, end, bad); \
|
/linux/fs/ubifs/ |
H A D | sysfs.c | 88 .kobj = {.ktype = &ubifs_ktype},
|
/linux/fs/ceph/ |
H A D | mdsmap.c | 75 #define __decode_and_drop_map(p, end, ktype, vtype, bad) \ argument 80 need = (sizeof(ktype) + sizeof(vtype)) * n; \
|
/linux/fs/ocfs2/cluster/ |
H A D | masklog.c | 153 .kobj = {.ktype = &mlog_ktype},
|
/linux/fs/erofs/ |
H A D | sysfs.c | 210 .kobj = {.ktype = &erofs_ktype},
|
/linux/drivers/base/ |
H A D | bus.c | 223 const struct kobj_type *ktype = get_ktype(kobj); in bus_uevent_filter() local 225 if (ktype == &bus_ktype) in bus_uevent_filter() 877 bus_kobj->ktype = &bus_ktype; in bus_register()
|
/linux/fs/nfs/ |
H A D | sysfs.c | 56 nfs_kset->kobj.ktype = &nfs_kset_type; in nfs_sysfs_init()
|