Lines Matching refs:kern_db
76 static struct rtacct_data *kern_db = &kern_db_static; variable
163 fprintf(fp, "#%s\n", kern_db->signature); in dump_abs_db()
185 val = &kern_db->val[realm*4]; in dump_abs_db()
186 rate = &kern_db->rate[realm*4]; in dump_abs_db()
219 fprintf(fp, "#%s\n", kern_db->signature); in dump_incr_db()
242 val = &kern_db->val[realm*4]; in dump_incr_db()
243 rate = &kern_db->rate[realm*4]; in dump_incr_db()
300 __u32 incr = ival[i] - kern_db->ival[i]; in update_db()
303 kern_db->val[i] == 0 && kern_db->rate[i] == 0) in update_db()
306 kern_db->val[i] += incr; in update_db()
307 kern_db->ival[i] = ival[i]; in update_db()
310 kern_db->rate[i] += W*(sample-kern_db->rate[i]); in update_db()
313 kern_db->rate[i] = sample; in update_db()
317 kern_db->rate[i] += w*(sample-kern_db->rate[i]); in update_db()
327 while (tot < sizeof(*kern_db)) { in send_db()
328 int n = write(fd, ((char *)kern_db) + tot, sizeof(*kern_db)-tot); in send_db()
363 sprintf(kern_db->signature, in server_loop()
368 pad_kern_table(kern_db, read_kern_table(kern_db->ival)); in server_loop()
562 if (write(fd, kern_db, sizeof(*hist_db)) < 0) { in main()
601 nread(fd, (char *)kern_db, sizeof(*kern_db)); in main()
603 strcmp(kern_db->signature, hist_db->signature)) { in main()
618 pad_kern_table(kern_db, read_kern_table(kern_db->ival)); in main()
619 strcpy(kern_db->signature, "kernel"); in main()