On 12 August 2015 at 17:40, Paolo Bonzini <[email protected]> wrote: > From: KONRAD Frederic <[email protected]> > > spinlock is only used in two cases: > * cpu-exec.c: to protect TranslationBlock > * mem_helper.c: for lock helper in target-i386 (which seems broken). > > It's a pthread_mutex_t in user-mode so better using QemuMutex directly in this > case. > It allows as well to reuse tb_lock mutex of TBContext in case of multithread > TCG.
The line wrapping in this commit message (and the grammar) looks a bit off... > Signed-off-by: KONRAD Frederic <[email protected]> > Message-Id: <[email protected]> > Signed-off-by: Paolo Bonzini <[email protected]> > --- > cpu-exec.c | 15 +++------------ > include/exec/exec-all.h | 4 ++-- > linux-user/main.c | 6 +++--- > target-i386/cpu.h | 3 +++ > target-i386/mem_helper.c | 25 ++++++++++++++++++++++--- > target-i386/translate.c | 2 ++ > tcg/tcg.h | 4 ++++ > translate-all.c | 34 ++++++++++++++++++++++++++++++++++ > 8 files changed, 73 insertions(+), 20 deletions(-) After this commit it looks like we have no users of spinlock_t at all. It would be good to have a followup patch which deleted include/exec/spinlock.h. Otherwise Reviewed-by: Peter Maydell <[email protected]> thanks -- PMM
