This series of patches introduce a correction in tq metric and forwarding rules of ogm packets.
In the current configuration routing loops scenario can emerge due to some conceptual errors such the global tq window and the forwarding of ogm coming from sub-optimal paths substituting ogm tq with the average of current router. An example scenario has been realized also in simulation using qemu.
Can be demonstrated as already done for DSDV[1], that is a protocol very similar to batman, that a proper forwarding policy together with a strict control on metric monotonicity (as suggested in [2]) are sufficient to guarantee loop-freeness for the protocol.
I apologize in advance if the source style is not the best possible, but I hope that the ideas will applied after a phase of code revision.
Cheers, Daniele Furlan
[1] C. Perkins, P. Bhagwat, ”Highly-dynamic destination-sequenced distance-vector routing (DSDV) for mobile computers”, Proc. SIGCOMM ’94, pp. 234-244 [2] Y. Yang, J. Wang, R. Kravets, ”Designing routing metrics for mesh networks”, In WiMesh, 2005.