This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: Re: DSR question
- From: t dot michals at attbi dot com
- To: Iztok Zupet <iztok dot zupet at vsr dot si>
- Cc: eCos-discuss <ecos-discuss at sources dot redhat dot com>
- Date: Mon, 30 Sep 2002 18:28:31 +0000
- Subject: Re: [ECOS] Re: DSR question
Basicly the interrupt is level triggered. So when the
ISR services the interrupt it is masked and
acknowledged. The DSR unmasks it. The ISR is actually
simulated by a simple switch. The idea is to check the
code and verify the timming (number of ISRs) the
processor can handle. So, what happens, is when the
switch is triggered, the ISR is called, it mask's and
ack's the interrupt. Then the DSR gets called. So it
ping pongs back and forth. Also, during this process,
all threads are suspended due to processing the
interrupt and DSR(which is fine for this test). Also,
the timer is running for the RTC. So the timer is also
posting DSR requests. So, after tossing the switch off,
then the threads run. But now the DSR is hung.
After this condition occurs I trace the ISR and the ISR
is still be called by both the switch and RTC. But the
DSR is somehow blocked. Also, the counts dsr_count is
very high, could this cause some rollover condition,
between the RTC and my ISR. The RTC ISR just does the
ack, so not to miss ticks.
CYG_INSTRUMENT_CLOCK( ISR, 0, 0);
HAL_CLOCK_RESET( CYGNUM_HAL_INTERRUPT_RTC,
CYGNUM_KERNEL_COUNTERS_RTC_PERIOD );
Cyg_Interrupt::acknowledge_interrupt
(CYGNUM_HAL_INTERRUPT_RTC);
#if defined(CYGVAR_KERNEL_COUNTERS_CLOCK_DSR_LATENCY)
HAL_CLOCK_READ(&clock_dsr_start);
#endif
Could this cause a roll over issue somewhere? If not,
I'll keep poking. I'm trying to simplify the ISR and
thread, to reduce what could be happening. So the only
thread I have running is a while(1) { diag_printf
("hello");}
my ISR and the RTC.
Also, I'm still poking around the ack and mask of the
interrupt; this has to be where the problem is; but I
still confused why the DSR would be locked unless a race
condition could happening?
> On Mon, 2002-09-30 at 18:49, t.michals@attbi.com wrote:
> > The rest of the application is just in a while loop
> > printf out a hello message, to let me know the thread
> > has not locked up.
> >
> > Yes, some how the DSR is being locked but not all
> > threads.?
>
> Never saw a DSR being locked and I had ISR's running at 8kHz and 25kHz
> sustained rate.Could it be that a DSR locks itself waiting for some
> piece of HW ? That usually happens.
>
> Regards
> iz
>
>
--
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss