summaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2015-07-20 20:20:54 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2015-07-20 20:20:54 +0000
commita3cdeecf0033919e3b5a79c17c19b5ac98719256 (patch)
tree92a930930f18a4f8ae897b1a69c39358137ce1e2 /src/include
parentbd34de9054cec794d96b0fde1eee9100e1d34215 (diff)
downloads6-a3cdeecf0033919e3b5a79c17c19b5ac98719256.tar.xz
- Add timeout-finish support and "down-readiness"
- LOTS of refactoring to make this work - Remove s6-notifywhenup - s6-supervise now rocks the casbah - rc for 2.2.0.0
Diffstat (limited to 'src/include')
-rw-r--r--src/include/s6/s6-supervise.h23
1 files changed, 14 insertions, 9 deletions
diff --git a/src/include/s6/s6-supervise.h b/src/include/s6/s6-supervise.h
index 2e9a3fa..dec0455 100644
--- a/src/include/s6/s6-supervise.h
+++ b/src/include/s6/s6-supervise.h
@@ -3,39 +3,44 @@
#ifndef S6_SUPERVISE_H
#define S6_SUPERVISE_H
+#include <sys/types.h>
#include <skalibs/tai.h>
#define S6_SUPERVISE_CTLDIR "supervise"
#define S6_SUPERVISE_EVENTDIR "event"
#define S6_SVSCAN_CTLDIR ".s6-svscan"
#define S6_SVSTATUS_FILENAME S6_SUPERVISE_CTLDIR "/status"
-#define S6_SUPERVISE_READY_FILENAME S6_SUPERVISE_CTLDIR "/ready"
-#define S6_SVSTATUS_SIZE 26
+#define S6_SVSTATUS_SIZE 35
extern int s6_svc_write (char const *, char const *, unsigned int) ;
+extern int s6_svc_writectl (char const *, char const *, char const *, unsigned int) ;
extern int s6_svc_main (int, char const *const *, char const *, char const *, char const *) ;
typedef struct s6_svstatus_s s6_svstatus_t, *s6_svstatus_t_ref ;
struct s6_svstatus_s
{
tain_t stamp ;
- unsigned int pid ;
- unsigned int flagwant : 1 ;
- unsigned int flagwantup : 1 ;
+ tain_t readystamp ;
+ pid_t pid ;
+ int wstat ;
unsigned int flagpaused : 1 ;
unsigned int flagfinishing : 1 ;
- unsigned int wstat ;
+ unsigned int flagwant : 1 ;
+ unsigned int flagwantup : 1 ;
+ unsigned int flagready : 1 ;
} ;
#define S6_SVSTATUS_ZERO \
{ \
.stamp = TAIN_ZERO, \
+ .readystamp = TAIN_ZERO, \
.pid = 0, \
- .flagwant = 0, \
- .flagwantup = 0, \
+ .wstat = 0, \
.flagpaused = 0, \
.flagfinishing = 0, \
- .wstat = 0 \
+ .flagwant = 1, \
+ .flagwantup = 1, \
+ .flagready = 1 \
}
extern void s6_svstatus_pack (char *, s6_svstatus_t const *) ;