How to open and initialize a virtual serial device of a pcmcia modem? Help !!!!!!

Hi,

I’m writing a Ndis-Wdm driver and my os is win2k. It works fine for
serial cable modems, but for pnp serial devices such as a pcmcia
modem, IoCallDriver always returns C0000001.

I have tried IoRegisterPlugPlayNotification function to get the
devicename as blow.
nts = IoRegisterPlugPlayNotification(
EventCategoryDeviceInterfaceChange,
PNPNOTIFY_DEVICE_INTERFACE_INCLUDE_EXISTING_INTERFACES,
(PVOID)&GUID_CLASS_COMPORT,
mainDriverObject,
PlugPlayCallback,
pAdapter,
&pAdapter->NotificationEntry);

Then I use IoGetDeviceObjectPointer to open the serial device of
pcmcia modem. that is successful.
I have replaced the os’s serial.sys with the serial.sys in DDK src for
easy tracing.
I find that when IoGetDeviceObjectPointer is called, the functions
such as SerialCreateOpen, SerialIoControl of serial.sys is called.
Then I user IoCallDriver to send IRP to the serial device. But it
always return C0000001, and none functions of serial.sys is called.
I don’t know why.

Please give some suggestion. Thank you very much!!!

Patrick Wen