Messages in this thread | | | Date | Mon, 29 Sep 2008 23:46:03 -0400 | From | Mathieu Desnoyers <> | Subject | Re: [PATCH v10 Golden] Unified trace buffer |
| |
* Steven Rostedt (rostedt@goodmis.org) wrote: > > On Mon, 29 Sep 2008, Mathieu Desnoyers wrote: > > > > > > Thanks! I must have been lucky some how not to trigger this :-/ > > > > > > > My guess is that you never free your buffers in your test cases. I don't > > know if it was expected; probably not if your code is built into the > > kernel. > > Actually my resize does free the buffers and I did test this. I probably > never ran the trace when testing the freeing which means those pointers > could have luckily not have been changed. > > -- Steve >
I also got some corruption of the offset field in the struct page I use. I think it might be related to the fact that I don't set the PG_private bit (slob does set it when the page is in its free pages list). However, given I'd like to pass the buffer pages to disk I/O and for network socket and still keep the ability to re-use it when the I/O has been performed, I wonder where I should put my
struct list_head list; /* linked list of buf pages */ size_t offset; /* page offset in the buffer */
fields ? Any ideas ?
They are currently in :
struct buf_page { union { struct { unsigned long flags; /* mandatory */ atomic_t _count; /* mandatory */ union { /* mandatory */ atomic_t _mapcount; struct { u16 inuse; u16 objects; }; }; struct list_head list; /* linked list of buf pages */ size_t offset; /* page offset in the buffer */ }; struct page page; }; };
Mathieu
-- Mathieu Desnoyers OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F BA06 3F25 A8FE 3BAE 9A68
| |