All of lore.kernel.org
 help / color / mirror / Atom feed
From: Al Viro <viro@ZenIV.linux.org.uk>
To: Vitaly Chernooky <vitalii.chernookyi@globallogic.com>
Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
	"Linus Torvalds" <torvalds@linux-foundation.org>,
	"David Vrabel" <david.vrabel@citrix.com>,
	"Marek Marczykowski-Górecki" <marmarek@invisiblethingslab.com>,
	"Iurii Konovalenko" <iurii.konovalenko@globallogic.com>,
	"Ian Campbell" <ian.campbell@citrix.com>,
	"Boris Ostrovsky" <boris.ostrovsky@oracle.com>,
	"Andrii Anisov" <andrii.anisov@globallogic.com>,
	"Artem Mygaiev" <artem.mygaiev@globallogic.com>
Subject: Re: [PATCH] [RFC] Fix deadlock on regular nonseekable files
Date: Fri, 20 Mar 2015 14:46:34 +0000	[thread overview]
Message-ID: <20150320144634.GY29656@ZenIV.linux.org.uk> (raw)
In-Reply-To: <CANZZXhBNSVmFTsteG7AAHuuYK7qU8J2LaHfcO16-2mcc+7kxag@mail.gmail.com>

On Fri, Mar 20, 2015 at 04:22:11PM +0200, Vitaly Chernooky wrote:
> > AFAICS, any threads blocked on f_pos_lock are not holding anything else and
> > cannot impede the rest.  What am I missing here?
> 
> As far as I understand it is true only for files on regular filesystem
> like ext4. Let's to see how XEN guys run into trouble with that
> f_pos_lock:

What does it have to do with filesystem type involved?  The only place that
takes f_pos_lock is __fdget_pos(), with only one caller in the entire tree -
fdget_pos().  Which is static in fs/read_write.c and all its callers are
in right in the beginning of sys_<something>.

Is it just that they have read() on procfs file blocked waiting for something
and a bunch of other read/write on the same descriptor blocked on ->f_pos_mutex
waiting for that sucker to finish?

Then basically they are asking to waive XSI 2.9.7 for that file - behaviour
*is* required by POSIX.

What file it is and what is the first read() (or write(), whatever) blocked on?
Stack traces would be useful for the latter...

  reply	other threads:[~2015-03-20 14:46 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-20 13:17 [PATCH] [RFC] Fix deadlock on regular nonseekable files Vitaly Chernooky
2015-03-20 13:42 ` Al Viro
2015-03-20 14:22   ` Vitaly Chernooky
2015-03-20 14:22     ` Vitaly Chernooky
2015-03-20 14:46     ` Al Viro [this message]
2015-03-20 17:37       ` Vitaly Chernooky
2015-03-20 17:55         ` Al Viro
2015-03-20 19:00           ` Marek Marczykowski-Górecki
2015-03-20 19:35             ` Al Viro
2015-03-20 19:35               ` Al Viro

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150320144634.GY29656@ZenIV.linux.org.uk \
    --to=viro@zeniv.linux.org.uk \
    --cc=andrii.anisov@globallogic.com \
    --cc=artem.mygaiev@globallogic.com \
    --cc=boris.ostrovsky@oracle.com \
    --cc=david.vrabel@citrix.com \
    --cc=ian.campbell@citrix.com \
    --cc=iurii.konovalenko@globallogic.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marmarek@invisiblethingslab.com \
    --cc=torvalds@linux-foundation.org \
    --cc=vitalii.chernookyi@globallogic.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.