rtems_event_receive and timeslicing
Efren Serra
efren.serra at Sun.COM
Tue Oct 23 16:07:57 UTC 2001
Brett,
I think should remove the RTEMS_TIMESLICE; it should not be used in real-time
systems. Also, I suppose the tasks are going to communicate; so, one should be
waiting on a queue and the other should append to the queue. This way neither
task hogs the CPU.
> I have a situation where I have two tasks running at the same priority (=
> 128). Both tasks were created with RTEMS_PREEMPT and
> RTEMS_TIMESLICE.
>
> One task is blocked, waiting on an event that is sent by an ISR. The other
> task is in an infinite loop as follows:
>
> for ( ;; )
> {
> ;
> }
>
> The task that is blocked on the rtems_event_receive() never appears to
> receive the event. However, if I place an
>
> rtems_task_suspend( RTEMS_SELF );
>
> call prior to the infinite loop in the 2nd task - the first task does
> receive the event.
>
> I won't have this task construct in the near future as I implement more
> functionality, but I would like to understand if the blocked task should run
> under this situation with timeslicing enabled. If I am missing some
> configuration options as well, I would like to know.
>
> I have
> #define CONFIGURE_TICKS_PER_TIMESLICE 50
> in my Initialization function file.
>
> I'm currently using the rtems-ss-20010816 snapshot.
>
> Thanks for any insight.
>
> Regards,
>
> Brett Swimley
More information about the users
mailing list