/* Address family must be initialized, and address must not be the ANY address for that family.  */
static int nfs_verify_server_address(struct sockaddr *addr)
/* Address family must be initialized, and address must not be the ANY address for that family.  */
static int nfs_verify_server_address(struct sockaddr *addr)
{
	switch (addr->sa_family) {
	case AF_INET: {
		struct sockaddr_in *sa = (struct sockaddr_in *)addr;
		return sa->sin_addr.s_addr != htonl(INADDR_ANY);
	}
	case AF_INET6: {
		struct in6_addr *sa = &((struct sockaddr_in6 *)addr)->sin6_addr;
		return !ipv6_addr_any(sa);
	}
	}
	dfprintk(MOUNT, "NFS: Invalid IP address specified\n");
	return 0;
}