This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: cyg_flag_setbits() question


Hi,

I've two quick questions:


Is it save to call cyg_flag_setbits() from an IRQ or should i better use a
DSR?

So use a DSR.

Is there a save way to transmit information from IRQ to DSR? As far as i
know the DSR's are queue's, so i need to transmit maybe which was the IRQ
cause of the IRQ to the DSR's.

Later in the same page it says:


void
dsr_function(cyg_vector_t vector,
            cyg_ucount32 count,
            cyg_addrword_t data)
{
}

vector is the source of the interrupts which caused the DSR to
trigger.

You can also use data as a pointer to an information block if you
want.


Imagine i got two quick interrupts before dsr could be called. I know it from windows wdm, where i can transmit a value from every interrupt to the dpc routine. A pointer to a data array for both irq and dsr wouldn't do it. So i could write some kind of list, but it would need a protection like a spinlock or so. I'm not really happy with this....


Bye...


-- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]