Re: IoCancelIrp and TDI



I don't think that really supporting serial timeouts over the (potentially
slow) Internet link is a good idea. Maybe it is a better idea to fake them.

--
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
maxim@xxxxxxxxxxxxxxxx
http://www.storagecraft.com

"David G" <DavidG@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:87234349-97C3-4584-B749-B36E03670C1C@xxxxxxxxxxxxxxxx
> I asked for help on 1/18/06 but no one responded. Did I post incorrectly?
> Has anyone used TDI and IoCancelIrp? How would I go about gettin a hold of a
> Microsoft engineer to look at this issue? Here is the post from 1/18/06:
>
> I'm developing on a Windows XP machine using the latest DDK.
>
> Hi, I've written a com port redirector that redirects com port data over the
> internet to a com port device server. I'm testing with Tera Term, a terminal
> application, and when it opens the com port it sends a timeout of 500
> milliseconds. Then I send a large file to the com port via Tera Term. As
> I'm streaming the data over the network, eventually the com port device
> server at the other end of the network cannot process the data as quickly and
> sends a small TCP window size in the the ACK packet. This stalls the writes
> for a while. Since Tera Term requested a timeout of 500 milliseconds, my
> timer expires and I cancel the Write IRP sent from Tera Term. I then call,
> from the timer expiration thread, IoCancelIrp on the Write IRP that was sent
> down to TDI. This causes my completion routine to fire with a Status of
> STATUS_CANCELLED.
>
> Now every IoCallDriver call to TDI gives me an error status of
> STATUS_INVALID_DEVICE_STATE (which is 0xC0000184). A network trace reveals
> that the PC sends an ACK with the RESET flag set in the TCP packet to the Com
> Port Device Server.
>
> Is there anyway to resurrect the TCP session without closing the current
> session down and opening another one?
>
> Thanks!
>

.



Relevant Pages

  • Re: rs232 -help!
    ... Okay, I never really found out how to set the comm timeout, however I got it ... I can read the port and the Read functon ... rs232 port asides from using the SerialWnd class.... ... posts from everyone, and then I read over the rs232 documentation, and then I ...
    (microsoft.public.vc.language)
  • Problem with USB thumbdrive using 5.3-BETA7 [resend].
    ... scbus0 on ata0 bus 0: ... port 1 addr 0 should never happen! ... umass0: BBB bulk-in clear stall failed, TIMEOUT ...
    (freebsd-current)
  • Problem using USB thumbdrive using 5.3-BETA6.
    ... scbus0 on ata0 bus 0: ... port 1 addr 0 should never happen! ... umass0: BBB bulk-in clear stall failed, TIMEOUT ...
    (freebsd-current)
  • Re: rs232 -help!
    ... I don't know the details of your CSerialWnd class, so I can only add some general comments. ... Usually you should not open the port, initialize it and close it again in each and every message sent to a window. ... Often serial ports signal each byte they are receiving, or or groups of bytes when there is some delay between them. ... This timeout should be large enough for the sender to fetch and transmit the next byte. ...
    (microsoft.public.vc.language)
  • Re: Newbie Issues (networking w/ FreeBSD)
    ... > in and doubled the timeout, and after a long wait (I didnt check the ... > but it is the same if I use telnet (or any other network service). ... of course the final port is the uplink. ... Assuming basic connectivity, many application timeout issues in Unix ...
    (freebsd-questions)