mirror_ubuntu-kernels/include/linux/nfs_common.h
Mike Snitzer 4806ded4c1 nfs_common: factor out nfs_errtbl and nfs_stat_to_errno
Common nfs_stat_to_errno() is used by both fs/nfs/nfs2xdr.c and
fs/nfs/nfs3xdr.c

Will also be used by fs/nfsd/localio.c

Signed-off-by: Mike Snitzer <snitzer@kernel.org>
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Reviewed-by: NeilBrown <neilb@suse.de>
Signed-off-by: Anna Schumaker <anna.schumaker@oracle.com>
2024-09-23 15:03:29 -04:00

17 lines
402 B
C

/* SPDX-License-Identifier: GPL-2.0 */
/*
* This file contains constants and methods used by both NFS client and server.
*/
#ifndef _LINUX_NFS_COMMON_H
#define _LINUX_NFS_COMMON_H
#include <linux/errno.h>
#include <uapi/linux/nfs.h>
/* Mapping from NFS error code to "errno" error code. */
#define errno_NFSERR_IO EIO
int nfs_stat_to_errno(enum nfs_stat status);
#endif /* _LINUX_NFS_COMMON_H */