diff options
author | Benjamin Walsh <benjamin.walsh@windriver.com> | 2016-10-06 16:24:09 -0400 |
---|---|---|
committer | Benjamin Walsh <benjamin.walsh@windriver.com> | 2016-10-10 21:27:42 +0000 |
commit | 48efb384f8aa9382754a8c6766141b5e1b6d4ad8 (patch) | |
tree | 62fb2a3e03bec446ee7982970b174c155164d251 /kernel | |
parent | 1a5450bb8e0e1776618f4dcc035737cf91821299 (diff) |
unified: do not compile out _k_neg_eagain when !CONFIG_ERRNO
It is always needed by the kernel, since the return codes are now
errnos. CONFIG_ERRNO is the mechanism for having a per-thread errno, not
using errno values.
Change-Id: I4ed14896a342f4122793d91b13c41b4a6a74716d
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/unified/Makefile | 7 | ||||
-rw-r--r-- | kernel/unified/errno.c | 2 |
2 files changed, 3 insertions, 6 deletions
diff --git a/kernel/unified/Makefile b/kernel/unified/Makefile index ef8e0235a..4191ec855 100644 --- a/kernel/unified/Makefile +++ b/kernel/unified/Makefile @@ -16,13 +16,8 @@ lib-y += $(strip \ device.o \ thread_abort.o \ idle.o \ -) - -lib-y += $(strip \ sched.o \ mutex.o \ -) -lib-y += $(strip \ lifo.o \ fifo.o \ stack.o \ @@ -34,6 +29,7 @@ lib-y += $(strip \ event.o \ pipes.o \ offload.o \ + errno.o \ ) lib-$(CONFIG_INT_LATENCY_BENCHMARK) += int_latency_bench.o @@ -43,7 +39,6 @@ lib-$(CONFIG_KERNEL_EVENT_LOGGER) += event_logger.o lib-$(CONFIG_KERNEL_EVENT_LOGGER) += kernel_event_logger.o lib-$(CONFIG_RING_BUFFER) += ring_buffer.o lib-$(CONFIG_ATOMIC_OPERATIONS_C) += atomic_c.o -lib-$(CONFIG_ERRNO) += errno.o lib-$(CONFIG_NANO_WORKQUEUE) += work_q.o obj-y += legacy/ diff --git a/kernel/unified/errno.c b/kernel/unified/errno.c index 7eb902275..ea96e3449 100644 --- a/kernel/unified/errno.c +++ b/kernel/unified/errno.c @@ -32,7 +32,9 @@ const int _k_neg_eagain = -EAGAIN; #endif +#ifdef CONFIG_ERRNO int *_get_errno(void) { return &_nanokernel.current->errno_var; } +#endif |