From: wcheng@sourceware.org <wcheng@sourceware.org>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] cluster/gfs-kernel/src/gfs ops_inode.c
Date: 15 Oct 2006 07:25:14 -0000 [thread overview]
Message-ID: <20061015072514.21254.qmail@sourceware.org> (raw)
CVSROOT: /cvs/cluster
Module name: cluster
Changes by: wcheng at sourceware.org 2006-10-15 07:25:14
Modified files:
gfs-kernel/src/gfs: ops_inode.c
Log message:
Just found 2.6.18 kernel has something called down_read_non_onwer for
rwsemaphore. If we can implement a similar function that does something
like "up_write_if_owner", then we can put i_alloc_sem back to correct
state. Correct the comment and mark this possibility.
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/gfs/ops_inode.c.diff?cvsroot=cluster&r1=1.13&r2=1.14
--- cluster/gfs-kernel/src/gfs/ops_inode.c 2006/10/15 06:32:06 1.13
+++ cluster/gfs-kernel/src/gfs/ops_inode.c 2006/10/15 07:25:09 1.14
@@ -1349,14 +1349,13 @@
* To avoid this to happen, i_alloc_sem must be dropped and trust
* be put into glock that it can carry the same protection.
*
- * One issue with dropping i_alloc_sem is gfs_setattr() can be
- * called from other code path without this sempaphore. Since linux
- * semaphore implementation doesn't include owner id, we have no way
- * to reliably decide whether the following "up" is a correct reset.
- * This implies if i_alloc_sem is ever used by non-direct_IO code
- * path in the future, this hack will fall apart. In short, with this
- * change, i_alloc_sem has become a meaningless lock within GFS and
- * don't expect its counter representing any correct state.
+ * One issue with dropping i_alloc_sem is that the gfs_setattr()
+ * can be invoked from other code path without this sempaphore.
+ * We'll need a new rwsem function that can "up" the semaphore
+ * only when it is needed. Before that happens (will research the
+ * possibility), i_alloc_sem (now) is a meaningless lock within
+ * GFS. If it is ever been used by other non-directIO code, this
+ * hack will fall apart.
*
* wcheng at redhat.com 10/14/06
*/
next reply other threads:[~2006-10-15 7:25 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-10-15 7:25 wcheng [this message]
-- strict thread matches above, loose matches on Subject: below --
2007-07-11 22:15 [Cluster-devel] cluster/gfs-kernel/src/gfs ops_inode.c rpeterso
2007-07-11 21:58 rpeterso
2007-06-29 21:57 rpeterso
2007-06-05 18:21 wcheng
2007-06-05 17:46 wcheng
2007-01-18 20:40 wcheng
2006-10-23 20:47 bmarzins
2006-10-03 17:27 rohara
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=20061015072514.21254.qmail@sourceware.org \
--to=wcheng@sourceware.org \
/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;
as well as URLs for NNTP newsgroup(s).