Skip to content

Commit 049e3ba

Browse files
dcpleungcfriedt
authored andcommitted
kernel: add -ENOTSUP doc to arch_float_en-/dis-able()
Some architectures already returns -ENOTSUP when these functions are called. So add this return value to the API doc. Signed-off-by: Daniel Leung <[email protected]>
1 parent 482a150 commit 049e3ba

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

kernel/include/kernel_arch_interface.h

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -181,8 +181,9 @@ void arch_switch_to_main_thread(struct k_thread *main_thread, char *stack_ptr,
181181
* @note For ARM architecture, disabling floating point preservation may only
182182
* be requested for the current thread and cannot be requested in ISRs.
183183
*
184-
* @retval 0 On success.
185-
* @retval -EINVAL If the floating point disabling could not be performed.
184+
* @retval 0 On success.
185+
* @retval -EINVAL If the floating point disabling could not be performed.
186+
* @retval -ENOTSUP If the operation is not supported
186187
*/
187188
int arch_float_disable(struct k_thread *thread);
188189

@@ -192,16 +193,17 @@ int arch_float_disable(struct k_thread *thread);
192193
* The function is used to enable the preservation of floating
193194
* point context information for a particular thread.
194195
* This API depends on each architecture implimentation. If the architecture
195-
* does not support enableing, this API will always be failed.
196+
* does not support enabling, this API will always be failed.
196197
*
197198
* The @a options parameter indicates which floating point register sets will
198199
* be used by the specified thread. Currently it is used by x86 only.
199200
*
200201
* @param thread ID of thread.
201202
* @param options architecture dependent options
202203
*
203-
* @retval 0 On success.
204-
* @retval -EINVAL If the floating point enabling could not be performed.
204+
* @retval 0 On success.
205+
* @retval -EINVAL If the floating point enabling could not be performed.
206+
* @retval -ENOTSUP If the operation is not supported
205207
*/
206208
int arch_float_enable(struct k_thread *thread, unsigned int options);
207209
#endif /* CONFIG_FPU && CONFIG_FPU_SHARING */

0 commit comments

Comments
 (0)