linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
To: Jason Gunthorpe <jgunthorpe@obsidianresearch.com>
Cc: Stefan Berger <stefanb@us.ibm.com>,
	linux-kernel@vger.kernel.org, Peter Huewe <peterhuewe@gmx.de>,
	tpmdd-devel@lists.sourceforge.net
Subject: Re: [PATCH 2/3] tpm: Get rid of chip->pdev
Date: Sun, 14 Feb 2016 07:24:14 +0200	[thread overview]
Message-ID: <20160214052414.GB8065@intel.com> (raw)
In-Reply-To: <20160213033320.GA27869@obsidianresearch.com>

On Fri, Feb 12, 2016 at 08:33:20PM -0700, Jason Gunthorpe wrote:
> On Fri, Feb 12, 2016 at 08:31:21PM -0500, Stefan Berger wrote:
> > > I'll send you something else that might work for vtpm...'
> > 
> > The vtpm driver will introduce chip->priv, which will point to vtpm_dev. For
> > this reason we need to hold a reference to the vtpm_dev->dev in the
> > front end.
> 
> This should take care of it for all drivers including vtpm.
> 
> https://github.com/jgunthorpe/linux/commits/for-jarkko
> 
> At the very least this turns silent use after free into a null pointer
> oops.
> 
> We should also discuss if we want to continue to have the driver
> module locked while /dev/tpmX is open, that is no longer needed for
> corectness.

I'm happy the patch that was sent before although I didn't give it
Reviewed-by because it had couple of style errors. If those two
style errors are the *only* issues I can fix up them.

Unless the differences are trivial (like a missing return value or
couple of minor style errors something very obvious) for me to fixup I'd
hope to re-review the code.

I'm not trying to be difficult here. For small errors I can amend
the commits but it seems that there was something more non-trival
done

Other than the first patch (for which I'm still waiting a clear
explanation why it is wrong), these are not going to 4.5 anyway so
there's lots time to things the long way.

/Jarkko

  reply	other threads:[~2016-02-14  5:24 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-13  0:04 [PATCH 0/3] Various struct device cleanups Jason Gunthorpe
2016-02-13  0:04 ` [PATCH 1/3] tpm: Hold the kref during tpm_chip_find_get Jason Gunthorpe
2016-02-13 10:08   ` Jarkko Sakkinen
2016-02-13 15:45     ` Jason Gunthorpe
2016-02-14  4:55   ` Jarkko Sakkinen
2016-02-14  6:50     ` Jason Gunthorpe
2016-02-14  8:02       ` Jarkko Sakkinen
2016-02-13  0:04 ` [PATCH 2/3] tpm: Get rid of chip->pdev Jason Gunthorpe
     [not found]   ` <201602130037.u1D0bDEN029756@d01av04.pok.ibm.com>
2016-02-13  1:11     ` Jason Gunthorpe
     [not found]       ` <201602130128.u1D1S2Xn006955@d01av05.pok.ibm.com>
2016-02-13  2:00         ` Jason Gunthorpe
2016-02-13  3:33         ` Jason Gunthorpe
2016-02-14  5:24           ` Jarkko Sakkinen [this message]
2016-02-14  6:57             ` Jason Gunthorpe
2016-02-14  8:03               ` Jarkko Sakkinen
2016-02-13 15:39   ` [tpmdd-devel] " Stefan Berger
2016-02-14  7:06     ` Jason Gunthorpe
2016-02-14  5:13   ` Jarkko Sakkinen
2016-02-13  0:04 ` [PATCH 3/3] tpm: Get rid of devname Jason Gunthorpe
2016-02-13  1:01   ` kbuild test robot
2016-02-13  1:13     ` Jason Gunthorpe
2016-02-14  5:16   ` Jarkko Sakkinen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160214052414.GB8065@intel.com \
    --to=jarkko.sakkinen@linux.intel.com \
    --cc=jgunthorpe@obsidianresearch.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=peterhuewe@gmx.de \
    --cc=stefanb@us.ibm.com \
    --cc=tpmdd-devel@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).