From 1ff4fc699f01f0ad1359fad48b00c9d3be1b28b4 Mon Sep 17 00:00:00 2001 From: Glenn Elliott Date: Fri, 8 Mar 2013 01:37:46 -0500 Subject: Make github/staging complatible with -O2. Minor changes to test case code to enable compilation with 'gcc -O2' (gcc v4.7.2). --- tests/nesting.c | 6 +++--- tests/pcp.c | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'tests') diff --git a/tests/nesting.c b/tests/nesting.c index 7b30715..b294334 100644 --- a/tests/nesting.c +++ b/tests/nesting.c @@ -10,7 +10,7 @@ TESTCASE(lock_fmlp_nesting, PSN_EDF | GSN_EDF | P_FP, { int fd, od, od2; - SYSCALL( fd = open(".fmlp_locks", O_RDONLY | O_CREAT) ); + SYSCALL( fd = open(".fmlp_locks", O_RDONLY | O_CREAT, S_IRUSR) ); SYSCALL( sporadic_partitioned(10, 100, 0) ); SYSCALL( task_mode(LITMUS_RT_TASK) ); @@ -45,7 +45,7 @@ TESTCASE(lock_fmlp_srp_nesting, PSN_EDF | P_FP, { int fd, od, od2; - SYSCALL( fd = open(".fmlp_locks", O_RDONLY | O_CREAT) ); + SYSCALL( fd = open(".fmlp_locks", O_RDONLY | O_CREAT, S_IRUSR) ); SYSCALL( sporadic_partitioned(10, 100, 0) ); SYSCALL( task_mode(LITMUS_RT_TASK) ); @@ -80,7 +80,7 @@ TESTCASE(lock_srp_nesting, PSN_EDF | P_FP, { int fd, od, od2; - SYSCALL( fd = open(".fmlp_locks", O_RDONLY | O_CREAT) ); + SYSCALL( fd = open(".fmlp_locks", O_RDONLY | O_CREAT, S_IRUSR) ); SYSCALL( sporadic_partitioned(10, 100, 0) ); SYSCALL( task_mode(LITMUS_RT_TASK) ); diff --git a/tests/pcp.c b/tests/pcp.c index ff4259c..8e1204f 100644 --- a/tests/pcp.c +++ b/tests/pcp.c @@ -57,7 +57,7 @@ TESTCASE(pcp_inheritance, P_FP, params.cls = RT_CLASS_HARD; params.budget_policy = NO_ENFORCEMENT; - SYSCALL( fd = open(".pcp_locks", O_RDONLY | O_CREAT) ); + SYSCALL( fd = open(".pcp_locks", O_RDONLY | O_CREAT, S_IRUSR) ); child_lo = FORK_TASK( @@ -162,7 +162,7 @@ TESTCASE(srp_ceiling_blocking, P_FP | PSN_EDF, params.cls = RT_CLASS_HARD; params.budget_policy = NO_ENFORCEMENT; - SYSCALL( fd = open(".srp_locks", O_RDONLY | O_CREAT) ); + SYSCALL( fd = open(".srp_locks", O_RDONLY | O_CREAT, S_IRUSR) ); child_lo = FORK_TASK( -- cgit v1.2.2