tpm: fix up the tpm_class shutdown_pre pointer when created
[sfrench/cifs-2.6.git] / drivers / char / tpm / tpm-chip.c
index b99f55f2d4fd25dd1669489d81f07ac8c7513100..7c444209a2561fdc3d043bf44ac4d4ecd827086e 100644 (file)
@@ -282,7 +282,7 @@ static void tpm_dev_release(struct device *dev)
  *
  * Return: always 0 (i.e. success)
  */
-static int tpm_class_shutdown(struct device *dev)
+int tpm_class_shutdown(struct device *dev)
 {
        struct tpm_chip *chip = container_of(dev, struct tpm_chip, dev);
 
@@ -337,7 +337,6 @@ struct tpm_chip *tpm_chip_alloc(struct device *pdev,
        device_initialize(&chip->dev);
 
        chip->dev.class = tpm_class;
-       chip->dev.class->shutdown_pre = tpm_class_shutdown;
        chip->dev.release = tpm_dev_release;
        chip->dev.parent = pdev;
        chip->dev.groups = chip->groups;