tech-kern archive

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

Re: CVS commit: src/sys/ufs/ufs



On Fri, May 16, 2014 at 09:04:37AM +0200, Martin Husemann wrote:
 > > I don't think it is a problem by itself as the file handle is opaque,
 > > but it is certainly wasteful to not put ufid_ino first.
 > 
 > That is not possible, the first few bytes of the structure must match
 > struct fid from fstypes.h.

Having just looked at the code that handles that... I'm going to give
it a good shellacking, I think. It is severely overcomplicated and it
does a horrible job of length-checking.

 > The structure is only used to construct opaque tokens for filehandles,
 > and the encoding includes the size, so I see no problem.

The problem is that the tokens are memcmp'd, so if they include struct
padding this may not work.

 > Indeed rebooting with an updated kernel will give active NFS clients
 > problems, but I am not sure we should realy care nor how we could
 > possibly avoid this one time issue. We have changed encoding of
 > filehandles before (at least once).

I don't think this is a problem, but maybe I'll put a note in UPDATING.

-- 
David A. Holland
dholland%netbsd.org@localhost


Home | Main Index | Thread Index | Old Index