Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-07 Thread Jason Gunthorpe
On Mon, Dec 07, 2015 at 10:59:15AM +0100, Wilck, Martin wrote: > > IS_ERR should address the oops though?? > > No, see my answer to Jarkko in the other part of the thread. I'm confused, is there an oops that still need to be fixed? > As reported before, with "force=1", I get the error message: >

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-07 Thread Jarkko Sakkinen
On Mon, Dec 07, 2015 at 10:52:51AM +0100, Wilck, Martin wrote: > > > > You can completely ignore this question. I saw Martins reply with a fix > > > > for > > > > "tpm_tis: Use devm_ioremap_resource" that you should squash into that > > > > change. So it's proved that TPM ACPI device objects do no

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-07 Thread Wilck, Martin
> IS_ERR should address the oops though?? No, see my answer to Jarkko in the other part of the thread. > I've put all the revised patches here: > > https://github.com/jgunthorpe/linux/commits/for-jarkko > > If you are OK with them now I'll post the series. I haven't re-reviewed it, but the tes

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-07 Thread Wilck, Martin
> > > You can completely ignore this question. I saw Martins reply with a fix > > > for > > > "tpm_tis: Use devm_ioremap_resource" that you should squash into that > > > change. So it's proved that TPM ACPI device objects do not always have a > > > memory resource. Good. > > > > Repeat, the memor

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-07 Thread Jarkko Sakkinen
On Mon, Dec 07, 2015 at 09:06:50AM +0100, Wilck, Martin wrote: > > > I'm a bit confused about the discussion because Martin replied that > > > tpm_tis used to get the address range before applying this series. > > > > > > And pnp_driver in the backend for TPM 1.x devices grabs the address > > > ra

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-07 Thread Wilck, Martin
> > I'm a bit confused about the discussion because Martin replied that > > tpm_tis used to get the address range before applying this series. > > > > And pnp_driver in the backend for TPM 1.x devices grabs the address > > range from DSDT. > > You can completely ignore this question. I saw Martin

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-06 Thread Jason Gunthorpe
On Sun, Dec 06, 2015 at 06:15:44AM +0200, Jarkko Sakkinen wrote: > You can completely ignore this question. I saw Martins reply with a fix for > "tpm_tis: Use devm_ioremap_resource" that you should squash into that > change. It isn't quite the right fix - but I've added something that should be OK

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-05 Thread Jarkko Sakkinen
On Sun, Dec 06, 2015 at 06:15:44AM +0200, Jarkko Sakkinen wrote: > On Sun, Dec 06, 2015 at 06:02:26AM +0200, Jarkko Sakkinen wrote: > > On Thu, Dec 03, 2015 at 11:19:32AM -0700, Jason Gunthorpe wrote: > > > On Thu, Dec 03, 2015 at 08:00:42AM +0200, Jarkko Sakkinen wrote: > > > > > > > I guess it'd

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-05 Thread Jarkko Sakkinen
On Sun, Dec 06, 2015 at 06:02:26AM +0200, Jarkko Sakkinen wrote: > On Thu, Dec 03, 2015 at 11:19:32AM -0700, Jason Gunthorpe wrote: > > On Thu, Dec 03, 2015 at 08:00:42AM +0200, Jarkko Sakkinen wrote: > > > > > I guess it'd be more realiable. In my NUC the current fix works and the > > > people wh

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-05 Thread Jarkko Sakkinen
On Thu, Dec 03, 2015 at 11:19:32AM -0700, Jason Gunthorpe wrote: > On Thu, Dec 03, 2015 at 08:00:42AM +0200, Jarkko Sakkinen wrote: > > > I guess it'd be more realiable. In my NUC the current fix works and the > > people who tested it. If you supply me a fix that changes it to use that > > I can t

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-04 Thread Jason Gunthorpe
On Fri, Dec 04, 2015 at 10:10:15AM +0100, Wilck, Martin wrote: > The following simple change fixes the ACPI probing after applying your > latest series. The must have been another ACPI resource that you were > erroneously using as mem resource. Close, acpi_dev_resource_memory destroys it's outpu

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-04 Thread Wilck, Martin
> > ACPI defines a mem resource corresponding to the standard TIS memory > > area on my system, and it used to be detected fine with Jarkko's patch. > > Somehow your latest changes broke it, not sure why. > > Are you certain? Based on what you sent me, that output is only > possible if there is no

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-04 Thread Wilck, Martin
On Do, 2015-12-03 at 10:00 -0700, Jason Gunthorpe wrote: > On Thu, Dec 03, 2015 at 09:30:30AM +0100, Wilck, Martin wrote: > > On Mi, 2015-12-02 at 12:11 -0700, Jason Gunthorpe wrote: > > > > > > What is the address tpm_tis should be using? I see two things, it > > > > either uses the x86 defaul

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-03 Thread Jason Gunthorpe
On Thu, Dec 03, 2015 at 08:00:42AM +0200, Jarkko Sakkinen wrote: > I guess it'd be more realiable. In my NUC the current fix works and the > people who tested it. If you supply me a fix that changes it to use that > I can test it and this will give also coverage to the people who tested > my origi

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-03 Thread Jason Gunthorpe
On Thu, Dec 03, 2015 at 09:30:30AM +0100, Wilck, Martin wrote: > On Mi, 2015-12-02 at 12:11 -0700, Jason Gunthorpe wrote: > > > > What is the address tpm_tis should be using? I see two things, it > > > either uses the x86 default address or it expects the ACPI to have a > > > MEM resource. AFAIK A

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-03 Thread Wilck, Martin
On Mi, 2015-12-02 at 12:11 -0700, Jason Gunthorpe wrote: > > What is the address tpm_tis should be using? I see two things, it > > either uses the x86 default address or it expects the ACPI to have a > > MEM resource. AFAIK ACPI should never rely on hard wired addresses, so > > I removed that code

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-02 Thread Jarkko Sakkinen
On Wed, Dec 02, 2015 at 12:11:55PM -0700, Jason Gunthorpe wrote: > On Wed, Dec 02, 2015 at 11:27:27AM -0700, Jason Gunthorpe wrote: > > > I'm guessing that if the driver probe order is tpm_crb,tpm_tis then > > things work because tpm_crb will claim the device first? Otherwise > > tpm_tis claims th

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-02 Thread Jarkko Sakkinen
On Wed, Dec 02, 2015 at 11:27:27AM -0700, Jason Gunthorpe wrote: > On Tue, Dec 01, 2015 at 11:33:51PM +0200, Jarkko Sakkinen wrote: > > On Tue, Dec 01, 2015 at 11:58:26AM -0700, Jason Gunthorpe wrote: > > > I went through the patches and didn't see anything that would shock me > > enough not to ap

