@@ -134,52 +134,6 @@ struct z_object_assignment {
134134 * @param obj Address of the kernel object
135135 */
136136void z_object_init (const void * obj );
137- #else
138- /* LCOV_EXCL_START */
139- #define K_THREAD_ACCESS_GRANT (thread , ...)
140-
141- /**
142- * @internal
143- */
144- static inline void z_object_init (const void * obj )
145- {
146- ARG_UNUSED (obj );
147- }
148-
149- /**
150- * @internal
151- */
152- static inline void z_impl_k_object_access_grant (const void * object ,
153- struct k_thread * thread )
154- {
155- ARG_UNUSED (object );
156- ARG_UNUSED (thread );
157- }
158-
159- /**
160- * @internal
161- */
162- static inline void k_object_access_revoke (const void * object ,
163- struct k_thread * thread )
164- {
165- ARG_UNUSED (object );
166- ARG_UNUSED (thread );
167- }
168-
169- /**
170- * @internal
171- */
172- static inline void z_impl_k_object_release (const void * object )
173- {
174- ARG_UNUSED (object );
175- }
176-
177- static inline void k_object_access_all_grant (const void * object )
178- {
179- ARG_UNUSED (object );
180- }
181- /* LCOV_EXCL_STOP */
182- #endif /* !CONFIG_USERSPACE */
183137
184138/**
185139 * Grant a thread access to a kernel object
@@ -236,6 +190,54 @@ __syscall void k_object_release(const void *object);
236190 */
237191void k_object_access_all_grant (const void * object );
238192
193+ #else
194+ /* LCOV_EXCL_START */
195+ #define K_THREAD_ACCESS_GRANT (thread , ...)
196+
197+ /**
198+ * @internal
199+ */
200+ static inline void z_object_init (const void * obj )
201+ {
202+ ARG_UNUSED (obj );
203+ }
204+
205+ /**
206+ * @internal
207+ */
208+ static inline void z_impl_k_object_access_grant (const void * object ,
209+ struct k_thread * thread )
210+ {
211+ ARG_UNUSED (object );
212+ ARG_UNUSED (thread );
213+ }
214+
215+ /**
216+ * @internal
217+ */
218+ static inline void k_object_access_revoke (const void * object ,
219+ struct k_thread * thread )
220+ {
221+ ARG_UNUSED (object );
222+ ARG_UNUSED (thread );
223+ }
224+
225+ /**
226+ * @internal
227+ */
228+ static inline void z_impl_k_object_release (const void * object )
229+ {
230+ ARG_UNUSED (object );
231+ }
232+
233+ static inline void k_object_access_all_grant (const void * object )
234+ {
235+ ARG_UNUSED (object );
236+ }
237+ /* LCOV_EXCL_STOP */
238+ #endif /* !CONFIG_USERSPACE */
239+
240+ #ifdef CONFIG_DYNAMIC_OBJECTS
239241/**
240242 * Allocate a kernel object of a designated type
241243 *
@@ -252,7 +254,6 @@ void k_object_access_all_grant(const void *object);
252254 */
253255__syscall void * k_object_alloc (enum k_objects otype );
254256
255- #ifdef CONFIG_DYNAMIC_OBJECTS
256257/**
257258 * Allocate memory and install as a generic kernel object
258259 *
@@ -310,6 +311,7 @@ static inline struct z_object *z_dynamic_object_create(size_t size)
310311 */
311312void k_object_free (void * obj );
312313#else
314+
313315/* LCOV_EXCL_START */
314316static inline void * z_impl_k_object_alloc (enum k_objects otype )
315317{
0 commit comments