X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;ds=sidebyside;f=include%2Flinux%2Fvs_socket.h;h=d5505c5619d0ff4fbbc734a10b7e733f2f59f7c6;hb=6a77f38946aaee1cd85eeec6cf4229b204c15071;hp=4992458226772652a07ab90f284a4c8c1ec79729;hpb=c449269f45c2cdf53af08c8d0af37472f66539d9;p=linux-2.6.git diff --git a/include/linux/vs_socket.h b/include/linux/vs_socket.h index 499245822..d5505c561 100644 --- a/include/linux/vs_socket.h +++ b/include/linux/vs_socket.h @@ -1,15 +1,8 @@ -#ifndef _VX_VS_LIMIT_H -#define _VX_VS_LIMIT_H +#ifndef _VX_VS_SOCKET_H +#define _VX_VS_SOCKET_H -// #define VX_DEBUG - -#include -#include -#include - -#include "vserver/context.h" -#include "vserver/network.h" +#include "vserver/debug.h" /* socket accounting */ @@ -33,12 +26,12 @@ static inline int vx_sock_type(int family) static inline void __vx_acc_sock(struct vx_info *vxi, int family, int pos, int size, char *file, int line) { - if (vxi) { + if (vxi) { int type = vx_sock_type(family); atomic_inc(&vxi->cacct.sock[type][pos].count); atomic_add(size, &vxi->cacct.sock[type][pos].total); - } + } } #define vx_sock_recv(sk,s) \ @@ -49,12 +42,12 @@ static inline void __vx_acc_sock(struct vx_info *vxi, vx_acc_sock((sk)->sk_vx_info, (sk)->sk_family, 2, (s)) -#define sock_vx_init(s) do { \ +#define sock_vx_init(s) do { \ (s)->sk_xid = 0; \ (s)->sk_vx_info = NULL; \ } while (0) -#define sock_nx_init(s) do { \ +#define sock_nx_init(s) do { \ (s)->sk_nid = 0; \ (s)->sk_nx_info = NULL; \ } while (0)