public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Badari Pulavarty <pbadari@us.ibm.com>
To: Michael Holzheu <HOLZHEU@de.ibm.com>,
	Andrew Morton <akpm@osdl.org>,
	lkml <linux-kernel@vger.kernel.org>
Subject: [PATCH] s390 hypfs fixes for 2.6.18-rc1-mm1
Date: Wed, 12 Jul 2006 21:10:54 -0700	[thread overview]
Message-ID: <44B5C7CE.6090606@us.ibm.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 370 bytes --]

Hi Micheal,

I made fixes to hypfs to fit new vfs ops interfaces. I am not sure if we 
really
need to vectorize aio interfaces, can you check and see if this is okay ?

And also, I am not sure what hypfs_aio_write() is actually doing.
It doesn't seem to be  doing with "buf" ?

(BTW - I have no way to verify these change. Can you give them a spin ?)

Thanks,
Badari




[-- Attachment #2: hypfs-fixes.patch --]
[-- Type: text/plain, Size: 1516 bytes --]

Vectorize aio interfaces to hypfs to fit new vfs ops interfaces.

Signed-off-by: Badari Pulavarty <pbadari@us.ibm.com>

Index: linux-2.6.18-rc1/arch/s390/hypfs/inode.c
===================================================================
--- linux-2.6.18-rc1.orig/arch/s390/hypfs/inode.c	2006-07-11 21:28:07.000000000 -0700
+++ linux-2.6.18-rc1/arch/s390/hypfs/inode.c	2006-07-12 21:18:44.000000000 -0700
@@ -134,12 +134,20 @@ static int hypfs_open(struct inode *inod
 	return 0;
 }
 
-static ssize_t hypfs_aio_read(struct kiocb *iocb, __user char *buf,
-			      size_t count, loff_t offset)
+static ssize_t hypfs_aio_read(struct kiocb *iocb, const struct iovec *iov,
+			      unsigned long nr_segs, loff_t offset)
 {
 	char *data;
 	size_t len;
 	struct file *filp = iocb->ki_filp;
+	/* XXX: temporary */
+	const struct __user *buf = iov[0].iov_base;
+	size_t count = iov[0].iov_len;
+
+	if (nr_segs != 1) {
+		count = -EINVAL;
+		goto out;
+	}
 
 	data = filp->private_data;
 	len = strlen(data);
@@ -158,12 +166,13 @@ static ssize_t hypfs_aio_read(struct kio
 out:
 	return count;
 }
-static ssize_t hypfs_aio_write(struct kiocb *iocb, const char __user *buf,
-			       size_t count, loff_t pos)
+static ssize_t hypfs_aio_write(struct kiocb *iocb, const struct iovec *iov,
+			      unsigned long nr_segs, loff_t offset)
 {
 	int rc;
 	struct super_block *sb;
 	struct hypfs_sb_info *fs_info;
+	size_t count = iov_length(iov, nr_segs);
 
 	sb = iocb->ki_filp->f_dentry->d_inode->i_sb;
 	fs_info = sb->s_fs_info;

             reply	other threads:[~2006-07-13  4:10 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-13  4:10 Badari Pulavarty [this message]
2006-07-13  4:17 ` [PATCH] s390 hypfs fixes for 2.6.18-rc1-mm1 Badari Pulavarty
2006-07-13  9:04   ` Cedric Le Goater
2006-07-13 16:48     ` Badari Pulavarty
2006-07-13  9:23   ` Andrew Morton
2006-07-13 14:31     ` Badari Pulavarty
2006-07-13 15:41       ` Michael Holzheu
2006-07-13 17:39         ` Badari Pulavarty
2006-07-14 10:23           ` Michael Holzheu
2006-07-13 13:44   ` Michael Holzheu

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=44B5C7CE.6090606@us.ibm.com \
    --to=pbadari@us.ibm.com \
    --cc=HOLZHEU@de.ibm.com \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox