win-pvdrivers

changeset 83:449304b11e61

Fixed packet sizing error which could cause an ASSERT/BSoD
author James Harper <james.harper@bendigoit.com.au>
date Tue Jan 01 13:51:14 2008 +1100 (2008-01-01)
parents 5d116e9b87fa
children 9afa5fd5e5b2
files xennet/sources xennet/xennet.c
line diff
     1.1 --- a/xennet/sources	Mon Dec 31 23:35:05 2007 +1100
     1.2 +++ b/xennet/sources	Tue Jan 01 13:51:14 2008 +1100
     1.3 @@ -1,7 +1,7 @@
     1.4  TARGETNAME=XENNET
     1.5  TARGETTYPE=DRIVER
     1.6  TARGETPATH=..\Target\$(DDK_TARGET_OS)
     1.7 -VERSION=0.5.0.31
     1.8 +VERSION=0.5.0.34
     1.9  KMDF_VERSION=1
    1.10  MSC_WARNING_LEVEL=/W4
    1.11  INF_NAME=xennet
     2.1 --- a/xennet/xennet.c	Mon Dec 31 23:35:05 2007 +1100
     2.2 +++ b/xennet/xennet.c	Tue Jan 01 13:51:14 2008 +1100
     2.3 @@ -825,7 +825,9 @@ XenNet_QueryInformation(
     2.4        temp_data = XN_DATA_SIZE;
     2.5        break;
     2.6      case OID_GEN_MAXIMUM_FRAME_SIZE:
     2.7 -      temp_data = XN_MAX_PKT_SIZE;
     2.8 +      // According to the specs, OID_GEN_MAXIMUM_FRAME_SIZE does not include the header, so
     2.9 +      // it is XN_DATA_SIZE not XN_MAX_PKT_SIZE
    2.10 +      temp_data = XN_DATA_SIZE; // XN_MAX_PKT_SIZE;
    2.11        break;
    2.12      case OID_GEN_LINK_SPEED:
    2.13        temp_data = 10000000; /* 1Gb */
    2.14 @@ -836,7 +838,7 @@ XenNet_QueryInformation(
    2.15        break;
    2.16      case OID_GEN_RECEIVE_BUFFER_SPACE:
    2.17        /* pkts times sizeof ring, maybe? */
    2.18 -      temp_data = XN_MAX_PKT_SIZE * NET_TX_RING_SIZE;
    2.19 +      temp_data = XN_MAX_PKT_SIZE * NET_RX_RING_SIZE;
    2.20        break;
    2.21      case OID_GEN_TRANSMIT_BLOCK_SIZE:
    2.22        temp_data = XN_MAX_PKT_SIZE;