public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andreas Dilger <adilger@clusterfs.com>
To: OHKUBO Katsuhiko <ohkubo-k@suri.co.jp>
Cc: linux-kernel@vger.kernel.org
Subject: Re: question: The use of s_op->write_super_lockfs/unlockfs
Date: Fri, 14 Jun 2002 00:49:05 -0600	[thread overview]
Message-ID: <20020614064905.GT682@clusterfs.com> (raw)
In-Reply-To: <20020614122405.FF2D.OHKUBO-K@suri.co.jp>

On Jun 14, 2002  12:55 +0900, OHKUBO Katsuhiko wrote:
> There ars
> 	void write_super_lockfs(super_block *)
> 	void unlockfs(super_block *)
> in struct super_operations.
> 
> Ext3 and reiserfs have implementations of it.
> But I cannot find callers of it and system calls for it.
> 
> There are some pathches such as 
> 	http://www.lifix.fi/listarchive/lkml/2001-08/msg00464.html
> but it's not included in Linux 2.4.18/2.5.21.
> 	drivers/md/lvm.c has only callers of functions in this patch
> 	if defined LVM_VFS_ENHANCEMENT, but there aren't function bodys.
> 
> Q1: Who does use s_op->write_super_lockfs/unlockfs now?

LVM and EVMS use this interface, but it has not been accepted into the
kernel yet.  I think Chris Mason wants to submit the patch to implement
this, but has not yet.  I believe the 2.4.18 patch needs changing for
both 2.4.20 and 2.5.x.

> Q3: Is it enable to implement of system calls for lockfs/unlockfs
> 	without deadlocks?

No, because there is no guarantee that the user process will ever
call unlockfs (it could die or something).  I _suppose_ it would
be possible to call an ioctl to do the lockfs, and if the process dies
before calling unlockfs the close() will also do the unlockfs.  It
could still deadlock on I/O to the locked device and never terminate,
and it would be unkillable from user-space (stuck in "D" state).

Cheers, Andreas
--
Andreas Dilger
http://www-mddsp.enel.ucalgary.ca/People/adilger/
http://sourceforge.net/projects/ext2resize/


      reply	other threads:[~2002-06-14  6:50 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-06-14  3:55 question: The use of s_op->write_super_lockfs/unlockfs OHKUBO Katsuhiko
2002-06-14  6:49 ` Andreas Dilger [this message]

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=20020614064905.GT682@clusterfs.com \
    --to=adilger@clusterfs.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ohkubo-k@suri.co.jp \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox