Messages in this thread | | | Subject | Re: [PATCH 2/4] integrity: Linux Integrity Module(LIM) | From | Mimi Zohar <> | Date | Fri, 21 Nov 2008 14:09:47 -0500 |
| |
On Fri, 2008-11-21 at 09:48 -0800, Dave Hansen wrote: > On Thu, 2008-11-20 at 11:43 -0500, Mimi Zohar wrote: > > > > +static inline void tget(struct template_list_entry *entry) > > +{ > > + atomic_inc(&entry->refcount); > > +} > > + > > +static inline void tput(struct template_list_entry *entry) > > +{ > > + if (atomic_dec_and_test(&entry->refcount)) > > + kfree(entry); > > +} > > Seems like a good place for a kref. > > -- Dave
Thanks!
Mimi
| |