From 0385a00a60b4f5a247fa9f4ba6b5850b00191aa2 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Fri, 8 Aug 2014 12:44:44 -0600 Subject: [PATCH] Move signal-related files from sched/ to sched/signal --- sched/Makefile | 7 ++----- sched/group_leave.c | 2 +- sched/group_signal.c | 2 +- sched/mqueue/Make.defs | 2 +- sched/mqueue/mq_descreate.c | 2 +- sched/mqueue/mq_sndinternal.c | 2 +- sched/os_start.c | 2 +- sched/pthread_condtimedwait.c | 2 +- sched/{ => signal}/sig_action.c | 2 +- sched/{ => signal}/sig_allocatependingsigaction.c | 2 +- sched/{ => signal}/sig_cleanup.c | 2 +- sched/{ => signal}/sig_deliver.c | 2 +- sched/{ => signal}/sig_dispatch.c | 2 +- sched/{ => signal}/sig_findaction.c | 2 +- sched/{ => signal}/sig_initialize.c | 2 +- sched/{ => signal}/sig_kill.c | 2 +- sched/{ => signal}/sig_lowest.c | 2 +- sched/{ => signal}/sig_mqnotempty.c | 2 +- sched/{pause.c => signal/sig_pause.c} | 0 sched/{ => signal}/sig_pending.c | 2 +- sched/{ => signal}/sig_procmask.c | 2 +- sched/{ => signal}/sig_queue.c | 2 +- sched/{ => signal}/sig_releasependingsigaction.c | 2 +- sched/{ => signal}/sig_releasependingsignal.c | 2 +- sched/{ => signal}/sig_removependingsignal.c | 2 +- sched/{ => signal}/sig_suspend.c | 2 +- sched/{ => signal}/sig_timedwait.c | 2 +- sched/{ => signal}/sig_unmaskpendingsignal.c | 2 +- sched/{ => signal}/sig_waitinfo.c | 0 sched/{sig_internal.h => signal/signal.h} | 10 +++++----- sched/task_exit.c | 2 +- sched/task_exithook.c | 2 +- sched/task_restart.c | 2 +- sched/task_terminate.c | 2 +- sched/timer_settime.c | 2 +- 35 files changed, 38 insertions(+), 41 deletions(-) rename sched/{ => signal}/sig_action.c (99%) rename sched/{ => signal}/sig_allocatependingsigaction.c (99%) rename sched/{ => signal}/sig_cleanup.c (99%) rename sched/{ => signal}/sig_deliver.c (99%) rename sched/{ => signal}/sig_dispatch.c (99%) rename sched/{ => signal}/sig_findaction.c (99%) rename sched/{ => signal}/sig_initialize.c (99%) rename sched/{ => signal}/sig_kill.c (99%) rename sched/{ => signal}/sig_lowest.c (99%) rename sched/{ => signal}/sig_mqnotempty.c (99%) rename sched/{pause.c => signal/sig_pause.c} (100%) rename sched/{ => signal}/sig_pending.c (99%) rename sched/{ => signal}/sig_procmask.c (99%) rename sched/{ => signal}/sig_queue.c (99%) rename sched/{ => signal}/sig_releasependingsigaction.c (99%) rename sched/{ => signal}/sig_releasependingsignal.c (99%) rename sched/{ => signal}/sig_removependingsignal.c (99%) rename sched/{ => signal}/sig_suspend.c (99%) rename sched/{ => signal}/sig_timedwait.c (99%) rename sched/{ => signal}/sig_unmaskpendingsignal.c (99%) rename sched/{ => signal}/sig_waitinfo.c (100%) rename sched/{sig_internal.h => signal/signal.h} (97%) diff --git a/sched/Makefile b/sched/Makefile index cfaf96f16c..3030f3ab5f 100644 --- a/sched/Makefile +++ b/sched/Makefile @@ -183,20 +183,17 @@ endif IRQ_SRCS = irq_initialize.c irq_attach.c irq_dispatch.c irq_unexpectedisr.c +include signal/Make.defs include mqueue/Make.defs CSRCS = $(MISC_SRCS) $(TSK_SRCS) $(GRP_SRCS) $(SCHED_SRCS) $(WDOG_SRCS) CSRCS += $(TIME_SRCS) $(SEM_SRCS) $(TIMER_SRCS) $(PGFILL_SRCS) -CSRCS += $(IRQ_SRCS) $(CLOCK_SRCS) $(MQUEUE_SRCS) +CSRCS += $(IRQ_SRCS) $(CLOCK_SRCS) $(MQUEUE_SRCS) $(SIGNAL_SRCS) ifneq ($(CONFIG_DISABLE_PTHREAD),y) CSRCS += $(PTHREAD_SRCS) endif -ifneq ($(CONFIG_DISABLE_SIGNALS),y) -CSRCS += $(SIGNAL_SRCS) -endif - ifneq ($(CONFIG_DISABLE_ENVIRON),y) CSRCS += $(ENV_SRCS) endif diff --git a/sched/group_leave.c b/sched/group_leave.c index 9f672573cc..71eded8b10 100644 --- a/sched/group_leave.c +++ b/sched/group_leave.c @@ -49,7 +49,7 @@ #include #include "env_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" #include "pthread_internal.h" #include "mqueue/mqueue.h" #include "group_internal.h" diff --git a/sched/group_signal.c b/sched/group_signal.c index e46b190fde..c158bc89ea 100644 --- a/sched/group_signal.c +++ b/sched/group_signal.c @@ -47,7 +47,7 @@ #include "os_internal.h" #include "group_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" #if defined(HAVE_TASK_GROUP) && !defined(CONFIG_DISABLE_SIGNALS) diff --git a/sched/mqueue/Make.defs b/sched/mqueue/Make.defs index 55952862c2..1dc67e3567 100644 --- a/sched/mqueue/Make.defs +++ b/sched/mqueue/Make.defs @@ -44,7 +44,7 @@ ifneq ($(CONFIG_DISABLE_SIGNALS),y) MQUEUE_SRCS += mq_waitirq.c mq_notify.c endif -# Include mq build support +# Include mqueue build support DEPPATH += --dep-path mqueue VPATH += :mqueue diff --git a/sched/mqueue/mq_descreate.c b/sched/mqueue/mq_descreate.c index 7043bf0558..b227147912 100644 --- a/sched/mqueue/mq_descreate.c +++ b/sched/mqueue/mq_descreate.c @@ -52,7 +52,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" #include "mqueue/mqueue.h" diff --git a/sched/mqueue/mq_sndinternal.c b/sched/mqueue/mq_sndinternal.c index 08764f0d85..270f5ab7ab 100644 --- a/sched/mqueue/mq_sndinternal.c +++ b/sched/mqueue/mq_sndinternal.c @@ -53,7 +53,7 @@ #include "os_internal.h" #ifndef CONFIG_DISABLE_SIGNALS -# include "sig_internal.h" +# include "signal/signal.h" #endif #include "mqueue/mqueue.h" diff --git a/sched/os_start.c b/sched/os_start.c index c930e4bb55..9963cc3a1a 100644 --- a/sched/os_start.c +++ b/sched/os_start.c @@ -52,7 +52,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" #include "wd_internal.h" #include "sem_internal.h" #ifndef CONFIG_DISABLE_MQUEUE diff --git a/sched/pthread_condtimedwait.c b/sched/pthread_condtimedwait.c index 37534dacfe..0a53918b89 100644 --- a/sched/pthread_condtimedwait.c +++ b/sched/pthread_condtimedwait.c @@ -53,7 +53,7 @@ #include "os_internal.h" #include "pthread_internal.h" #include "clock_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /**************************************************************************** * Definitions diff --git a/sched/sig_action.c b/sched/signal/sig_action.c similarity index 99% rename from sched/sig_action.c rename to sched/signal/sig_action.c index 049a85823f..bd17e4f9f4 100644 --- a/sched/sig_action.c +++ b/sched/signal/sig_action.c @@ -47,7 +47,7 @@ #include "os_internal.h" #include "group_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /**************************************************************************** * Definitions diff --git a/sched/sig_allocatependingsigaction.c b/sched/signal/sig_allocatependingsigaction.c similarity index 99% rename from sched/sig_allocatependingsigaction.c rename to sched/signal/sig_allocatependingsigaction.c index 15d6470cae..fa8236ee8e 100644 --- a/sched/sig_allocatependingsigaction.c +++ b/sched/signal/sig_allocatependingsigaction.c @@ -44,7 +44,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /************************************************************************ * Definitions diff --git a/sched/sig_cleanup.c b/sched/signal/sig_cleanup.c similarity index 99% rename from sched/sig_cleanup.c rename to sched/signal/sig_cleanup.c index 46b3cb584c..535c6273a2 100644 --- a/sched/sig_cleanup.c +++ b/sched/signal/sig_cleanup.c @@ -41,7 +41,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /************************************************************************ * Definitions diff --git a/sched/sig_deliver.c b/sched/signal/sig_deliver.c similarity index 99% rename from sched/sig_deliver.c rename to sched/signal/sig_deliver.c index d3a7afc177..6e40db1790 100644 --- a/sched/sig_deliver.c +++ b/sched/signal/sig_deliver.c @@ -49,7 +49,7 @@ #include "os_internal.h" #include "sem_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /**************************************************************************** * Definitions diff --git a/sched/sig_dispatch.c b/sched/signal/sig_dispatch.c similarity index 99% rename from sched/sig_dispatch.c rename to sched/signal/sig_dispatch.c index f985778853..6cada00af9 100644 --- a/sched/sig_dispatch.c +++ b/sched/signal/sig_dispatch.c @@ -51,7 +51,7 @@ #include "os_internal.h" #include "group_internal.h" #include "sem_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" #include "mqueue/mqueue.h" /**************************************************************************** diff --git a/sched/sig_findaction.c b/sched/signal/sig_findaction.c similarity index 99% rename from sched/sig_findaction.c rename to sched/signal/sig_findaction.c index b701d3232e..be81496989 100644 --- a/sched/sig_findaction.c +++ b/sched/signal/sig_findaction.c @@ -38,7 +38,7 @@ ************************************************************************/ #include -#include "sig_internal.h" +#include "signal/signal.h" /************************************************************************ * Definitions diff --git a/sched/sig_initialize.c b/sched/signal/sig_initialize.c similarity index 99% rename from sched/sig_initialize.c rename to sched/signal/sig_initialize.c index 966d818a16..cd76c67951 100644 --- a/sched/sig_initialize.c +++ b/sched/signal/sig_initialize.c @@ -44,7 +44,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /************************************************************************ * Definitions diff --git a/sched/sig_kill.c b/sched/signal/sig_kill.c similarity index 99% rename from sched/sig_kill.c rename to sched/signal/sig_kill.c index 90ac918f31..e9d110b618 100644 --- a/sched/sig_kill.c +++ b/sched/signal/sig_kill.c @@ -45,7 +45,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /************************************************************************ * Global Functions diff --git a/sched/sig_lowest.c b/sched/signal/sig_lowest.c similarity index 99% rename from sched/sig_lowest.c rename to sched/signal/sig_lowest.c index f5654eb478..c84d7bfee0 100644 --- a/sched/sig_lowest.c +++ b/sched/signal/sig_lowest.c @@ -41,7 +41,7 @@ #include -#include "sig_internal.h" +#include "signal/signal.h" /************************************************************************ * Definitions diff --git a/sched/sig_mqnotempty.c b/sched/signal/sig_mqnotempty.c similarity index 99% rename from sched/sig_mqnotempty.c rename to sched/signal/sig_mqnotempty.c index 9bdfa9f146..3e7412ecdd 100644 --- a/sched/sig_mqnotempty.c +++ b/sched/signal/sig_mqnotempty.c @@ -46,7 +46,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /**************************************************************************** * Definitions diff --git a/sched/pause.c b/sched/signal/sig_pause.c similarity index 100% rename from sched/pause.c rename to sched/signal/sig_pause.c diff --git a/sched/sig_pending.c b/sched/signal/sig_pending.c similarity index 99% rename from sched/sig_pending.c rename to sched/signal/sig_pending.c index 98d7847673..9169604757 100644 --- a/sched/sig_pending.c +++ b/sched/signal/sig_pending.c @@ -43,7 +43,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /**************************************************************************** * Definitions diff --git a/sched/sig_procmask.c b/sched/signal/sig_procmask.c similarity index 99% rename from sched/sig_procmask.c rename to sched/signal/sig_procmask.c index aa738aa9a5..eb065af3ac 100644 --- a/sched/sig_procmask.c +++ b/sched/signal/sig_procmask.c @@ -50,7 +50,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /**************************************************************************** * Definitions diff --git a/sched/sig_queue.c b/sched/signal/sig_queue.c similarity index 99% rename from sched/sig_queue.c rename to sched/signal/sig_queue.c index 8174fe1faa..5156622503 100644 --- a/sched/sig_queue.c +++ b/sched/signal/sig_queue.c @@ -46,7 +46,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /**************************************************************************** * Definitions diff --git a/sched/sig_releasependingsigaction.c b/sched/signal/sig_releasependingsigaction.c similarity index 99% rename from sched/sig_releasependingsigaction.c rename to sched/signal/sig_releasependingsigaction.c index b0dab2ea90..e5fbf8a7ae 100644 --- a/sched/sig_releasependingsigaction.c +++ b/sched/signal/sig_releasependingsigaction.c @@ -42,7 +42,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /************************************************************************ * Definitions diff --git a/sched/sig_releasependingsignal.c b/sched/signal/sig_releasependingsignal.c similarity index 99% rename from sched/sig_releasependingsignal.c rename to sched/signal/sig_releasependingsignal.c index 41c2286eba..392b825b33 100644 --- a/sched/sig_releasependingsignal.c +++ b/sched/signal/sig_releasependingsignal.c @@ -51,7 +51,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /************************************************************************ * Definitions diff --git a/sched/sig_removependingsignal.c b/sched/signal/sig_removependingsignal.c similarity index 99% rename from sched/sig_removependingsignal.c rename to sched/signal/sig_removependingsignal.c index 656cf726aa..723ab3b743 100644 --- a/sched/sig_removependingsignal.c +++ b/sched/signal/sig_removependingsignal.c @@ -51,7 +51,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /************************************************************************ * Definitions diff --git a/sched/sig_suspend.c b/sched/signal/sig_suspend.c similarity index 99% rename from sched/sig_suspend.c rename to sched/signal/sig_suspend.c index 7342d124c3..d434761c8f 100644 --- a/sched/sig_suspend.c +++ b/sched/signal/sig_suspend.c @@ -47,7 +47,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /**************************************************************************** * Definitions diff --git a/sched/sig_timedwait.c b/sched/signal/sig_timedwait.c similarity index 99% rename from sched/sig_timedwait.c rename to sched/signal/sig_timedwait.c index 85b870642c..0e4635ad6c 100644 --- a/sched/sig_timedwait.c +++ b/sched/signal/sig_timedwait.c @@ -53,7 +53,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" #include "clock_internal.h" /**************************************************************************** diff --git a/sched/sig_unmaskpendingsignal.c b/sched/signal/sig_unmaskpendingsignal.c similarity index 99% rename from sched/sig_unmaskpendingsignal.c rename to sched/signal/sig_unmaskpendingsignal.c index c9326e3069..8d13b7a0fe 100644 --- a/sched/sig_unmaskpendingsignal.c +++ b/sched/signal/sig_unmaskpendingsignal.c @@ -42,7 +42,7 @@ #include #include "os_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /************************************************************************ * Definitions diff --git a/sched/sig_waitinfo.c b/sched/signal/sig_waitinfo.c similarity index 100% rename from sched/sig_waitinfo.c rename to sched/signal/sig_waitinfo.c diff --git a/sched/sig_internal.h b/sched/signal/signal.h similarity index 97% rename from sched/sig_internal.h rename to sched/signal/signal.h index c9f74491e8..2277dea1af 100644 --- a/sched/sig_internal.h +++ b/sched/signal/signal.h @@ -1,7 +1,7 @@ /**************************************************************************** - * sched/sig_internal.h + * sched/signal/signal.h * - * Copyright (C) 2007-2009, 2013 Gregory Nutt. All rights reserved. + * Copyright (C) 2007-2009, 2013-2014 Gregory Nutt. All rights reserved. * Author: Gregory Nutt * * Redistribution and use in source and binary forms, with or without @@ -33,8 +33,8 @@ * ****************************************************************************/ -#ifndef __SCHED_SIG_INTERNAL_H -#define __SCHED_SIG_INTERNAL_H +#ifndef __SCHED_SIGNAL_SIGNAL_H +#define __SCHED_SIGNAL_SIGNAL_H /**************************************************************************** * Included Files @@ -198,4 +198,4 @@ void sig_releasependingsignal(FAR sigpendq_t *sigpend); FAR sigpendq_t *sig_removependingsignal(FAR struct tcb_s *stcb, int signo); void sig_unmaskpendingsignal(void); -#endif /* __SCHED_SIG_INTERNAL_H */ +#endif /* __SCHED_SIGNAL_SIGNAL_H */ diff --git a/sched/task_exit.c b/sched/task_exit.c index 9483f65fd7..4bcdc189c5 100644 --- a/sched/task_exit.c +++ b/sched/task_exit.c @@ -42,7 +42,7 @@ #include #include "os_internal.h" #ifndef CONFIG_DISABLE_SIGNALS -# include "sig_internal.h" +# include "signal/signal.h" #endif /**************************************************************************** diff --git a/sched/task_exithook.c b/sched/task_exithook.c index e776bb1551..5074a99862 100644 --- a/sched/task_exithook.c +++ b/sched/task_exithook.c @@ -50,7 +50,7 @@ #include "os_internal.h" #include "group_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /**************************************************************************** * Pre-processor Definitions diff --git a/sched/task_restart.c b/sched/task_restart.c index e47c12822c..45346c6f17 100644 --- a/sched/task_restart.c +++ b/sched/task_restart.c @@ -47,7 +47,7 @@ #include "os_internal.h" #include "group_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" /**************************************************************************** * Definitions diff --git a/sched/task_terminate.c b/sched/task_terminate.c index 9d034d7195..11438d22d0 100644 --- a/sched/task_terminate.c +++ b/sched/task_terminate.c @@ -49,7 +49,7 @@ #include "os_internal.h" #ifndef CONFIG_DISABLE_SIGNALS -# include "sig_internal.h" +# include "signal/signal.h" #endif /**************************************************************************** diff --git a/sched/timer_settime.c b/sched/timer_settime.c index a09c818134..747a258348 100644 --- a/sched/timer_settime.c +++ b/sched/timer_settime.c @@ -46,7 +46,7 @@ #include "os_internal.h" #include "clock_internal.h" -#include "sig_internal.h" +#include "signal/signal.h" #include "timer_internal.h" #ifndef CONFIG_DISABLE_POSIX_TIMERS