11 #include <minix/config.h>
12 #include <minix/com.h>
13 #include <minix/type.h>
14 #include <minix/const.h>
15 #include <minix/endpoint.h>
16 #include <minix/safecopies.h>
17 #include <minix/syslib.h>
18 #include <minix/sysutil.h>
22 * log2(CLICK_SIZE * TEST_PAGE_NUM) = CLICK_SHIFT + log2(TEST_PAGE_NUM)
24 #define TEST_PAGE_NUM 8
25 #define TEST_PAGE_SHIFT 15
27 #define BUF_SIZE (TEST_PAGE_NUM * CLICK_SIZE)
30 #define FIFO_REQUESTOR "/usr/src/test/safecopy/1fifo"
31 #define FIFO_GRANTOR "/usr/src/test/safecopy/2fifo"
33 #define FIFO_WAIT(fid) { \
35 if(read(fid, &a, sizeof(a)) != sizeof(a)) \
36 panic("FIFO_WAIT failed"); \
38 #define FIFO_NOTIFY(fid) { \
40 if(write(fid, &a, sizeof(a)) != sizeof(a)) \
41 panic("FIFO_NOTIFY failed"); \
46 # define dprint printf
48 # define dprint (void)