Whamcloud - gitweb
LU-6245 lnet: remove kernel defines in userland headers
[fs/lustre-release.git] / libcfs / include / libcfs / libcfs.h
index 2f9f633..c82a3d9 100644 (file)
@@ -27,7 +27,7 @@
  * Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved.
  * Use is subject to license terms.
  *
- * Copyright (c) 2011, 2012, Intel Corporation.
+ * Copyright (c) 2011, 2014, Intel Corporation.
  */
 /*
  * This file is part of Lustre, http://www.lustre.org/
 # include <libcfs/user-prim.h>
 # include <libcfs/user-mem.h>
 # include <libcfs/user-lock.h>
-# include <libcfs/user-tcpip.h>
 # include <libcfs/user-bitops.h>
 #endif /* __KERNEL__ */
 
 #include "curproc.h"
 
-#ifndef offsetof
-# define offsetof(typ,memb) ((long)(long_ptr_t)((char *)&(((typ *)0)->memb)))
-#endif
-
 #ifndef ARRAY_SIZE
 #define ARRAY_SIZE(a) ((sizeof (a)) / (sizeof ((a)[0])))
 #endif
@@ -138,23 +133,6 @@ static inline int __is_po2(unsigned long long val)
 #  error cfs_for_each_possible_cpu is not supported by kernel!
 #endif
 
-/* libcfs tcpip */
-int libcfs_ipif_query(char *name, int *up, __u32 *ip, __u32 *mask);
-int libcfs_ipif_enumerate(char ***names);
-void libcfs_ipif_free_enumeration(char **names, int n);
-int libcfs_sock_listen(cfs_socket_t **sockp, __u32 ip, int port, int backlog);
-int libcfs_sock_accept(cfs_socket_t **newsockp, cfs_socket_t *sock);
-void libcfs_sock_abort_accept(cfs_socket_t *sock);
-int libcfs_sock_connect(cfs_socket_t **sockp, int *fatal,
-                        __u32 local_ip, int local_port,
-                        __u32 peer_ip, int peer_port);
-int libcfs_sock_setbuf(cfs_socket_t *socket, int txbufsize, int rxbufsize);
-int libcfs_sock_getbuf(cfs_socket_t *socket, int *txbufsize, int *rxbufsize);
-int libcfs_sock_getaddr(cfs_socket_t *socket, int remote, __u32 *ip, int *port);
-int libcfs_sock_write(cfs_socket_t *sock, void *buffer, int nob, int timeout);
-int libcfs_sock_read(cfs_socket_t *sock, void *buffer, int nob, int timeout);
-void libcfs_sock_release(cfs_socket_t *sock);
-
 /* libcfs watchdogs */
 struct lc_watchdog;
 
@@ -281,7 +259,6 @@ void cfs_get_random_bytes(void *buf, int size);
 #include <libcfs/libcfs_hash.h>
 #include <libcfs/libcfs_heap.h>
 #include <libcfs/libcfs_fail.h>
-#include <libcfs/params_tree.h>
 
 /* container_of depends on "likely" which is defined in libcfs_private.h */
 static inline void *__container_of(const void *ptr, unsigned long shift)