[ovs-dev] [PATCH v3] Rapid Spanning Protocol Implementation (IEEE 802.1D) + functional tests

Martino Fornasa mf at fornasa.it
Mon May 26 16:50:19 UTC 2014


Jarno Rajahalme wrote:
> Daniele, Martino,
>
> Thank you for the contribution, and sorry that it has taken so long for me to get to the review!
[...]

Dear all,
we are working on Jarno revision, and we will provide shortly a revised patch.
In the meantime, I would like to ask for advice on an issue we have encountered.

In RSTP, there are some cases in which the reception of an incoming BPDU triggers the the transmission of one or more BPDUs.
It seems that the approach we are following at the moment could not allow such, as a deadlock on the xlate_rwlock mutex is triggered.

In particular:
* The reception of a BPDU triggers the execution of xlate_actions__() [ofproto/ofproto-dpif-xlate.c] which takes a lock on xlate_rwlock.
* The processing of such BPDU inside lib/rstp* components triggers the following calls:
** rstp_send_bpdu() [lib/rstp-state-machines.c]
** rstp_send_bpdu_cb() [lib/ofproto/ofproto-dpif.c]
** ofproto_dpif_send_packet() [lib/ofproto/ofproto-dpif.c]
** xlate_send_packet() [lib/ofproto-dpif.xlate.c]
** xlate_send_packet() tries to acquire a lock on xlate_rwlock, resulting in a deadlock.

I am not familiar with the internals of ovs locking mechanisms, so, I am not sure how to proceed...




More information about the dev mailing list