|
|
1.1 root 1: /* $Header: /newbits/286_KERNEL/USRSRC/coh/RCS/elog.c,v 1.1 92/01/09 13:26:39 bin Exp Locker: bin $ */
2: /* (lgl-
3: * The information contained herein is a trade secret of Mark Williams
4: * Company, and is confidential information. It is provided under a
5: * license agreement, and may be copied or disclosed only under the
6: * terms of that agreement. Any reproduction or disclosure of this
7: * material without the express written authorization of Mark Williams
8: * Company or persuant to the license agreement is unlawful.
9: *
10: * COHERENT Version 2.3.37
11: * Copyright (c) 1982, 1983, 1984.
12: * An unpublished work by Mark Williams Company, Chicago.
13: * All rights reserved.
14: -lgl) */
15: /*
16: * Coherent - event/error logging facility.
17: *
18: * $Log: elog.c,v $
19: * Revision 1.1 92/01/09 13:26:39 bin
20: * Initial revision
21: *
22: * Revision 1.1 88/03/24 16:19:48 src
23: * Initial revision
24: *
25: */
26: #include <coherent.h>
27:
28: #define NEVENT 256
29: typedef struct {
30: char *e_event; /* Function pointer or whatever */
31: int e_time; /* Timer tick of event */
32: } EVENT;
33:
34: EVENT events[NEVENT];
35: unsigned curevent = 0;
36: unsigned totevent = 0;
37:
38: elog(eventp)
39: char *eventp;
40: {
41: register EVENT *ep;
42:
43: totevent += 1;
44: ep = &events[curevent++];
45: curevent %= NEVENT;
46: ep->e_event = eventp;
47: ep->e_time = timer.t_time;
48: }
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.