Date: Wed, 10 Sep 2014 09:46:21 +0200 From: Philippe Jalaber <pjalaber@gmail.com> To: freebsd-hackers@freebsd.org Subject: subr_witness.c "rm_spinlock" and "smp rendezvous" wrong declaration order Message-ID: <CA%2Bi3ByKkCAJ8wc9-jvQxd_f3CdACihkgHSoHJZ1KtgxogH6_oA@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
Hello there, I have been playing with SMP and witness and looking at subr_witness.c. I suspect there is a bug in the declaration order of locks "rm_spinlock" and "smp rendezvous". It leads witness to fire a wrong LOR in SMP. Details: _rm_wlock in kern/kern_rmlock.c calls smp_rendezvous_cpus who locks smp_ipi_mtx then calls smp_rendezvous_action who calls rm_cleanIPI who locks rm_spinlock. So "smp_rendezvous" should be declared before "rm_spinlock" in subr_witness.c Thanks for reading me, Philippe
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CA%2Bi3ByKkCAJ8wc9-jvQxd_f3CdACihkgHSoHJZ1KtgxogH6_oA>