• Neil Brown's avatar
    [PATCH] kNFSd: Reorganise rpc program version management. · 1a80c3c6
    Neil Brown authored
    An rpc service like NFSD knows about a number of
    versions (2,3,4) and needs to know the max and min valid
    version numbers, and also the maximum xdr buffer size used
    by any version.
    
    These max/mins are currently computed at compile time which means
    we need to include all the xdr*.h headers into nfssvc.c just for
    computing a couple of numbers.
    
    With this patch, these max/mins are calculated at run time from
    information in the svc_version structure which has been extended to
    include per-version xdrsize.
    
    Also the nfsd_version2, nfsd_version3, and nfsd_version4
    structures are moved from nfssvc.c to their more correct home
    of nfs*proc.c
    
    Code gets neated, xdr*.h are no-longer included in
    nfssvc.c, and the ugly ifdef can be removed fom xdr4.h
    1a80c3c6
nfsproc.c 15.3 KB