Re: [PATCH] nfsd/blocklayout: accept any minlength

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

 



On Sun, Oct 11, 2015 at 03:08:22PM +0200, Christoph Hellwig wrote:
> On Fri, Oct 09, 2015 at 04:04:38PM -0400, J. Bruce Fields wrote:
> > I had some ideas that layouts were something a server could decline just
> > on random whim.  Rereading that section.... OK, looks like I was
> > confused, TRYLATER is the closest we come to random whim.
> > 
> > So the following condition on the alignments of the offset also looks
> > wrong.  Christoph, should it be rounding the offset down instead of
> > rejecting in that case?
> 
> RFC5663 is very explicit about the extents being aligned, but doesn't
> say anything about LAYOUTGET requests.  It's a bit of a gray area, but
> I think not handing out a layout is still the best thing to do as a client
> has to be really confused to ask for an unaligned layout and expect to get
> an aligned extent back.

http://tools.ietf.org/html/rfc5661#section-18.43.3 always allows a
server to round down the offset, is there any downside to doing that?

> I just need to check for the best possible error value.

INVAL or BADLAYOUT, I guess.  But just rounding down seems harmless and
compatible with the letter of the spec.

Though without any reason or a client to request an unaligned offset I
guess it's a bit academic.

--b.

> 
> > And other layoutunavailable cases might need review too.
> 
> Will do.
--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux