[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180718095420.GA28377@nautica>
Date: Wed, 18 Jul 2018 11:54:20 +0200
From: Dominique Martinet <asmadeus@...ewreck.org>
To: piaojun <piaojun@...wei.com>
Cc: "akpm@...ux-foundation.org" <akpm@...ux-foundation.org>,
Eric Van Hensbergen <ericvh@...il.com>,
Ron Minnich <rminnich@...dia.gov>,
Latchesar Ionkov <lucho@...kov.net>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
v9fs-developer@...ts.sourceforge.net
Subject: Re: [PATCH] net/9p/trans_virtio.c: replace mutex_lock with spin_lock
to protect 'virtio_chan_list'
piaojun wrote on Wed, Jul 18, 2018:
> spin_lock is more effective for short time protection than mutex_lock, as
> mutex lock may cause process sleep and wake up which consume much cpu
> time.
That's not a fast path operation, I don't mind changing things but I'd
like to understand why - these functions are only ever called at unmount
time or when something happens on the virtio bus (probe will happen on
probing on the pci bus and I'm not too sure on remove but probably pci
removal i.e. basically never?)
I don't see why this wouldn't work, but I won't take this without a
(good?) reason.
--
Dominique Martinet
Powered by blists - more mailing lists