PortServer port open fails with an EAGAIN.

I have a GPS receiver connected to a PortServer TS 3 M MEI Version 82000747_W1 02/16/2016. This GPS device continues to transmit data after it’s app sets
it up. If I kill the app the PortServer hangs and cannot be opened by the
app or anything else such as a terminal emulator like putty. The open returns
an EAGAIN error which is not an allowed error for an open call under Linux or POSIX.
I am running Ubuntu 18.04 which has kernel 4.15.0-45.

If the ASYNC data flow into the PortServer is stopped before I kill the app
then the port can be opened again. The only way to recover is a power cycle.
Using “reset” in the PortServer web page will not recover the device.

This is the data flow to and from the PortServer when it has failed as seen by
the drpd daemon:

Read 1 bytes from the Server.
0000: f0 .
Read 3 bytes from network device
0000: b1 0a 00 …
Write 3 bytes to Server
0000: b1 0a 00 …
Read 6 bytes from the Server.
0000: b1 0b 00 01 00 01 …
Read 1 bytes from the Server.
0000: f0 .

I have the same problem with a PortServer TS 4 that is connected to a
RAID box that also continually sends data. If I kill it’s app the
PortServer hangs. Again, only a power cycle will recover it.
Unloading and re-loading the device driver will not recover the PortServer.

Is there a way that the device driver can recover the PortServer? Any
special code that I could add?

I have compiled the device driver and have watched the data flow back
and forth between the driver and PortServer. It seems that the returned
data from above shows the problem. The data “b1 0b 00 01 00 01” has some
bits set to 1. When things work these are set to 0. This data is not
defined so I don’t know what this means. Is the firmware source code
available? Is there a particular command that I can issue that will recover
the port?