Resource Manager for Serial Ports

Hi Friends,
I’m writing a resource manager to deal with some POSIX serial port
commands in a QNX 6.1 RTOS. Until now everything was ok and I’ve
implemented open(), close(), read(), write() and select() handling functions
in my resource manager.
But now I’m in trouble with tcsetattr() and tcgetattr(). I know that a
resource manager must handle devctl() of a client in order to receive or
send specific commands/data to this client (i.e. port speed, parity bit,
no.bits, etc).
My problem: no matters what values I set at the client’s side, using for
example cfsetispeed() to set the speed to 2400, 4800 or 9600, the value that
I get from dcmd inside my resource manager’s devctl() handler when the
client runs tcsetattr() is always the same: 804c7414.
Does anybody know how tcsetattr() and tcgetattr() are implemented in QNX
6.1 RTOS? Or how do they use devctl() to exchange data with a serial port
resource manager? if I could have the source code of them it would be

Best Regards,
Douglas Mota Dias / Brazil.