tpm: Get rid of chip->pdev
authorJason Gunthorpe <jgunthorpe@obsidianresearch.com>
Mon, 29 Feb 2016 17:29:47 +0000 (12:29 -0500)
committerJarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Sat, 25 Jun 2016 14:26:35 +0000 (17:26 +0300)
commit8cfffc9d4d3786d3b496a021d7224e06328bac7d
treee3e74d641c9cf6de78cfb73fca6c102a0fa12f23
parent4d8007ee2626066dbfd3917e813f7c2e47f96392
tpm: Get rid of chip->pdev

This is a hold over from before the struct device conversion.

- All prints should be using &chip->dev, which is the Linux
  standard. This changes prints to use tpm0 as the device name,
  not the PnP/etc ID.
- The few places involving sysfs/modules that really do need the
  parent just use chip->dev.parent instead
- We no longer need to get_device(pdev) in any places since it is no
  longer used by any of the code. The kref on the parent is held
  by the device core during device_add and dropped in device_del

Signed-off-by: Jason Gunthorpe <jgunthorpe@obsidianresearch.com>
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Tested-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Reviewed-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Tested-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
13 files changed:
drivers/char/tpm/tpm-chip.c
drivers/char/tpm/tpm-dev.c
drivers/char/tpm/tpm-interface.c
drivers/char/tpm/tpm-sysfs.c
drivers/char/tpm/tpm.h
drivers/char/tpm/tpm2-cmd.c
drivers/char/tpm/tpm_atmel.c
drivers/char/tpm/tpm_i2c_atmel.c
drivers/char/tpm/tpm_i2c_infineon.c
drivers/char/tpm/tpm_i2c_nuvoton.c
drivers/char/tpm/tpm_infineon.c
drivers/char/tpm/tpm_nsc.c
drivers/char/tpm/tpm_tis.c