最終更新:2015-10-26 (月) 16:24:55 (3105d)  

kset
Top / kset

a set of kobjects of a specific type, belonging to a specific subsystem.

定義

  • struct kset {
            struct list_head list;
            spinlock_t list_lock;
            struct kobject kobj;
            const struct kset_uevent_ops *uevent_ops;
    };

kset->kobj (kobject)

  • struct kobject {
            const char              *name;
            struct list_head        entry;
            struct kobject          *parent;
            struct kset             *kset;
            struct kobj_type        *ktype;
            struct kernfs_node      *sd;
            struct kref             kref;
    #ifdef CONFIG_DEBUG_KOBJECT_RELEASE
            struct delayed_work     release;
    #endif
            unsigned int state_initialized:1;
            unsigned int state_in_sysfs:1;
            unsigned int state_add_uevent_sent:1;
            unsigned int state_remove_uevent_sent:1;
            unsigned int uevent_suppress:1;
    };

設定する項目

  • メンバ説明
    char*kset->kobj.name名前
    kobjectkset->kobj.parent親kobject(指定しない場合はkobj->kset->kobj)
    kobj_type?kset->kobj.ktypeclass_ktype?とかdriver_ktype?kset_ktype?
    ksetkset->kobj.kset所属するkset
    kset_uevent_ops?kset.uevent_ops

関数

メモ