Re: [tpmdd-devel] [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-02 Thread Jason Gunthorpe
On Wed, Dec 02, 2015 at 11:27:27AM -0700, Jason Gunthorpe wrote: > I'm guessing that if the driver probe order is tpm_crb,tpm_tis then > things work because tpm_crb will claim the device first? Otherwise > tpm_tis claims these things unconditionally? If the probe order is > reversed things become

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-02 Thread Jason Gunthorpe
On Tue, Dec 01, 2015 at 11:33:51PM +0200, Jarkko Sakkinen wrote: > On Tue, Dec 01, 2015 at 11:58:26AM -0700, Jason Gunthorpe wrote: > I went through the patches and didn't see anything that would shock me > enough not to apply the patches in the current if they also work when > tested *but* are th

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-02 Thread Jason Gunthorpe
On Wed, Dec 02, 2015 at 01:34:38PM +0100, Wilck, Martin wrote: > On Di, 2015-12-01 at 11:58 -0700, Jason Gunthorpe wrote: > > > Martin, this should fix the double loading you noticed, please confirm. > > There > > is a possibility the force path needs a bit more code to be compatible with > > de

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-02 Thread Uwe Kleine-König
Hello Greg, On Wed, Dec 02, 2015 at 08:53:38AM -0800, Greg Kroah-Hartman wrote: > On Wed, Dec 02, 2015 at 09:21:47AM +0100, Uwe Kleine-König wrote: > > > > These changes are complex enough they really shouldn't go into 4.4 > > > > unless absolutely necessary. > > > > > > The reasons I'm asking th

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-02 Thread Greg Kroah-Hartman
On Wed, Dec 02, 2015 at 09:21:47AM +0100, Uwe Kleine-König wrote: > Hello, > > Cc += gregkh > > On Wed, Dec 02, 2015 at 10:11:14AM +0200, Jarkko Sakkinen wrote: > > On Tue, Dec 01, 2015 at 03:22:23PM -0700, Jason Gunthorpe wrote: > > > On Tue, Dec 01, 2015 at 11:33:51PM +0200, Jarkko Sakkinen wro

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-02 Thread Wilck, Martin
On Di, 2015-12-01 at 11:58 -0700, Jason Gunthorpe wrote: > Martin, this should fix the double loading you noticed, please confirm. There > is a possibility the force path needs a bit more code to be compatible with > devm_ioremap_resource, I'm not sure, hoping not. Nope, this one oopses in the A

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-02 Thread Peter Huewe
Am 2. Dezember 2015 00:14:23 PST, schrieb Jarkko Sakkinen : >On Tue, Dec 01, 2015 at 05:15:14PM -0800, Peter Huewe wrote: >> >> >> Am 1. Dezember 2015 14:22:23 PST, schrieb Jason Gunthorpe >: >> >On Tue, Dec 01, 2015 at 11:33:51PM +0200, Jarkko Sakkinen wrote: >> > >> >> I went through the pat

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-02 Thread Uwe Kleine-König
Hello, Cc += gregkh On Wed, Dec 02, 2015 at 10:11:14AM +0200, Jarkko Sakkinen wrote: > On Tue, Dec 01, 2015 at 03:22:23PM -0700, Jason Gunthorpe wrote: > > On Tue, Dec 01, 2015 at 11:33:51PM +0200, Jarkko Sakkinen wrote: > > > > > I went through the patches and didn't see anything that would sho

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-02 Thread Jarkko Sakkinen
On Tue, Dec 01, 2015 at 05:15:14PM -0800, Peter Huewe wrote: > > > Am 1. Dezember 2015 14:22:23 PST, schrieb Jason Gunthorpe > : > >On Tue, Dec 01, 2015 at 11:33:51PM +0200, Jarkko Sakkinen wrote: > > > >> I went through the patches and didn't see anything that would shock > >me > >> enough not

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-02 Thread Jarkko Sakkinen
On Tue, Dec 01, 2015 at 03:22:23PM -0700, Jason Gunthorpe wrote: > On Tue, Dec 01, 2015 at 11:33:51PM +0200, Jarkko Sakkinen wrote: > > > I went through the patches and didn't see anything that would shock me > > enough not to apply the patches in the current if they also work when > > tested *but

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-01 Thread Peter Huewe
Am 1. Dezember 2015 14:22:23 PST, schrieb Jason Gunthorpe : >On Tue, Dec 01, 2015 at 11:33:51PM +0200, Jarkko Sakkinen wrote: > >> I went through the patches and didn't see anything that would shock >me >> enough not to apply the patches in the current if they also work when >> tested *but* are

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-01 Thread Jason Gunthorpe
On Tue, Dec 01, 2015 at 11:33:51PM +0200, Jarkko Sakkinen wrote: > I went through the patches and didn't see anything that would shock me > enough not to apply the patches in the current if they also work when > tested *but* are these release critical for Linux v4.4? > > I got a bit confused abou

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-01 Thread Jarkko Sakkinen
On Tue, Dec 01, 2015 at 11:58:26AM -0700, Jason Gunthorpe wrote: > Drive the force=1 flow through the driver core. There are two main reasons to > do this: > 1) To enable tpm_tis for OF environments requires a platform_device anyhow, > so > the probe/release code needs to be re-used for that

Re: [PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-01 Thread Jarkko Sakkinen
On Tue, Dec 01, 2015 at 11:58:26AM -0700, Jason Gunthorpe wrote: > Drive the force=1 flow through the driver core. There are two main reasons to > do this: > 1) To enable tpm_tis for OF environments requires a platform_device anyhow, > so > the probe/release code needs to be re-used for that

[PATCH v2 0/3] tpm_tis: Clean up force module parameter

2015-12-01 Thread Jason Gunthorpe
Drive the force=1 flow through the driver core. There are two main reasons to do this: 1) To enable tpm_tis for OF environments requires a platform_device anyhow, so the probe/release code needs to be re-used for that. 2) Recent changes in the core code break the assumption that a driver wil