Query about I/O Buffers of Serial Port Driver

Hello all,

I have a query on Serial Device Driver Development.

I am emulating a Serial Port Driver on Win 2K platform. I have a sample of a
similarly emulated driver on Win 95/98 platform.

On Win 95/98 Platform , a serial port driver has a routine called “Setup()”
which can be invoked through a VCOMM interface called
VCOMM_SetupComm(m_CommHandle, //
Setup this comm port,
&m_RLM_RxQueue[0], RLM_RxSize,
// …With this receive queue,
&m_RLM_TxQueue[0], RLM_TxSize);
// …And this transmit queue.

whereby the caller supplies the addresses AND sizes of the I/O Buffers to be
used, to the port driver.

From the documentation in DDK 2000 and the header file ntddser.h( Win 2000)
, I have understood as follows :

My understanding :

  1. I can use the structure SERIAL_QUEUE_SIZE in the
    IOCTL_SERIAL_SET_QUEUE_SIZE for passing the sizes of the
    I/O-buffers-to-be-used to the serial
    port driver.
  2. I do not see any possibility for passing the ADDRESSES of the
    buffers to the Port Driver. Hence on Win 2K, the Port Driver must be
    allocating the memory
    for the I/O buffers, instead of receiving them from the caller.

Please correct me if I am wrong in the above understanding.

Queries :

  1. The structure SERIAL_BASIC_SETTINGS in ntddser.h ( Win 2000) has two
    members RxFifo and TxFifo. What is their equivalent on Win 2000 ?
  2. Are these (RxFifo and TxFifo) by any chance the same as the
    addresses of the I/O Buffers being used by the “serial.sys”, the Serial Port
    Driver on Win 2000 ?

I appreciate any information in this context,
Regards,
Shail.


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

>VCOMM_SetupComm(m_CommHandle, //

Setup this comm port,
&m_RLM_RxQueue[0], RLM_RxSize,
// …With this receive queue,
&m_RLM_TxQueue[0], RLM_TxSize);
// …And this transmit queue.

whereby the caller supplies the addresses AND sizes of the I/O Buffers to be
used, to the port driver.

This a dirty MS way. Why the client application can have a direct
control to a drivers internal data structure. It exist read/Write
interface functions and the drivers writers can use a data
strcture for its own fifo, queue …

  1. I do not see any possibility for passing the ADDRESSES of the
    buffers to the Port Driver. Hence on Win 2K, the Port Driver must be
    allocating the memory
    for the I/O buffers, instead of receiving them from the caller.

Yes this is true and correct.

  1. The structure SERIAL_BASIC_SETTINGS in ntddser.h ( Win 2000) has two
    members RxFifo and TxFifo. What is their equivalent on Win 2000 ?

Use your head and make always your own data structures.

elli


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com