Port-amiga archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: RTS/CTS flow control



Don Phillips <bsd%blkhole.resun.com@localhost> wrote:
> Does anybody know if RTS/CTS flow control has been fully implemented in
> the serial port (ser.c) and/or A2232 multi-port serial cards?  If it
> hasn't and the modem on the port is set for hardware flow control, it
> might explain some of the overruns that I'm seeing (silo overflows.)  I am
> aware of the options to change the size of the silos, and to defer the
> level 6 interrupts, but deferring the level 6 interrupts seems to have the
> unpleasant side effect of really messing up the clock.

Ok, one last time:

the only interupt which is  at Lev. 5 is the serial receive interupt.

The only thing it does is read the data byte and status bits from the 
hardware, as one 16bit read, and write them to a ringbuffer without looking
at them, as one 16bit write. Nothing more (this is why the NetBSD serial
driver performs better than the Commodore serial driver :-).

This should take something like, uh, interupt overhead + 5 microseconds
(guessed). You won't see any effect on the clock because of that; at 100Hz
clock interupt rate, a 5 microsecond, + 1us for register save/restore, jitter
won't be noticable.

On the other hand, the clock interupt does a lot of work in a BSD system, and
can very well mess up the serial reception, if the hardware can only buffer
one character (at 38400 bps: 3840 interupts/s, that is, 260us _absolute
maximum_ for higher level interupts or uninteruptible instructions, or
6500 cycles (on a A3000: 68030@25MHz). This isn't much. Even a 68060
cache push might be too much for this ;-)

Regards,
        -is



Home | Main Index | Thread Index | Old Index