Re: [PATCH v13 04/19] nfsd: factor out __fh_verify to allow NULL rqstp to be passed

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

 



On Wed, Aug 28, 2024 at 01:01:01PM -0400, Chuck Lever wrote:
> On Mon, Aug 26, 2024 at 09:44:48AM +1000, NeilBrown wrote:
> > On Mon, 26 Aug 2024, Chuck Lever wrote:
> > > See comment on 5/N: since that patch makes this a public API again,
> > > consider not removing this kdoc comment but rather updating it.
> > 
> > What exactly do you consider to be a "public API"??  Anything without
> > "static"?  That seems somewhat arbitrary.
> > 
> > I think of __fh_verify() as a private API used by fh_verify() and
> > nfsd_file_acquire_local() and nothing else.
> > 
> > It seems pointless duplication the documentation for __fh_verify() and
> > fh_verify().  Maybe one could refer to the other "fh_verify is like
> > fh_verify except ....."
> > 
> > ??
> > 
> > > 
> > > 
> > > > -__be32
> > > > -fh_verify(struct svc_rqst *rqstp, struct svc_fh *fhp, umode_t type, int access)
> > > > +static __be32
> > > > +__fh_verify(struct svc_rqst *rqstp,
> 
> An alternative would be to leave __fh_verify() as a static, and then
> add an fh_verify_local() API, echoing nfsd_file_acquire_local(), and
> then give that API a kdoc comment.
> 
> That would make it clear who the intended consumer is.

I ran with this idea, definite improvement, you'll find the changes
folded in to the relevant patch (with the same subject) in v14.

Thanks,
Mike




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux