"Paul Clements wrote:" > "Peter T. Breuer" wrote: > > Curiously enough, I'm slightly more nonplussed by the problem of > > kfreeing the bitmap pages when their dirty count drops to zero. > > What should I do? Maintain a how-many-times-we-have-wanted-to-free-this > > page count and only free it on the 10th attempt? > > hmm...perhaps an LRU approach? you could store a timestamp (jiffies?), > so that you never deallocate a page unless it hasn't been used in X > amount of time...might be too heavyweight for what you're trying to do This is not silly, but is too heavyweight to do each time a bit is set. The best thing to do is probably either or both of a) put the notionally freed pages on a free list and allocate from that list first when we want a new page b) do a periodic sweep for clean pages and free them. Peter - To unsubscribe from this list: send the line "unsubscribe linux-raid" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html