Whamcloud - gitweb
Branch HEAD
[fs/lustre-release.git] / lnet / libcfs / tracefile.c
index 3ca5ee8..4a5cf52 100644 (file)
@@ -343,7 +343,7 @@ int libcfs_debug_vmsg2(cfs_debug_limit_state_t *cdls, int subsys, int mask,
         __LASSERT (tage->used <= CFS_PAGE_SIZE);
 
 console:
-        if (!((mask & D_CANTMASK) != 0 || (mask & libcfs_printk) != 0)) {
+        if ((mask & libcfs_printk) == 0) {
                 /* no console output requested */
                 if (tcd != NULL)
                         trace_put_tcd(tcd);
@@ -1046,7 +1046,7 @@ void trace_stop_thread(void)
         mutex_up(&trace_thread_sem);
 }
 
-int tracefile_init(void)
+int tracefile_init(int max_pages)
 {
         struct trace_cpu_data *tcd;
         int                    i;
@@ -1067,7 +1067,7 @@ int tracefile_init(void)
                 tcd->tcd_cur_pages = 0;
                 tcd->tcd_cur_stock_pages = 0;
                 tcd->tcd_cur_daemon_pages = 0;
-                tcd->tcd_max_pages = (TCD_MAX_PAGES * factor) / 100;
+                tcd->tcd_max_pages = (max_pages * factor) / 100;
                 LASSERT(tcd->tcd_max_pages > 0);
                 tcd->tcd_shutting_down = 0;
         }