Loading README.md +2 −2 Original line number Diff line number Diff line Data Scheduler ============== Norns Data Scheduler ==================== apply-headers.sh +2 −2 Original line number Diff line number Diff line Loading @@ -36,9 +36,9 @@ FILES=( "Makefile.am" "examples/Makefile.am" "examples/app.c" "include/libnorn.h" "include/norns.h" "lib/Makefile.am" "lib/norn.c" "lib/norns.c" "src/dloom.cpp" ) Loading examples/Makefile.am +1 −1 Original line number Diff line number Diff line Loading @@ -33,5 +33,5 @@ app_CPPFLAGS = \ -I$(top_srcdir)/include app_LDADD = \ $(top_builddir)/lib/libnorn.la $(top_builddir)/lib/libnorns.la examples/app.c +2 −2 Original line number Diff line number Diff line Loading @@ -21,12 +21,12 @@ * along with Data Scheduler. If not, see <http://www.gnu.org/licenses/>. */ #include <libnorn.h> #include <norns.h> #include <stdio.h> int main() { printf("Hello, World! I'm the app \n"); initialize(); norns_init(); return 0; } include/libnorn.h→include/norns.h +34 −10 Original line number Diff line number Diff line Loading @@ -21,17 +21,41 @@ * along with Data Scheduler. If not, see <http://www.gnu.org/licenses/>. */ #ifndef __NORN_LIB_H__ #define __NORN_LIB_H__ #ifndef __NORNS_LIB_H__ #define __NORNS_LIB_H__ 1 #ifdef __cplusplus extern "C" { #endif #include <features.h> #include <sys/types.h> void initialize(); __BEGIN_DECLS #ifdef __cplusplus }; // extern "C" #endif /* I/O task descriptor */ struct norns_iotd { int ni_tid; /* task identifier */ int ni_ibid; /* input backend identifier */ int ni_obid; /* output backend identifier */ int ni_type; /* type of task */ }; #endif /* __NORN_LIB_H__ */ /* */ enum { NORNS }; void norns_init() __THROW __nonnull ((1)); /* Enqueue an asynchronous I/O task */ int norns_transfer(struct norns_iotd* iotdp) __THROW __nonnull((1)); /* Try to cancel an asynchronous I/O task associated with iotdp */ ssize_t norns_cancel(struct norns_iotd* iotdp) __THROW __nonnull((1)); /* Retrieve return status associated with iotdp */ ssize_t norns_return(struct norns_iotd* iotdp) __THROW __nonnull((1)); /* Retrieve error status associated with iotdp */ int norns_error(struct norns_iotd* iotdp) __THROW __nonnull((1)); __END_DECLS #endif /* __NORNS_LIB_H__ */ Loading
README.md +2 −2 Original line number Diff line number Diff line Data Scheduler ============== Norns Data Scheduler ====================
apply-headers.sh +2 −2 Original line number Diff line number Diff line Loading @@ -36,9 +36,9 @@ FILES=( "Makefile.am" "examples/Makefile.am" "examples/app.c" "include/libnorn.h" "include/norns.h" "lib/Makefile.am" "lib/norn.c" "lib/norns.c" "src/dloom.cpp" ) Loading
examples/Makefile.am +1 −1 Original line number Diff line number Diff line Loading @@ -33,5 +33,5 @@ app_CPPFLAGS = \ -I$(top_srcdir)/include app_LDADD = \ $(top_builddir)/lib/libnorn.la $(top_builddir)/lib/libnorns.la
examples/app.c +2 −2 Original line number Diff line number Diff line Loading @@ -21,12 +21,12 @@ * along with Data Scheduler. If not, see <http://www.gnu.org/licenses/>. */ #include <libnorn.h> #include <norns.h> #include <stdio.h> int main() { printf("Hello, World! I'm the app \n"); initialize(); norns_init(); return 0; }
include/libnorn.h→include/norns.h +34 −10 Original line number Diff line number Diff line Loading @@ -21,17 +21,41 @@ * along with Data Scheduler. If not, see <http://www.gnu.org/licenses/>. */ #ifndef __NORN_LIB_H__ #define __NORN_LIB_H__ #ifndef __NORNS_LIB_H__ #define __NORNS_LIB_H__ 1 #ifdef __cplusplus extern "C" { #endif #include <features.h> #include <sys/types.h> void initialize(); __BEGIN_DECLS #ifdef __cplusplus }; // extern "C" #endif /* I/O task descriptor */ struct norns_iotd { int ni_tid; /* task identifier */ int ni_ibid; /* input backend identifier */ int ni_obid; /* output backend identifier */ int ni_type; /* type of task */ }; #endif /* __NORN_LIB_H__ */ /* */ enum { NORNS }; void norns_init() __THROW __nonnull ((1)); /* Enqueue an asynchronous I/O task */ int norns_transfer(struct norns_iotd* iotdp) __THROW __nonnull((1)); /* Try to cancel an asynchronous I/O task associated with iotdp */ ssize_t norns_cancel(struct norns_iotd* iotdp) __THROW __nonnull((1)); /* Retrieve return status associated with iotdp */ ssize_t norns_return(struct norns_iotd* iotdp) __THROW __nonnull((1)); /* Retrieve error status associated with iotdp */ int norns_error(struct norns_iotd* iotdp) __THROW __nonnull((1)); __END_DECLS #endif /* __NORNS_LIB_H__ */