File tree Expand file tree Collapse file tree 2 files changed +22
-4
lines changed
Expand file tree Collapse file tree 2 files changed +22
-4
lines changed Original file line number Diff line number Diff line change @@ -864,10 +864,15 @@ DMABuffer_free
864864
865865 if (munlock (buffer -> map , buffer -> length ) != 0 )
866866 {
867- // report, but continue with release procedure even if unlock fails
868- //ERROR_EXIT( errno, exit, "Buffer unlocking failed!\n" );
869- ERROR ( errno , "Buffer unlocking failed!\n" );
870- }
867+ #ifdef PDA_SKIP_UNLOCK_FAILURE
868+ #pragma message "*** Compiling with PDA_SKIP_UNLOCK_FAILURE"
869+ // report, but continue with release procedure even if unlock fails
870+ ERROR ( errno , "Buffer unlocking failed! (but releasing)\n" );
871+ if (0 ) { goto exit ; } // fake use of exit label to avoid compiler warning
872+ #else
873+ ERROR_EXIT ( errno , exit , "Buffer unlocking failed!\n" );
874+ #endif
875+ }
871876
872877 buffer -> map = MAP_FAILED ;
873878 persistant = PDA_DELETE ;
Original file line number Diff line number Diff line change @@ -62,6 +62,7 @@ MODPROBE_MODE="#define MODPROBE_MODE"
6262PREFIX=" /usr"
6363DEBUG=" "
6464NUMA=" true"
65+ EXTRA_DEFINES=" "
6566
6667
6768help ()
7374 echo " --debug=<true|false>"
7475 echo " --numa=<true|false>"
7576 echo " --modprobe=<true|false>"
77+ echo " --extra=<additional defines, comma separated>"
7678}
7779
7880
120122 continue
121123 ;;
122124
125+ " --extra" )
126+ EXTRA_DEFINES=$VALUE
127+ continue
128+ ;;
129+
123130 * )
124131 echo " Unknown parameter $PARAMETER !"
125132 exit -1
@@ -233,6 +240,12 @@ gen_config()
233240 echo " $KMOD_AVAIL " >> $BUILD_PATH /src/config.h
234241 echo " $NUMA_AVAIL " >> $BUILD_PATH /src/config.h
235242 echo " $MODPROBE_MODE " >> $BUILD_PATH /src/config.h
243+
244+ for DEF in ${EXTRA_DEFINES// ,/ }
245+ do
246+ echo " #define $DEF " >> $BUILD_PATH /src/config.h
247+ done
248+
236249 echo " #endif /* CONFIG_H */" >> $BUILD_PATH /src/config.h
237250}
238251
You can’t perform that action at this time.
0 commit comments