|
@@ -343,28 +343,33 @@ PXENV_EXIT_t pxenv_undi_get_information ( struct s_PXENV_UNDI_GET_INFORMATION
|
343
|
343
|
|
344
|
344
|
/* PXENV_UNDI_GET_STATISTICS
|
345
|
345
|
*
|
346
|
|
- * Status: won't implement (would require driver API changes for no
|
347
|
|
- * real benefit)
|
|
346
|
+ * Status: working
|
348
|
347
|
*/
|
349
|
348
|
PXENV_EXIT_t pxenv_undi_get_statistics ( struct s_PXENV_UNDI_GET_STATISTICS
|
350
|
349
|
*undi_get_statistics ) {
|
351
|
350
|
DBG ( "PXENV_UNDI_GET_STATISTICS" );
|
352
|
351
|
|
353
|
|
- undi_get_statistics->Status = PXENV_STATUS_UNSUPPORTED;
|
354
|
|
- return PXENV_EXIT_FAILURE;
|
|
352
|
+ undi_get_statistics->XmtGoodFrames = pxe_netdev->stats.tx_count;
|
|
353
|
+ undi_get_statistics->RcvGoodFrames = pxe_netdev->stats.rx_count;
|
|
354
|
+ undi_get_statistics->RcvCRCErrors = 0;
|
|
355
|
+ undi_get_statistics->RcvResourceErrors = 0;
|
|
356
|
+
|
|
357
|
+ undi_get_statistics->Status = PXENV_STATUS_SUCCESS;
|
|
358
|
+ return PXENV_EXIT_SUCCESS;
|
355
|
359
|
}
|
356
|
360
|
|
357
|
361
|
/* PXENV_UNDI_CLEAR_STATISTICS
|
358
|
362
|
*
|
359
|
|
- * Status: won't implement (would require driver API changes for no
|
360
|
|
- * real benefit)
|
|
363
|
+ * Status: working
|
361
|
364
|
*/
|
362
|
365
|
PXENV_EXIT_t pxenv_undi_clear_statistics ( struct s_PXENV_UNDI_CLEAR_STATISTICS
|
363
|
366
|
*undi_clear_statistics ) {
|
364
|
367
|
DBG ( "PXENV_UNDI_CLEAR_STATISTICS" );
|
365
|
368
|
|
366
|
|
- undi_clear_statistics->Status = PXENV_STATUS_UNSUPPORTED;
|
367
|
|
- return PXENV_EXIT_FAILURE;
|
|
369
|
+ memset ( &pxe_netdev->stats, 0, sizeof ( pxe_netdev->stats ) );
|
|
370
|
+
|
|
371
|
+ undi_clear_statistics->Status = PXENV_STATUS_SUCCESS;
|
|
372
|
+ return PXENV_EXIT_SUCCESS;
|
368
|
373
|
}
|
369
|
374
|
|
370
|
375
|
/* PXENV_UNDI_INITIATE_DIAGS
|