Re: [PATCH 2/6] CIFS: Make read call work with strict cache mode (try #2)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 29 Nov 2010 13:41:13 +0300
Pavel Shilovsky <piastryyy@xxxxxxxxx> wrote:

> 2010/11/29 Christoph Hellwig <hch@xxxxxxxxxxxxx>:
> >
> > Your patch arbitrarily shortens the read to the first vector.  While
> > short reads for regular files are fine with Posix, it will break a lot
> > of userspace applications.
> >
> 
> cifs_user_read returns the number of bytes we read from the server and
> it, of course, can be different with requested number. Could you
> explain carefully what do you mean, please? Where is a problem here?
> 
> 

Gah...good catch, Christoph. I'll need to rescind my ack for this patch
too.

Pavel, note that the aio_read prototype has a "nr_segs" argument. Your
patch ignores that argument in the strictcache case. If someone passes
in an array of iovecs, then you're ignoring all but the first.

-- 
Jeff Layton <jlayton@xxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe linux-cifs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux