X-Git-Url: http://git.linux-vserver.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=util-vserver%2Fkernel%2Fcvirt_def.h;h=23aa246f51299f590d5209db82720ac8675204ea;hb=faa778968d1a7dfeaebc9fe4b847e691dc62fd15;hp=9fabb31c7a1a2063f0d850ebb897765cd3b46dcb;hpb=77d302326fbb2bc08b55f228627f83f2be1dbc0b;p=util-vserver.git diff --git a/util-vserver/kernel/cvirt_def.h b/util-vserver/kernel/cvirt_def.h index 9fabb31..23aa246 100644 --- a/util-vserver/kernel/cvirt_def.h +++ b/util-vserver/kernel/cvirt_def.h @@ -35,7 +35,7 @@ struct _vx_syslog { /* context sub struct */ struct _vx_cvirt { -// int max_threads; /* maximum allowed threads */ + int max_threads; /* maximum allowed threads */ atomic_t nr_threads; /* number of current threads */ atomic_t nr_running; /* number of running threads */ atomic_t nr_uninterruptible; /* number of uninterruptible threads */ @@ -61,24 +61,6 @@ struct _vx_cvirt { struct _vx_syslog syslog; }; - -#ifdef CONFIG_VSERVER_DEBUG - -static inline void __dump_vx_cvirt(struct _vx_cvirt *cvirt) -{ - printk("\t_vx_cvirt:\n"); - printk("\t threads: %4d, %4d, %4d, %4d\n", - atomic_read(&cvirt->nr_threads), - atomic_read(&cvirt->nr_running), - atomic_read(&cvirt->nr_uninterruptible), - atomic_read(&cvirt->nr_onhold)); - /* add rest here */ - printk("\t total_forks = %d\n", atomic_read(&cvirt->total_forks)); -} - -#endif - - struct _vx_sock_acc { atomic_t count; atomic_t total; @@ -87,29 +69,9 @@ struct _vx_sock_acc { /* context sub struct */ struct _vx_cacct { + unsigned long total_forks; + struct _vx_sock_acc sock[5][3]; }; -#ifdef CONFIG_VSERVER_DEBUG - -static inline void __dump_vx_cacct(struct _vx_cacct *cacct) -{ - int i,j; - - printk("\t_vx_cacct:"); - for (i=0; i<5; i++) { - struct _vx_sock_acc *ptr = cacct->sock[i]; - - printk("\t [%d] =", i); - for (j=0; j<3; j++) { - printk(" [%d] = %8d, %8d", j, - atomic_read(&ptr[j].count), - atomic_read(&ptr[j].total)); - } - printk("\n"); - } -} - -#endif - #endif /* _VX_CVIRT_DEF_H */