lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 3 Oct 2019 12:48:39 -0700
From:   Eric Biggers <ebiggers@...nel.org>
To:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc:     linux-kernel@...r.kernel.org, stable@...r.kernel.org,
        syzbot+af05535bb79520f95431@...kaller.appspotmail.com,
        syzbot+d86c4426a01f60feddc7@...kaller.appspotmail.com,
        Christoph Hellwig <hch@....de>,
        Miklos Szeredi <mszeredi@...hat.com>,
        Sasha Levin <sashal@...nel.org>
Subject: Re: [PATCH 4.19 209/211] fuse: fix deadlock with aio poll and
 fuse_iqueue::waitq.lock

On Thu, Oct 03, 2019 at 05:54:35PM +0200, Greg Kroah-Hartman wrote:
>  
>  static void queue_interrupt(struct fuse_iqueue *fiq, struct fuse_req *req)
>  {
> -	spin_lock(&fiq->waitq.lock);
> +	spin_lock(&fiq->lock);
>  	if (test_bit(FR_FINISHED, &req->flags)) {
> -		spin_unlock(&fiq->waitq.lock);
> +		spin_unlock(&fiq->lock);
>  		return;
>  	}
>  	if (list_empty(&req->intr_entry)) {
>  		list_add_tail(&req->intr_entry, &fiq->interrupts);
>  		wake_up_locked(&fiq->waitq);
>  	}
> -	spin_unlock(&fiq->waitq.lock);
> +	spin_unlock(&fiq->lock);
>  	kill_fasync(&fiq->fasync, SIGIO, POLL_IN);
>  }

This isn't backported correctly.  wake_up_locked() needs to be changed to wake_up().

diff --git a/fs/fuse/dev.c b/fs/fuse/dev.c
index c0d59a86ada2e..6d39143cfa094 100644
--- a/fs/fuse/dev.c
+++ b/fs/fuse/dev.c
@@ -434,7 +434,7 @@ static void queue_interrupt(struct fuse_iqueue *fiq, struct fuse_req *req)
 	}
 	if (list_empty(&req->intr_entry)) {
 		list_add_tail(&req->intr_entry, &fiq->interrupts);
-		wake_up_locked(&fiq->waitq);
+		wake_up(&fiq->waitq);
 	}
 	spin_unlock(&fiq->lock);
 	kill_fasync(&fiq->fasync, SIGIO, POLL_IN);

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