ISR's are random events that preempt your scheduler.
Deferred Service Routines run in the same thread as your scheduler.
It's excruciatingly hard to write (correct) code that can be interrupted and have it's internals monkeyed with at any clock cycle.
Thus the ISR/DSR handoff is a way of sequencing events into a manner the scheduler can handle sanely.
Most ISR's are written to be preemptible, it ack the interrupt and enable interrupts. Thus the chance of losing an event is very small.
The larger your isr the more you're into the realm of "excruciatingly hard to write (correct) code".
Your scheduler may be very simple... eg. only one thread as you described above, but my point applies.
ISR's are random events that preempt your scheduler.
Deferred Service Routines run in the same thread as your scheduler.
It's excruciatingly hard to write (correct) code that can be interrupted and have it's internals monkeyed with at any clock cycle.
Thus the ISR/DSR handoff is a way of sequencing events into a manner the scheduler can handle sanely.
Most ISR's are written to be preemptible, it ack the interrupt and enable interrupts. Thus the chance of losing an event is very small.
The larger your isr the more you're into the realm of "excruciatingly hard to write (correct) code".
Your scheduler may be very simple... eg. only one thread as you described above, but my point applies.