|
jacus wrote:
I can't agree about the control lines. For me the devc-ser8250 doesn't
touch them at all.
Well I did say "suspect".
Quote:
I would like to:
- send XOFF,
- reset all UART channels (dedicated to chipset/hardware),
- turn off RTS and DTR line.
This doesn't sound too challenging. By Reset, did you mean, do a chip reset, or did you mean reset the UART parameters, eg. baud and parity.
I ask because a chip reset would likely turn RTS and DTR off.
Quote:
Can anybody tell me where should I put code responsible
for driver termination ?
I don't think I understand the question. Obviously you need to catch any important signals. For shutdown you probably want to catch SIGPWR.
The code could be in the signal handler, or you could just set a flag so that termination is handled outside of the handler. Of course, then you need to ensure that this outside code is executed.
Quote:
Do I need to catch SIGTERM signal ?
You might want to check the documentation on the various
signals you can catch. Catching a signal is one obvious way to deal with process termination.
Quote:
Can this be done in different way ?
If you know when you want the driver to stop, you could create a custom IOCTL call, or even a custom QNX message. |