Linux Kernel
3.7.1
|
#include <linux/types.h>
#include <linux/list.h>
#include <linux/sysfs.h>
#include <linux/compiler.h>
#include <linux/spinlock.h>
#include <linux/kref.h>
#include <linux/kobject_ns.h>
#include <linux/kernel.h>
#include <linux/wait.h>
#include <linux/atomic.h>
Go to the source code of this file.
Data Structures | |
struct | kobject |
struct | kobj_type |
struct | kobj_uevent_env |
struct | kset_uevent_ops |
struct | kobj_attribute |
struct | kset |
Macros | |
#define | UEVENT_HELPER_PATH_LEN 256 |
#define | UEVENT_NUM_ENVP 32 /* number of env pointers */ |
#define | UEVENT_BUFFER_SIZE 2048 /* buffer for the variables */ |
Enumerations | |
enum | kobject_action { KOBJ_ADD, KOBJ_REMOVE, KOBJ_CHANGE, KOBJ_MOVE, KOBJ_ONLINE, KOBJ_OFFLINE, KOBJ_MAX } |
Variables | |
char | uevent_helper [] |
u64 | uevent_seqnum |
const char * | name |
struct kobject * | parent |
struct kobject const char * | fmt |
struct kobject const char struct kobj_type * | ktype |
struct sysfs_ops | kobj_sysfs_ops |
struct kobject * | kernel_kobj |
struct kobject * | mm_kobj |
struct kobject * | hypervisor_kobj |
struct kobject * | power_kobj |
struct kobject * | firmware_kobj |
static const char * | format |
enum kobject_action |
__printf | ( | 2 | , |
3 | |||
) |
__printf | ( | 3 | , |
4 | |||
) |
__printf | ( | 4 | , |
5 | |||
) |
|
read |
kobject_create - create a struct kobject dynamically
This function creates a kobject structure dynamically and sets it up to be a "dynamic" kobject with a default release function set up.
If the kobject was not able to be created, NULL will be returned. The kobject structure returned from here must be cleaned up with a call to kobject_put() and not kfree(), as kobject_init() has already been called on this structure.
kobject_init - initialize a kobject structure : pointer to the kobject to initialize : pointer to the ktype for this kobject.
This function will properly initialize a kobject such that it can then be passed to the kobject_add() call.
After this function is called, the kobject MUST be cleaned up by a call to kobject_put(), not by a call to kfree directly to ensure that all of the memory is cleaned up properly.
|
read |
int __must_check kset_register | ( | struct kset * | k | ) |
Definition at line 18 of file firmware.c.
Definition at line 16 of file hypervisor.c.
char uevent_helper[] |
Definition at line 32 of file kobject_uevent.c.
u64 uevent_seqnum |
Definition at line 31 of file kobject_uevent.c.