1 /* SPDX-License-Identifier: GPL-2.0 */
3 * Resolve DNS hostnames into valid ip addresses
5 #ifndef __LINUX_FS_NFS_DNS_RESOLVE_H
6 #define __LINUX_FS_NFS_DNS_RESOLVE_H
8 #define NFS_DNS_HOSTNAME_MAXLEN (128)
11 #ifdef CONFIG_NFS_USE_KERNEL_DNS
12 static inline int nfs_dns_resolver_init(void)
17 static inline void nfs_dns_resolver_destroy(void)
20 static inline int nfs_dns_resolver_cache_init(struct net *net)
25 static inline void nfs_dns_resolver_cache_destroy(struct net *net)
28 extern int nfs_dns_resolver_init(void);
29 extern void nfs_dns_resolver_destroy(void);
30 extern int nfs_dns_resolver_cache_init(struct net *net);
31 extern void nfs_dns_resolver_cache_destroy(struct net *net);
34 extern ssize_t nfs_dns_resolve_name(struct net *net, char *name,
35 size_t namelen, struct sockaddr *sa, size_t salen);