Lines Matching refs:be
6 A kernel object can be one of three classes of data:
20 All kernel objects must be placed in memory that is not accessible by
36 may be called to release any runtime-allocated buffers the object was using.
39 will be freed.
45 and can be located anywhere in the binary, or even declared on stacks. However,
47 not be located in any memory that user threads have direct access to.
49 In order for a static kernel object to be usable by a user thread via system
50 call APIs, several conditions must be met on how the kernel object is declared:
52 * The object must be declared as a top-level global at build time, such that it
56 in a special table of kernel object metadata. Kernel objects may be members
59 * Kernel objects must be located in memory reserved for the kernel. They
60 must not be located in any memory partitions that are user-accessible.
62 * Any memory reserved for a kernel object must be used exclusively for that
63 object. Kernel objects may not be members of a union data type.
65 Kernel objects that are found but do not meet the above conditions will not be
69 The debug output of the :ref:`gen_kobject_list.py` script may be useful when
71 information will be printed if the script is run with the ``--verbose`` flag,
77 Kernel objects may also be allocated at runtime if
79 :c:func:`k_object_alloc` API may be used to instantiate an object from
80 the calling thread's resource pool. Such allocations may be freed in two
84 object to be released.
87 permissions on it) the object will be automatically freed. User threads
109 of what may or may not be a valid kernel object, the address can be validated
115 be prevented. When a device struct is found, its API pointer is examined to
148 :c:macro:`K_INHERIT_PERMS` option, the child thread will be granted the
156 Access to them needs to be explicitly or implicitly granted. There are several
166 :c:func:`k_thread_access_grant` may also be used, which accepts an arbitrary
169 permission, or the object whose access is being granted, do not need to be
173 * Supervisor threads may declare a particular kernel object to be a public
176 untrusted or exploited code will then be able to access the object. Use
180 then the :c:macro:`K_THREAD_ACCESS_GRANT()` may be used to grant that thread
183 Once a thread has been granted access to an object, such access may be
190 not being tracked by the kernel will be no-ops. Doing the same from user mode
199 Most operations on kernel objects will fail if the object is considered to be
201 be performed first.
203 Some objects will be implicitly initialized at boot:
206 (such as :c:macro:`K_SEM_DEFINE` for semaphores) will be in an initialized
238 When implementing new kernel features or driver subsystems, it may be necessary
248 Instances of the new struct should now be tracked.
259 Driver instances of the new subsystem should now be tracked.