diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2007-02-21 21:55:16 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2007-02-21 21:55:16 +0000 |
commit | efc2cf23a849f7be1d65c4cdd7767f88917c46a7 (patch) | |
tree | fbe3518a364d6b9d811e00f7201e082d50ead7e3 /nuttx/sched/sig_mqnotempty.c | |
parent | 94e5b72f50f3096b83fe50c7b57324a08e318f29 (diff) | |
download | px4-nuttx-efc2cf23a849f7be1d65c4cdd7767f88917c46a7.tar.gz px4-nuttx-efc2cf23a849f7be1d65c4cdd7767f88917c46a7.tar.bz2 px4-nuttx-efc2cf23a849f7be1d65c4cdd7767f88917c46a7.zip |
Progress toward clean SDCC compilation
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@18 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/sched/sig_mqnotempty.c')
-rw-r--r-- | nuttx/sched/sig_mqnotempty.c | 22 |
1 files changed, 17 insertions, 5 deletions
diff --git a/nuttx/sched/sig_mqnotempty.c b/nuttx/sched/sig_mqnotempty.c index cc5a064f6..ab395db2e 100644 --- a/nuttx/sched/sig_mqnotempty.c +++ b/nuttx/sched/sig_mqnotempty.c @@ -80,7 +80,11 @@ * ************************************************************/ +#ifdef CONFIG_CAN_PASS_STRUCTS int sig_mqnotempty (int pid, int signo, const union sigval value) +#else +int sig_mqnotempty (int pid, int signo, void *sival_ptr) +#endif { _TCB *stcb; siginfo_t info; @@ -91,14 +95,22 @@ int sig_mqnotempty (int pid, int signo, const union sigval value) /* Get the TCB of the receiving task */ stcb = sched_gettcb(pid); - dbg("sig_mqnotempty: TCB=0x%08x signo=%d value=%d\n", - stcb, signo, value.sival_int); + +#ifdef CONFIG_CAN_PASS_STRUCTS + dbg("TCB=%p signo=%d value=%d\n", stcb, signo, value.sival_int); +#else + dbg("TCB=%p signo=%d sival_ptr=%p\n", stcb, signo, sival_ptr); +#endif /* Create the siginfo structure */ - info.si_signo = signo; - info.si_code = SI_MESGQ; - info.si_value = value; + info.si_signo = signo; + info.si_code = SI_MESGQ; +#ifdef CONFIG_CAN_PASS_STRUCTS + info.si_value = value; +#else + info.si_value.sival_ptr = sival_ptr; +#endif /* Verify that we can perform the signalling operation */ |