Hi,
bitarray.c consists mostly of functionality that is already available as part of the standard kernel API. batman-adv could use architecture optimized code and reduce the binary size by switching to the standard functions.
it took some time to read about the kernel bit functions but I think this is the right way to go. From my end it looks pretty solid. Though I have 2 comments: * get_bit_status()/bit_mark()/bit_shift() now are wrapper functions of the linux kernel functions with an additional check. How about we follow the kernel naming convention plus a small prefix ? For example: bat_test_bit()/bat_set_bit()/bat_bitmap_shift_left() ? We probably could also inline those 3 functions since they don't do much. * Am I right assuming that you did not find something nice / handy for our bitarrays bcast_own/bcast_own_sum ? At the moment we deal with them in a "manual" fashion ..
Cheers, Marek