All of lore.kernel.org
 help / color / mirror / Atom feed
From: Laurent Riffard <laurent.riffard@free.fr>
To: ReiserFS Mailing List <reiserfs-devel@vger.kernel.org>,
	Edward Shishkin <edward.shishkin@gmail.com>
Cc: Andrew Morton <akpm@osdl.org>, Randy Dunlap <randy.dunlap@oracle.com>
Subject: Reiser4: remove simple_prepare_write usage
Date: Wed, 26 Nov 2008 18:05:56 +0100	[thread overview]
Message-ID: <492D81F4.6010507@free.fr> (raw)

Reiser4 can't be built as a module when EXPORT_UNUSED_SYMBOL is not set.

It's broken because reiser4_write_extent is calling
simple_prepare_write() and commit
4e02ed4b4a2fae34aae766a5bb93ae235f60adb8 scheduled it for unexporting.

Signed-off-by: Laurent Riffard <laurent.riffard@free.fr>
---
 fs/reiser4/plugin/item/extent_file_ops.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/fs/reiser4/plugin/item/extent_file_ops.c b/fs/reiser4/plugin/item/extent_file_ops.c
index ef3744e..1eb1ab7 100644
--- a/fs/reiser4/plugin/item/extent_file_ops.c
+++ b/fs/reiser4/plugin/item/extent_file_ops.c
@@ -1059,8 +1059,9 @@ ssize_t reiser4_write_extent(struct file *file, struct inode * inode,
 
 		lock_page(page);
 		if (!PageUptodate(page) && to_page != PAGE_CACHE_SIZE)
-			simple_prepare_write(file, page, page_off,
-					     page_off + to_page);
+			zero_user_segments(page, 0, page_off,
+			                   page_off + to_page,
+			                   PAGE_CACHE_SIZE);
 
 		written = filemap_copy_from_user(page, page_off, buf, to_page);
 		if (unlikely(written != to_page)) {
-- 
1.6.0.4.3.g5bcce


             reply	other threads:[~2008-11-26 17:05 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-26 17:05 Laurent Riffard [this message]
2008-11-26 17:51 ` Reiser4: remove simple_prepare_write usage Randy Dunlap
2008-11-26 17:57 ` Edward Shishkin

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=492D81F4.6010507@free.fr \
    --to=laurent.riffard@free.fr \
    --cc=akpm@osdl.org \
    --cc=edward.shishkin@gmail.com \
    --cc=randy.dunlap@oracle.com \
    --cc=reiserfs-devel@vger.kernel.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 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.