tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: cookies and kmem_alloc



On Mon, Jan 25, 2016 at 02:31:15PM -0500, Christos Zoulas wrote:
 > The directory functions pass around ap_cookies, and ap_ncookies,
 > but if one uses kmem_alloc() instead of malloc(), there is no way
 > to kmem_free() the buffer, since we don't pass the size. I suggest
 > that we add a new field called ap_acookies, which holds the size we
 > allocated with kmem_alloc(), or it is 0 for compatibility for code
 > that allocated the cookie buffer with malloc(). Any better ideas?

Burn down the in-kernel readdir interface and do a new one; it is
terrible the way it is and there's nothing to be gained by attempting
to polish it.

I don't yet have a clear handle on what the interface should be; but
both the nfs-facing and userlevel-facing parts are no good as is. :(

-- 
David A. Holland
dholland%netbsd.org@localhost


Home | Main Index | Thread Index | Old Index