On Thu, Sep 20, 2018 at 01:08:32PM -0400, Devesh Sharma wrote: > Remove the lock around the doorbell. It isn't necessary > and was a bottleneck for multithreaded clients. Performance of > spdk improves by 40% with it removed. > > Signed-off-by: JD Zheng <jiandong.zheng@xxxxxxxxxxxx> > Signed-off-by: Jonathan Richardson <jonathan.richardson@xxxxxxxxxxxx> > Signed-off-by: Devesh Sharma <devesh.sharma@xxxxxxxxxxxx> > --- > providers/bnxt_re/db.c | 2 -- > providers/bnxt_re/main.c | 1 - > providers/bnxt_re/main.h | 1 - > providers/bnxt_re/verbs.c | 2 -- > 4 files changed, 6 deletions(-) > > diff --git a/providers/bnxt_re/db.c b/providers/bnxt_re/db.c > index a79f871..2896ceb 100644 > --- a/providers/bnxt_re/db.c > +++ b/providers/bnxt_re/db.c > @@ -44,11 +44,9 @@ static void bnxt_re_ring_db(struct bnxt_re_dpi *dpi, > { > __le64 *dbval; > > - pthread_spin_lock(&dpi->db_lock); > dbval = (__le64 *)&hdr->indx; > udma_to_device_barrier(); > iowrite64(dpi->dbpage, dbval); > - pthread_spin_unlock(&dpi->db_lock); > } Nope, you have to convert this provider to use the mmio accessor helpers if you want to do this. Ie get rid of iowrite64/iowrite32 and use the macros in util/mmio.h They provide the necessary guarentee for atomicity to allow the lock to be removed. Jason