win-pvdrivers

view liblfds.6/src/single_dir_for_windows_kernel/freelist_get_and_set.c @ 1106:2d392ecdd366

Fix race is xenvbd causing 30 second freeze under high load
author James Harper <james.harper@bendigoit.com.au>
date Tue Nov 11 23:08:11 2014 +1100 (2014-11-11)
parents 6300617040e0
children
line source
1 #include "freelist_internal.h"
7 /****************************************************************************/
8 void *freelist_get_user_data_from_element( struct freelist_element *fe, void **user_data )
9 {
10 assert( fe != NULL );
11 // TRD : user_data can be NULL
13 if( user_data != NULL )
14 *user_data = fe->user_data;
16 return( fe->user_data );
17 }
23 /****************************************************************************/
24 void freelist_set_user_data_in_element( struct freelist_element *fe, void *user_data )
25 {
26 assert( fe != NULL );
27 // TRD : user_data can be NULL
29 fe->user_data = user_data;
31 return;
32 }