win-pvdrivers

changeset 87:70258b4c8380

xennet: clean up warnings
author Andy Grover <andy.grover@oracle.com>
date Wed Jan 02 10:43:25 2008 -0800 (2008-01-02)
parents 58f32e252d01
children 3a9c28d5a006
files xennet/xennet.c
line diff
     1.1 --- a/xennet/xennet.c	Wed Jan 02 15:22:01 2008 +1100
     1.2 +++ b/xennet/xennet.c	Wed Jan 02 10:43:25 2008 -0800
     1.3 @@ -170,7 +170,6 @@ XenNet_TxBufferGC(struct xennet_info *xi
     1.4    unsigned short id;
     1.5    PNDIS_PACKET pkt;
     1.6    PMDL pmdl;
     1.7 -  int notify;
     1.8  
     1.9    ASSERT(xi->connected);
    1.10  
    1.11 @@ -217,14 +216,7 @@ XenNet_TxBufferGC(struct xennet_info *xi
    1.12        prod + ((xi->tx.sring->req_prod - prod) >> 1) + 1;
    1.13      KeMemoryBarrier();
    1.14    } while ((cons == prod) && (prod != xi->tx.sring->rsp_prod));
    1.15 -/*
    1.16 -  RING_PUSH_REQUESTS_AND_CHECK_NOTIFY(&xi->tx, notify);
    1.17 -  if (notify)
    1.18 -  {
    1.19 -    xi->XenInterface.EvtChn_Notify(xi->XenInterface.InterfaceHeader.Context,
    1.20 -      xi->event_channel);
    1.21 -  }
    1.22 -*/
    1.23 +
    1.24    /* if queued packets, send them now?
    1.25    network_maybe_wake_tx(dev); */
    1.26  
    1.27 @@ -401,7 +393,7 @@ XenNet_Interrupt(
    1.28  
    1.29  //  KdPrint((__DRIVER_NAME " --> " __FUNCTION__ "\n"));
    1.30  
    1.31 -  KeAcquireSpinLock(xi->Lock, &OldIrql);
    1.32 +  KeAcquireSpinLock(&xi->Lock, &OldIrql);
    1.33  
    1.34    //KdPrint((__DRIVER_NAME "     ***XenNet Interrupt***\n"));  
    1.35  
    1.36 @@ -411,7 +403,7 @@ XenNet_Interrupt(
    1.37      XenNet_RxBufferCheck(xi);
    1.38    }
    1.39  
    1.40 -  KeReleaseSpinLock(xi->Lock, OldIrql);
    1.41 +  KeReleaseSpinLock(&xi->Lock, OldIrql);
    1.42  
    1.43  //  KdPrint((__DRIVER_NAME " <-- " __FUNCTION__ "\n"));
    1.44  
    1.45 @@ -614,7 +606,6 @@ XenNet_Init(
    1.46    struct xennet_info *xi = NULL;
    1.47    ULONG length;
    1.48    WDF_OBJECT_ATTRIBUTES wdf_attrs;
    1.49 -  char *msg;
    1.50    char *Value;
    1.51    char TmpPath[128];
    1.52  
    1.53 @@ -1228,11 +1219,11 @@ XenNet_SendPackets(
    1.54    int notify;
    1.55    PMDL pmdl;
    1.56    UINT pkt_size;
    1.57 -  PKIRQL OldIrql;
    1.58 +  KIRQL OldIrql;
    1.59  
    1.60  //  KdPrint((__DRIVER_NAME " --> " __FUNCTION__ "\n"));
    1.61  
    1.62 -  KeAcquireSpinLock(xi->Lock, &OldIrql);
    1.63 +  KeAcquireSpinLock(&xi->Lock, &OldIrql);
    1.64  
    1.65    for (i = 0; i < NumberOfPackets; i++)
    1.66    {
    1.67 @@ -1281,7 +1272,7 @@ XenNet_SendPackets(
    1.68        xi->event_channel);
    1.69    }
    1.70  
    1.71 -  KeReleaseSpinLock(xi->Lock, OldIrql);
    1.72 +  KeReleaseSpinLock(&xi->Lock, OldIrql);
    1.73  
    1.74  //  KdPrint((__DRIVER_NAME " <-- " __FUNCTION__ "\n"));
    1.75  }
    1.76 @@ -1307,7 +1298,8 @@ XenNet_Shutdown(
    1.77    IN NDIS_HANDLE MiniportAdapterContext
    1.78    )
    1.79  {
    1.80 -  struct xennet_info *xi = MiniportAdapterContext;
    1.81 +  //struct xennet_info *xi = MiniportAdapterContext;
    1.82 +  UNREFERENCED_PARAMETER(MiniportAdapterContext);
    1.83  
    1.84    // I think all we are supposed to do here is reset the adapter, which for us might be nothing...
    1.85