lkml.org 
[lkml]   [2010]   [Nov]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v1.3 2/4] key: add tpm_send command
From
Date
On Fri, 2010-11-12 at 19:24 -0200, Rajiv Andrade wrote:
>
> Hi Dave,
>
> On 11/12/2010 12:48 PM, David Safford wrote:
>
> > On Fri, 2010-11-12 at 14:11 +0000, David Howells wrote:
> >> Mimi Zohar<zohar@linux.vnet.ibm.com> wrote:
> >>
> >>>>> + module_put(chip->dev->driver->owner);
> >>>> Where's the corresponding module_get()? I suspect this should be wrapped to
> >>>> match tpm_chip_find_get().
> >>>>
> >>>> David
> >>> The module_get() is in tpm_chip_find_get(), which is just a helper.
> >>> (It's used this way throughout tpm.c)
> >> I'd make a function tpm_chip_find_put() just to wrap module_put() and then
> >> place it with tpm_chip_find_get() in the sources. That makes it easier to see
> >> what's going on.
> > Or alternately rename the helper to tpm_chip_find_and_module_get()?
> > In either case, this is really up to Rajiv (the maintainer for tpm.c
> > who has already acked this patch), as this usage already appears in
> > other places in tpm.c. There would have to be a separate patch fixing
> > this for all of the instances. Rajiv, your thoughts?
> >
> > dave
> Rename the helper to tpm_chip_find_and_module_get() solves the naming issue
> in a simpler and better way in my opinion.
>
> Thanks,
> Rajiv

David, does this look ok to you? If so, I will do two patches, one to
fix the helper name throughout the existing tpm.c, and then a new
version of the tpm_send patch which uses the new name.

thanks
dave



\
 
 \ /
  Last update: 2010-11-12 23:11    [W:0.041 / U:1.884 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site