mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-02-17 14:50:43 -05:00
virtio_fs: Remove redundant spinlock in virtio_fs_request_complete()
Since clear_bit is an atomic operation, the spinlock is redundant and can be removed, reducing lock contention is good for performance. Signed-off-by: Li RongQing <lirongqing@baidu.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
This commit is contained in:
committed by
Miklos Szeredi
parent
6fd26f5085
commit
b4da63cea1
@@ -761,7 +761,6 @@ static void copy_args_from_argbuf(struct fuse_args *args, struct fuse_req *req)
|
||||
static void virtio_fs_request_complete(struct fuse_req *req,
|
||||
struct virtio_fs_vq *fsvq)
|
||||
{
|
||||
struct fuse_pqueue *fpq = &fsvq->fud->pq;
|
||||
struct fuse_args *args;
|
||||
struct fuse_args_pages *ap;
|
||||
unsigned int len, i, thislen;
|
||||
@@ -790,9 +789,7 @@ static void virtio_fs_request_complete(struct fuse_req *req,
|
||||
}
|
||||
}
|
||||
|
||||
spin_lock(&fpq->lock);
|
||||
clear_bit(FR_SENT, &req->flags);
|
||||
spin_unlock(&fpq->lock);
|
||||
|
||||
fuse_request_end(req);
|
||||
spin_lock(&fsvq->lock);
|
||||
|
||||
Reference in New Issue
Block a user