Re: [evlog-dev] [PATCH] save most recent event when the buffer overflows
James Keniston <[email protected]> Wed, 30 Apr 2003 11:13:23 -0700
| Newsgroups | gmane.linux.kernel.event-logging |
|---|---|
| Message-ID | <OFB6988E8C.849830F9-ON88256D18.00611519-88256D18.00641A2C@us.ibm.com> |
When reimplementing Zhu Yi's feature on top of the revised evlog-buffer code, we'd need to add some locking around evl_ebuf.bf_head. In the current implementation, only the function that drains the buffer can advance the bf_head pointer. In Zhu Yi's code, cbuf_wrap advances the bf_head pointer when discarding old records to make room for the new one. We'd also need to adjust counting of discarded records -- but retain the policy that we don't log an "event records dropped" message until draining has restored significant free space to the buffer. Jim |---------+--------------------------------------------> | | [email protected] | | | Sent by: | | | [email protected]| | | ceforge.net | | | | | | | | | 04/30/03 09:49 AM | | | | |---------+--------------------------------------------> >--------------------------------------------------------------------------------------------------------------------------------------------------| | | | To: "Zhu, Yi" <[email protected]> | | cc: [email protected], Hien Q Nguyen/Beaverton/IBM@IBMUS, James Keniston/Beaverton/IBM@IBMUS, | | [email protected] | | Subject: Re: [evlog-dev] [PATCH] save most recent event when the buffer overflows | | | >--------------------------------------------------------------------------------------------------------------------------------------------------| Hi Yi, We are currently making a lot of changes in the kernel (i.e. Jim re-wrote the evlog kernel buffer and combined the evl_buf.c and evl_cmd.c files to just one file evlog.c etc...). We will release the new kernel patch in the near future, we like to postpone this patch until then. Thanks for your contributions. Hien. Zhu, Yi wrote: > Hi, > > I implemented the "saving most recent event when the buffer overflows" feature > (TODO list 16) for kernel 2.4.20 in below patch. Currently it is enabled by > selecting CONFIG_EVLOG_SAVE_RECENT when make menuconfig. I am also glad to know > if there is any requirement to export it as a proc interface to configure it at > run time. > > > [SNIP] ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf